Hello, I'm IPython-Dashboar, which is inspired by one of the greatest package, IPython.

I'm a stand alone, light-weight web server for building, sharing graphs created in ipython. Build for data science, data analysis guys. Building an interactive visualization, collaborated dashboard, and real-time streaming graph.

If you are do data exploring in IPython notebook, and draw some graph or select some metrics from database, which will be used to present to others, but you don't like to share the code or the complicated logic [ for private or page cleaning ], I think I can help you to do the present part job.

In this tutorial, I'll show you how to do data exploring in ipython notebook and how to share it to others without ipython.


1. Load packages [ One can't make bricks without straw ]

  • I recommend import package in a readable and reasonable order, which will be useful as the project gets larger.
In [1]:
# built-in package
import os
import sys
import json
import time
import datetime as dt

# third-parth package
import dashboard as dash
import pandas as pd
import matplotlib as plt
import seaborn
import mpld3

# package configre
pd.options.display.max_columns = 100
pd.options.display.max_rows = 500

2. Load data

  • I've prepared a test data on this repo.
  • Don't forget to take a look at the data before exploring it, that's a good habit.
In [2]:
url = """https://github.com/litaotao/IPython-Dashboard/raw/v-0.1.2-visualiza-table/docs/people_number_by_province_lateset_10_years.csv"""
data = pd.read_csv(url)
In [3]:
地区 2014年 2013年 2012年 2011年 2010年 2009年 2008年 2007年 2006年 2005年
0 北京市 2152 2115 2069 2019 1962 1860 1771 1676 1601 1538
1 天津市 1517 1472 1413 1355 1299 1228 1176 1115 1075 1043
2 河北省 7384 7333 7288 7241 7194 7034 6989 6943 6898 6851

3. Traditionaly way of plotting [ I really like ipython indeed, but ... ]

  • matplotlib + seaborn + mpld3 : I really like it very much, but ...
  • raw html : ok, it a way indeed, but ...
In [4]:
data.plot(x="地区", y=["2014年", "2013年"], kind="bar", figsize=(12, 5))

4. Not enough even arm matplotlib with seaborn, mpld3

  • If you just wanna share this graph above to others ?
  • if you wanna hidden/show a specific field, eg, just show one years' population ?
  • If you wanna know the exact number of a bar when the hovering on the bar ?
  • if ...
  • if ...


5. How IPython-Dashboard make it simple

  • No need to code complicated graph settings
  • Flexible to define
  • Able to share one graph, multi-graph in a dashboard
  • More ? coming soon ...


  • start redis server
  • start IPython-Dashboard server

redis-server dash-server

5.1 Firstly, send you data to the IPython-Dashboard

In [5]:
dash.client.sender(data, key='chinese_population', force=True)

5.2 Secondly, oh, there is no second step, you can explore your graph, dashboard as long as opening browser


In [ ]: