In [1]:
import pixiedust


Pixiedust database opened successfully
Pixiedust version 0.74
/Users/rajrsingh/anaconda/lib/python2.7/site-packages/bokeh/core/json_encoder.py:52: DeprecationWarning: parsing timezone aware datetimes is deprecated; this will raise an error in the future
  NP_EPOCH = np.datetime64('1970-01-01T00:00:00Z')

In [2]:
pixiedust.sampleData()


Id Name Topic Publisher
1 Car performance data transportation IBM
2 Airbnb Data for Analytics: Washington D.C. Listings Economy & Business IBM Cloud Data Services
3 Total population by country Society IBM Cloud Data Services
4 GoSales Transactions for Naive Bayes Model Leisure IBM
5 Election results by County Society IBM
6 Million dollar home sales in NE Mass late 2016 Economy & Business IBM

In [3]:
popdf = pixiedust.sampleData(3)


Downloading 'Total population by country' from https://apsportal.ibm.com/exchange-api/v1/entries/889ca053a19986a4445839358a91963e/data?accessKey=657b130d504ab539947e51b50f0e338e
Starting download...
Creating pySpark DataFrame for 'Total population by country'. Please wait...
Successfully created pySpark DataFrame for 'Total population by country'

In [4]:
display(popdf)


Hey, there's something awesome here! To see it, open this notebook outside GitHub, in a viewer like Jupyter
456,816270,437,212,523

Million dollar home sales

Home sales of $1million and above in Northeastern Massachusetts for the 3 months prior to Jan. 27, 2017. Downloaded from Redfin.com on Jan. 27, 2017.


In [5]:
homesdf = pixiedust.sampleData(6)


Downloading 'Million dollar home sales in NE Mass late 2016' from https://openobjectstore.mybluemix.net/misc/milliondollarhomes.csv
Starting download...
Creating pySpark DataFrame for 'Million dollar home sales in NE Mass late 2016'. Please wait...
Successfully created pySpark DataFrame for 'Million dollar home sales in NE Mass late 2016'

Map display

The first time you run the main pixiedust visualization command, display(), you get the default visualization, which is a table. Then, from the drop-down menu select "Map", and populate the options dialog as follows:

  • Keys: put your latitude and longitude fields here. They must be floating values. These fields must be named latitude, lat or y and longitude, lon or x.
  • Values: the field you want to use to thematically color the map. Only one field can be used.
  • Mapbox Access Token: The token you get from your Mapbox account here: https://www.mapbox.com/studio/signup/

In [6]:
display(homesdf)


Hey, there's something awesome here! To see it, open this notebook outside GitHub, in a viewer like Jupyter

PixieDust map with Mapbox