1171 lines
103 KiB
Text
1171 lines
103 KiB
Text
{
|
|
"cells": [
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"# Data Exploration\n",
|
|
"\n"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 1,
|
|
"metadata": {
|
|
"collapsed": true,
|
|
"scrolled": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"import os\n",
|
|
"import pandas as pd\n",
|
|
"import settings\n",
|
|
"\n",
|
|
"% matplotlib inline"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 2,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/html": [
|
|
"<div>\n",
|
|
"<style>\n",
|
|
" .dataframe thead tr:only-child th {\n",
|
|
" text-align: right;\n",
|
|
" }\n",
|
|
"\n",
|
|
" .dataframe thead th {\n",
|
|
" text-align: left;\n",
|
|
" }\n",
|
|
"\n",
|
|
" .dataframe tbody tr th {\n",
|
|
" vertical-align: top;\n",
|
|
" }\n",
|
|
"</style>\n",
|
|
"<table border=\"1\" class=\"dataframe\">\n",
|
|
" <thead>\n",
|
|
" <tr style=\"text-align: right;\">\n",
|
|
" <th></th>\n",
|
|
" <th>Nation</th>\n",
|
|
" <th>Year</th>\n",
|
|
" <th>Pop</th>\n",
|
|
" </tr>\n",
|
|
" </thead>\n",
|
|
" <tbody>\n",
|
|
" <tr>\n",
|
|
" <th>0</th>\n",
|
|
" <td>North America</td>\n",
|
|
" <td>1980</td>\n",
|
|
" <td>320.27638</td>\n",
|
|
" </tr>\n",
|
|
" <tr>\n",
|
|
" <th>1</th>\n",
|
|
" <td>Bermuda</td>\n",
|
|
" <td>1980</td>\n",
|
|
" <td>0.05473</td>\n",
|
|
" </tr>\n",
|
|
" <tr>\n",
|
|
" <th>2</th>\n",
|
|
" <td>Argentina</td>\n",
|
|
" <td>1980</td>\n",
|
|
" <td>28.3698</td>\n",
|
|
" </tr>\n",
|
|
" <tr>\n",
|
|
" <th>3</th>\n",
|
|
" <td>Former U.S.S.R.</td>\n",
|
|
" <td>1980</td>\n",
|
|
" <td>265.92182</td>\n",
|
|
" </tr>\n",
|
|
" <tr>\n",
|
|
" <th>4</th>\n",
|
|
" <td>Georgia</td>\n",
|
|
" <td>1980</td>\n",
|
|
" <td>--</td>\n",
|
|
" </tr>\n",
|
|
" </tbody>\n",
|
|
"</table>\n",
|
|
"</div>"
|
|
],
|
|
"text/plain": [
|
|
" Nation Year Pop\n",
|
|
"0 North America 1980 320.27638\n",
|
|
"1 Bermuda 1980 0.05473\n",
|
|
"2 Argentina 1980 28.3698\n",
|
|
"3 Former U.S.S.R. 1980 265.92182\n",
|
|
"4 Georgia 1980 --"
|
|
]
|
|
},
|
|
"execution_count": 2,
|
|
"metadata": {},
|
|
"output_type": "execute_result"
|
|
}
|
|
],
|
|
"source": [
|
|
"df = pd.read_csv(os.path.join(settings.data_dir, 'pop_by_country_long_form.csv'))\n",
|
|
"df['Year'] = df['Year'].str[4:].astype(int)\n",
|
|
"df.head()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 3,
|
|
"metadata": {
|
|
"scrolled": true
|
|
},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/plain": [
|
|
"array(['North America', 'Bermuda', 'Argentina', 'Former U.S.S.R.',\n",
|
|
" 'Georgia', 'Kazakhstan', 'Kyrgyzstan', 'Latvia', 'Lithuania',\n",
|
|
" 'Moldova', 'Russia', 'Tajikistan', 'Turkmenistan', 'Aruba',\n",
|
|
" 'Ukraine', 'Uzbekistan', 'Middle East', 'Bahrain', 'Iran', 'Iraq',\n",
|
|
" 'Israel', 'Jordan', 'Kuwait', 'Lebanon', 'Bahamas, The', 'Oman',\n",
|
|
" 'Palestine', 'Qatar', 'Saudi Arabia', 'Syria',\n",
|
|
" 'United Arab Emirates', 'Yemen', 'Africa', 'Algeria', 'Angola',\n",
|
|
" 'Barbados', 'Benin', 'Botswana', 'Burkina Faso', 'Burundi',\n",
|
|
" 'Cameroon', 'Cape Verde', 'Central African Republic', 'Chad',\n",
|
|
" 'Comoros', 'Congo (Brazzaville)', 'Belize', 'Congo (Kinshasa)',\n",
|
|
" 'Cote dIvoire (IvoryCoast)', 'Djibouti', 'Egypt',\n",
|
|
" 'Equatorial Guinea', 'Eritrea', 'Ethiopia', 'Gabon', 'Gambia, The',\n",
|
|
" 'Ghana', 'Bolivia', 'Guinea', 'Guinea-Bissau', 'Kenya', 'Lesotho',\n",
|
|
" 'Liberia', 'Libya', 'Madagascar', 'Malawi', 'Mali', 'Mauritania',\n",
|
|
" 'Brazil', 'Mauritius', 'Morocco', 'Mozambique', 'Namibia', 'Niger',\n",
|
|
" 'Nigeria', 'Reunion', 'Rwanda', 'Saint Helena',\n",
|
|
" 'Sao Tome and Principe', 'Cayman Islands', 'Senegal', 'Seychelles',\n",
|
|
" 'Sierra Leone', 'Somalia', 'South Africa', 'Sudan', 'Swaziland',\n",
|
|
" 'Tanzania', 'Togo', 'Tunisia', 'Chile', 'Uganda', 'Western Sahara',\n",
|
|
" 'Zambia', 'Zimbabwe', 'Asia & Oceania', 'Afghanistan',\n",
|
|
" 'American Samoa', 'Australia', 'Bangladesh', 'Bhutan', 'Colombia',\n",
|
|
" 'Brunei', 'Burma (Myanmar)', 'Cambodia', 'China', 'Cook Islands',\n",
|
|
" 'Fiji', 'French Polynesia', 'Guam', 'Hawaiian Trade Zone',\n",
|
|
" 'Hong Kong', 'Canada', 'Costa Rica', 'India', 'Indonesia', 'Japan',\n",
|
|
" 'Kiribati', 'Korea, North', 'Korea, South', 'Laos', 'Macau',\n",
|
|
" 'Malaysia', 'Maldives', 'Cuba', 'Mongolia', 'Nauru', 'Nepal',\n",
|
|
" 'New Caledonia', 'New Zealand', 'Niue', 'Pakistan',\n",
|
|
" 'Papua New Guinea', 'Philippines', 'Samoa', 'Dominica', 'Singapore',\n",
|
|
" 'Solomon Islands', 'Sri Lanka', 'Taiwan', 'Thailand',\n",
|
|
" 'Timor-Leste (East Timor)', 'Tonga', 'U.S. Pacific Islands',\n",
|
|
" 'Vanuatu', 'Vietnam', 'Dominican Republic', 'Wake Island', 'World',\n",
|
|
" 'Ecuador', 'El Salvador', 'Falkland Islands (Islas Malvinas)',\n",
|
|
" 'French Guiana', 'Grenada', 'Guadeloupe', 'Greenland', 'Guatemala',\n",
|
|
" 'Guyana', 'Haiti', 'Honduras', 'Jamaica', 'Martinique',\n",
|
|
" 'Montserrat', 'Netherlands Antilles', 'Nicaragua', 'Panama',\n",
|
|
" 'Mexico', 'Paraguay', 'Peru', 'Puerto Rico',\n",
|
|
" 'Saint Kitts and Nevis', 'Saint Lucia', 'Saint Vincent/Grenadines',\n",
|
|
" 'Suriname', 'Trinidad and Tobago', 'Turks and Caicos Islands',\n",
|
|
" 'Uruguay', 'Saint Pierre and Miquelon', 'Venezuela',\n",
|
|
" 'Virgin Islands, U.S.', 'Virgin Islands, British', 'Europe',\n",
|
|
" 'Albania', 'Austria', 'Belgium', 'Bosnia and Herzegovina',\n",
|
|
" 'Bulgaria', 'Croatia', 'United States', 'Cyprus', 'Czech Republic',\n",
|
|
" 'Denmark', 'Faroe Islands', 'Finland', 'Former Czechoslovakia',\n",
|
|
" 'Former Serbia and Montenegro', 'Former Yugoslavia', 'France',\n",
|
|
" 'Germany', 'Central & South America', 'Germany, East',\n",
|
|
" 'Germany, West', 'Gibraltar', 'Greece', 'Hungary', 'Iceland',\n",
|
|
" 'Ireland', 'Italy', 'Luxembourg', 'Macedonia', 'Antarctica',\n",
|
|
" 'Malta', 'Montenegro', 'Netherlands', 'Norway', 'Poland',\n",
|
|
" 'Portugal', 'Romania', 'Serbia', 'Slovakia', 'Slovenia',\n",
|
|
" 'Antigua and Barbuda', 'Spain', 'Sweden', 'Switzerland', 'Turkey',\n",
|
|
" 'United Kingdom', 'Eurasia', 'Armenia', 'Azerbaijan', 'Belarus',\n",
|
|
" 'Estonia'], dtype=object)"
|
|
]
|
|
},
|
|
"execution_count": 3,
|
|
"metadata": {},
|
|
"output_type": "execute_result"
|
|
}
|
|
],
|
|
"source": [
|
|
"df.Nation.drop_duplicates().values"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 4,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"name": "stdout",
|
|
"output_type": "stream",
|
|
"text": [
|
|
"Object `to_json` not found.\n"
|
|
]
|
|
}
|
|
],
|
|
"source": [
|
|
"nation = 'United States'\n",
|
|
"df2 = df.groupby(['Year', 'Nation']).sum().unstack()\n",
|
|
"df2.columns = df2.columns.droplevel()#[nation]\n",
|
|
"df2[[nation]].rename(columns={'United States':'Series', 'Year':'Values'}).to_json?"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"df2[[nation]].rename(columns={'United States':'Series', 'Year':'Values'}).to_json"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 5,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/plain": [
|
|
"<bound method NDFrame.to_json of Nation Series\n",
|
|
"Year \n",
|
|
"1980 227.22468\n",
|
|
"1981 229.46571\n",
|
|
"1982 231.66446\n",
|
|
"1983 233.79199\n",
|
|
"1984 235.8249\n",
|
|
"1985 237.9238\n",
|
|
"1986 240.13289\n",
|
|
"1987 242.28892\n",
|
|
"1988 244.49898\n",
|
|
"1989 246.81923\n",
|
|
"1990 249.62281\n",
|
|
"1991 252.98094\n",
|
|
"1992 256.51422\n",
|
|
"1993 259.91859\n",
|
|
"1994 263.12582\n",
|
|
"1995 266.27839\n",
|
|
"1996 269.39428\n",
|
|
"1997 272.64693\n",
|
|
"1998 275.8541\n",
|
|
"1999 279.04017\n",
|
|
"2000 282.17196\n",
|
|
"2001 285.08156\n",
|
|
"2002 287.80391\n",
|
|
"2003 290.32642\n",
|
|
"2004 293.04574\n",
|
|
"2005 295.75315\n",
|
|
"2006 298.59321\n",
|
|
"2007 301.5799\n",
|
|
"2008 304.37485\n",
|
|
"2009 307.00655\n",
|
|
"2010 310.23286>"
|
|
]
|
|
},
|
|
"execution_count": 5,
|
|
"metadata": {},
|
|
"output_type": "execute_result"
|
|
}
|
|
],
|
|
"source": [
|
|
"df2[[nation]].rename(columns={'United States':'Series', 'Year':'Values'}).to_json"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 6,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/plain": [
|
|
"'labels:[1980, 1981, 1982, 1983, 1984, 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010], series: [[227.22468, 229.46571, 231.66446, 233.79199, 235.8249, 237.9238, 240.13289, 242.28892, 244.49898, 246.81923, 249.62281, 252.98094, 256.51422, 259.91859, 263.12582, 266.27839, 269.39428, 272.64693, 275.8541, 279.04017, 282.17196, 285.08156, 287.80391, 290.32642, 293.04574, 295.75315, 298.59321, 301.5799, 304.37485, 307.00655, 310.23286]]'"
|
|
]
|
|
},
|
|
"execution_count": 6,
|
|
"metadata": {},
|
|
"output_type": "execute_result"
|
|
}
|
|
],
|
|
"source": [
|
|
"f'labels:{df2.index.astype(int).tolist()}, series: [{df2[nation].astype(float).tolist()}]'"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 7,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"df = pd.read_csv(os.path.join(settings.data_dir, 'pop_by_country_long_form.csv'))\n",
|
|
"df['Year'] = df['Year'].str[4:].astype(int)\n",
|
|
"df2 = df.groupby(['Year', 'Nation']).sum().unstack()\n",
|
|
"df2.columns = df2.columns.droplevel()\n",
|
|
"nations = df2.columns"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 8,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"import matplotlib.pyplot as plt"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 9,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAXYAAAECCAYAAADq7fyyAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3Xl0VdXB/vHvZkgYQ5iCDAmBAIGAhCEMolWwIBZxrlBn\nsS1Y6q+1vg6lqKiIQ62CQ0FRBKvSWgWRQlEmURSUyjyFDCQBIgQCZJ7v3b8/Et8XLUqmm3PvyfNZ\ni7WSm3vvefaC+7Bzzj7nGGstIiLiHg2cDiAiIrVLxS4i4jIqdhERl1Gxi4i4jIpdRMRlVOwiIi6j\nYhcRcRkVu4iIy6jYRURcppGvN9CuXTsbGRnp682IiLjK1q1bM6217avzWp8Xe2RkJF9//bWvNyMi\n4irGmLTqvla7YkREXEbFLiLiMip2ERGXUbGLiLiMil1ExGVU7CIiLqNiFxFxGZ+vYxcRkcorKfMy\nb0Nyjd5DxS4i4id2Hs7iwSW7iD+WW6P30a4YERGHFZZ4ePLf+7l27hdkFZTy+m1xNXo/zdhFRBy0\nOfkk05buIvVkATcOjWDauN6ENGlco/dUsYuIOCCnqJSnV8Wz+KtDdG3bjMW/HsaIqHa18t4qdhGR\nOrY+PoM/Ld3D8dwifv2Tbtw7JpqmQQ1r7f1V7CIideRkXjGPr9jHhzu+IbpDS165dTADwkNrfTsq\ndhERH7PW8q9dR3l0+V5yi0q5Z3RPpo7sQVAj36xfUbGLiPhQRk4R0z/Yw9r9GcSGh/Ln6/sTfV5L\nn25TxS4i4gPWWt77+ggzV+6jpMzL9HF9uPOibjRsYH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PATc7mkykFmkfu4iIy2jGLiLiMip2ERGXUbGLiLiMil1ExGVU7CIiLqNi\nFxFxGRW7iIjL/H/U9KEeLyXnkAAAAABJRU5ErkJggg==\n",
|
|
"text/plain": [
|
|
"<matplotlib.figure.Figure at 0x9f78a20>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"fig, ax = plt.subplots()\n",
|
|
"df2[nations[12]].astype(float).plot(ax=ax);"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 10,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"items = ['mpl/' + nation for nation in df2.columns]"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 11,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/plain": [
|
|
"[('mpl/Afghanistan', 'mpl/Afghanistan'),\n",
|
|
" ('mpl/Africa', 'mpl/Africa'),\n",
|
|
" ('mpl/Albania', 'mpl/Albania'),\n",
|
|
" ('mpl/Algeria', 'mpl/Algeria'),\n",
|
|
" ('mpl/American Samoa', 'mpl/American Samoa'),\n",
|
|
" ('mpl/Angola', 'mpl/Angola'),\n",
|
|
" ('mpl/Antarctica', 'mpl/Antarctica'),\n",
|
|
" ('mpl/Antigua and Barbuda', 'mpl/Antigua and Barbuda'),\n",
|
|
" ('mpl/Argentina', 'mpl/Argentina'),\n",
|
|
" ('mpl/Armenia', 'mpl/Armenia'),\n",
|
|
" ('mpl/Aruba', 'mpl/Aruba'),\n",
|
|
" ('mpl/Asia & Oceania', 'mpl/Asia & Oceania'),\n",
|
|
" ('mpl/Australia', 'mpl/Australia'),\n",
|
|
" ('mpl/Austria', 'mpl/Austria'),\n",
|
|
" ('mpl/Azerbaijan', 'mpl/Azerbaijan'),\n",
|
|
" ('mpl/Bahamas, The', 'mpl/Bahamas, The'),\n",
|
|
" ('mpl/Bahrain', 'mpl/Bahrain'),\n",
|
|
" ('mpl/Bangladesh', 'mpl/Bangladesh'),\n",
|
|
" ('mpl/Barbados', 'mpl/Barbados'),\n",
|
|
" ('mpl/Belarus', 'mpl/Belarus'),\n",
|
|
" ('mpl/Belgium', 'mpl/Belgium'),\n",
|
|
" ('mpl/Belize', 'mpl/Belize'),\n",
|
|
" ('mpl/Benin', 'mpl/Benin'),\n",
|
|
" ('mpl/Bermuda', 'mpl/Bermuda'),\n",
|
|
" ('mpl/Bhutan', 'mpl/Bhutan'),\n",
|
|
" ('mpl/Bolivia', 'mpl/Bolivia'),\n",
|
|
" ('mpl/Bosnia and Herzegovina', 'mpl/Bosnia and Herzegovina'),\n",
|
|
" ('mpl/Botswana', 'mpl/Botswana'),\n",
|
|
" ('mpl/Brazil', 'mpl/Brazil'),\n",
|
|
" ('mpl/Brunei', 'mpl/Brunei'),\n",
|
|
" ('mpl/Bulgaria', 'mpl/Bulgaria'),\n",
|
|
" ('mpl/Burkina Faso', 'mpl/Burkina Faso'),\n",
|
|
" ('mpl/Burma (Myanmar)', 'mpl/Burma (Myanmar)'),\n",
|
|
" ('mpl/Burundi', 'mpl/Burundi'),\n",
|
|
" ('mpl/Cambodia', 'mpl/Cambodia'),\n",
|
|
" ('mpl/Cameroon', 'mpl/Cameroon'),\n",
|
|
" ('mpl/Canada', 'mpl/Canada'),\n",
|
|
" ('mpl/Cape Verde', 'mpl/Cape Verde'),\n",
|
|
" ('mpl/Cayman Islands', 'mpl/Cayman Islands'),\n",
|
|
" ('mpl/Central & South America', 'mpl/Central & South America'),\n",
|
|
" ('mpl/Central African Republic', 'mpl/Central African Republic'),\n",
|
|
" ('mpl/Chad', 'mpl/Chad'),\n",
|
|
" ('mpl/Chile', 'mpl/Chile'),\n",
|
|
" ('mpl/China', 'mpl/China'),\n",
|
|
" ('mpl/Colombia', 'mpl/Colombia'),\n",
|
|
" ('mpl/Comoros', 'mpl/Comoros'),\n",
|
|
" ('mpl/Congo (Brazzaville)', 'mpl/Congo (Brazzaville)'),\n",
|
|
" ('mpl/Congo (Kinshasa)', 'mpl/Congo (Kinshasa)'),\n",
|
|
" ('mpl/Cook Islands', 'mpl/Cook Islands'),\n",
|
|
" ('mpl/Costa Rica', 'mpl/Costa Rica'),\n",
|
|
" ('mpl/Cote dIvoire (IvoryCoast)', 'mpl/Cote dIvoire (IvoryCoast)'),\n",
|
|
" ('mpl/Croatia', 'mpl/Croatia'),\n",
|
|
" ('mpl/Cuba', 'mpl/Cuba'),\n",
|
|
" ('mpl/Cyprus', 'mpl/Cyprus'),\n",
|
|
" ('mpl/Czech Republic', 'mpl/Czech Republic'),\n",
|
|
" ('mpl/Denmark', 'mpl/Denmark'),\n",
|
|
" ('mpl/Djibouti', 'mpl/Djibouti'),\n",
|
|
" ('mpl/Dominica', 'mpl/Dominica'),\n",
|
|
" ('mpl/Dominican Republic', 'mpl/Dominican Republic'),\n",
|
|
" ('mpl/Ecuador', 'mpl/Ecuador'),\n",
|
|
" ('mpl/Egypt', 'mpl/Egypt'),\n",
|
|
" ('mpl/El Salvador', 'mpl/El Salvador'),\n",
|
|
" ('mpl/Equatorial Guinea', 'mpl/Equatorial Guinea'),\n",
|
|
" ('mpl/Eritrea', 'mpl/Eritrea'),\n",
|
|
" ('mpl/Estonia', 'mpl/Estonia'),\n",
|
|
" ('mpl/Ethiopia', 'mpl/Ethiopia'),\n",
|
|
" ('mpl/Eurasia', 'mpl/Eurasia'),\n",
|
|
" ('mpl/Europe', 'mpl/Europe'),\n",
|
|
" ('mpl/Falkland Islands (Islas Malvinas)',\n",
|
|
" 'mpl/Falkland Islands (Islas Malvinas)'),\n",
|
|
" ('mpl/Faroe Islands', 'mpl/Faroe Islands'),\n",
|
|
" ('mpl/Fiji', 'mpl/Fiji'),\n",
|
|
" ('mpl/Finland', 'mpl/Finland'),\n",
|
|
" ('mpl/Former Czechoslovakia', 'mpl/Former Czechoslovakia'),\n",
|
|
" ('mpl/Former Serbia and Montenegro', 'mpl/Former Serbia and Montenegro'),\n",
|
|
" ('mpl/Former U.S.S.R.', 'mpl/Former U.S.S.R.'),\n",
|
|
" ('mpl/Former Yugoslavia', 'mpl/Former Yugoslavia'),\n",
|
|
" ('mpl/France', 'mpl/France'),\n",
|
|
" ('mpl/French Guiana', 'mpl/French Guiana'),\n",
|
|
" ('mpl/French Polynesia', 'mpl/French Polynesia'),\n",
|
|
" ('mpl/Gabon', 'mpl/Gabon'),\n",
|
|
" ('mpl/Gambia, The', 'mpl/Gambia, The'),\n",
|
|
" ('mpl/Georgia', 'mpl/Georgia'),\n",
|
|
" ('mpl/Germany', 'mpl/Germany'),\n",
|
|
" ('mpl/Germany, East', 'mpl/Germany, East'),\n",
|
|
" ('mpl/Germany, West', 'mpl/Germany, West'),\n",
|
|
" ('mpl/Ghana', 'mpl/Ghana'),\n",
|
|
" ('mpl/Gibraltar', 'mpl/Gibraltar'),\n",
|
|
" ('mpl/Greece', 'mpl/Greece'),\n",
|
|
" ('mpl/Greenland', 'mpl/Greenland'),\n",
|
|
" ('mpl/Grenada', 'mpl/Grenada'),\n",
|
|
" ('mpl/Guadeloupe', 'mpl/Guadeloupe'),\n",
|
|
" ('mpl/Guam', 'mpl/Guam'),\n",
|
|
" ('mpl/Guatemala', 'mpl/Guatemala'),\n",
|
|
" ('mpl/Guinea', 'mpl/Guinea'),\n",
|
|
" ('mpl/Guinea-Bissau', 'mpl/Guinea-Bissau'),\n",
|
|
" ('mpl/Guyana', 'mpl/Guyana'),\n",
|
|
" ('mpl/Haiti', 'mpl/Haiti'),\n",
|
|
" ('mpl/Hawaiian Trade Zone', 'mpl/Hawaiian Trade Zone'),\n",
|
|
" ('mpl/Honduras', 'mpl/Honduras'),\n",
|
|
" ('mpl/Hong Kong', 'mpl/Hong Kong'),\n",
|
|
" ('mpl/Hungary', 'mpl/Hungary'),\n",
|
|
" ('mpl/Iceland', 'mpl/Iceland'),\n",
|
|
" ('mpl/India', 'mpl/India'),\n",
|
|
" ('mpl/Indonesia', 'mpl/Indonesia'),\n",
|
|
" ('mpl/Iran', 'mpl/Iran'),\n",
|
|
" ('mpl/Iraq', 'mpl/Iraq'),\n",
|
|
" ('mpl/Ireland', 'mpl/Ireland'),\n",
|
|
" ('mpl/Israel', 'mpl/Israel'),\n",
|
|
" ('mpl/Italy', 'mpl/Italy'),\n",
|
|
" ('mpl/Jamaica', 'mpl/Jamaica'),\n",
|
|
" ('mpl/Japan', 'mpl/Japan'),\n",
|
|
" ('mpl/Jordan', 'mpl/Jordan'),\n",
|
|
" ('mpl/Kazakhstan', 'mpl/Kazakhstan'),\n",
|
|
" ('mpl/Kenya', 'mpl/Kenya'),\n",
|
|
" ('mpl/Kiribati', 'mpl/Kiribati'),\n",
|
|
" ('mpl/Korea, North', 'mpl/Korea, North'),\n",
|
|
" ('mpl/Korea, South', 'mpl/Korea, South'),\n",
|
|
" ('mpl/Kuwait', 'mpl/Kuwait'),\n",
|
|
" ('mpl/Kyrgyzstan', 'mpl/Kyrgyzstan'),\n",
|
|
" ('mpl/Laos', 'mpl/Laos'),\n",
|
|
" ('mpl/Latvia', 'mpl/Latvia'),\n",
|
|
" ('mpl/Lebanon', 'mpl/Lebanon'),\n",
|
|
" ('mpl/Lesotho', 'mpl/Lesotho'),\n",
|
|
" ('mpl/Liberia', 'mpl/Liberia'),\n",
|
|
" ('mpl/Libya', 'mpl/Libya'),\n",
|
|
" ('mpl/Lithuania', 'mpl/Lithuania'),\n",
|
|
" ('mpl/Luxembourg', 'mpl/Luxembourg'),\n",
|
|
" ('mpl/Macau', 'mpl/Macau'),\n",
|
|
" ('mpl/Macedonia', 'mpl/Macedonia'),\n",
|
|
" ('mpl/Madagascar', 'mpl/Madagascar'),\n",
|
|
" ('mpl/Malawi', 'mpl/Malawi'),\n",
|
|
" ('mpl/Malaysia', 'mpl/Malaysia'),\n",
|
|
" ('mpl/Maldives', 'mpl/Maldives'),\n",
|
|
" ('mpl/Mali', 'mpl/Mali'),\n",
|
|
" ('mpl/Malta', 'mpl/Malta'),\n",
|
|
" ('mpl/Martinique', 'mpl/Martinique'),\n",
|
|
" ('mpl/Mauritania', 'mpl/Mauritania'),\n",
|
|
" ('mpl/Mauritius', 'mpl/Mauritius'),\n",
|
|
" ('mpl/Mexico', 'mpl/Mexico'),\n",
|
|
" ('mpl/Middle East', 'mpl/Middle East'),\n",
|
|
" ('mpl/Moldova', 'mpl/Moldova'),\n",
|
|
" ('mpl/Mongolia', 'mpl/Mongolia'),\n",
|
|
" ('mpl/Montenegro', 'mpl/Montenegro'),\n",
|
|
" ('mpl/Montserrat', 'mpl/Montserrat'),\n",
|
|
" ('mpl/Morocco', 'mpl/Morocco'),\n",
|
|
" ('mpl/Mozambique', 'mpl/Mozambique'),\n",
|
|
" ('mpl/Namibia', 'mpl/Namibia'),\n",
|
|
" ('mpl/Nauru', 'mpl/Nauru'),\n",
|
|
" ('mpl/Nepal', 'mpl/Nepal'),\n",
|
|
" ('mpl/Netherlands', 'mpl/Netherlands'),\n",
|
|
" ('mpl/Netherlands Antilles', 'mpl/Netherlands Antilles'),\n",
|
|
" ('mpl/New Caledonia', 'mpl/New Caledonia'),\n",
|
|
" ('mpl/New Zealand', 'mpl/New Zealand'),\n",
|
|
" ('mpl/Nicaragua', 'mpl/Nicaragua'),\n",
|
|
" ('mpl/Niger', 'mpl/Niger'),\n",
|
|
" ('mpl/Nigeria', 'mpl/Nigeria'),\n",
|
|
" ('mpl/Niue', 'mpl/Niue'),\n",
|
|
" ('mpl/North America', 'mpl/North America'),\n",
|
|
" ('mpl/Norway', 'mpl/Norway'),\n",
|
|
" ('mpl/Oman', 'mpl/Oman'),\n",
|
|
" ('mpl/Pakistan', 'mpl/Pakistan'),\n",
|
|
" ('mpl/Palestine', 'mpl/Palestine'),\n",
|
|
" ('mpl/Panama', 'mpl/Panama'),\n",
|
|
" ('mpl/Papua New Guinea', 'mpl/Papua New Guinea'),\n",
|
|
" ('mpl/Paraguay', 'mpl/Paraguay'),\n",
|
|
" ('mpl/Peru', 'mpl/Peru'),\n",
|
|
" ('mpl/Philippines', 'mpl/Philippines'),\n",
|
|
" ('mpl/Poland', 'mpl/Poland'),\n",
|
|
" ('mpl/Portugal', 'mpl/Portugal'),\n",
|
|
" ('mpl/Puerto Rico', 'mpl/Puerto Rico'),\n",
|
|
" ('mpl/Qatar', 'mpl/Qatar'),\n",
|
|
" ('mpl/Reunion', 'mpl/Reunion'),\n",
|
|
" ('mpl/Romania', 'mpl/Romania'),\n",
|
|
" ('mpl/Russia', 'mpl/Russia'),\n",
|
|
" ('mpl/Rwanda', 'mpl/Rwanda'),\n",
|
|
" ('mpl/Saint Helena', 'mpl/Saint Helena'),\n",
|
|
" ('mpl/Saint Kitts and Nevis', 'mpl/Saint Kitts and Nevis'),\n",
|
|
" ('mpl/Saint Lucia', 'mpl/Saint Lucia'),\n",
|
|
" ('mpl/Saint Pierre and Miquelon', 'mpl/Saint Pierre and Miquelon'),\n",
|
|
" ('mpl/Saint Vincent/Grenadines', 'mpl/Saint Vincent/Grenadines'),\n",
|
|
" ('mpl/Samoa', 'mpl/Samoa'),\n",
|
|
" ('mpl/Sao Tome and Principe', 'mpl/Sao Tome and Principe'),\n",
|
|
" ('mpl/Saudi Arabia', 'mpl/Saudi Arabia'),\n",
|
|
" ('mpl/Senegal', 'mpl/Senegal'),\n",
|
|
" ('mpl/Serbia', 'mpl/Serbia'),\n",
|
|
" ('mpl/Seychelles', 'mpl/Seychelles'),\n",
|
|
" ('mpl/Sierra Leone', 'mpl/Sierra Leone'),\n",
|
|
" ('mpl/Singapore', 'mpl/Singapore'),\n",
|
|
" ('mpl/Slovakia', 'mpl/Slovakia'),\n",
|
|
" ('mpl/Slovenia', 'mpl/Slovenia'),\n",
|
|
" ('mpl/Solomon Islands', 'mpl/Solomon Islands'),\n",
|
|
" ('mpl/Somalia', 'mpl/Somalia'),\n",
|
|
" ('mpl/South Africa', 'mpl/South Africa'),\n",
|
|
" ('mpl/Spain', 'mpl/Spain'),\n",
|
|
" ('mpl/Sri Lanka', 'mpl/Sri Lanka'),\n",
|
|
" ('mpl/Sudan', 'mpl/Sudan'),\n",
|
|
" ('mpl/Suriname', 'mpl/Suriname'),\n",
|
|
" ('mpl/Swaziland', 'mpl/Swaziland'),\n",
|
|
" ('mpl/Sweden', 'mpl/Sweden'),\n",
|
|
" ('mpl/Switzerland', 'mpl/Switzerland'),\n",
|
|
" ('mpl/Syria', 'mpl/Syria'),\n",
|
|
" ('mpl/Taiwan', 'mpl/Taiwan'),\n",
|
|
" ('mpl/Tajikistan', 'mpl/Tajikistan'),\n",
|
|
" ('mpl/Tanzania', 'mpl/Tanzania'),\n",
|
|
" ('mpl/Thailand', 'mpl/Thailand'),\n",
|
|
" ('mpl/Timor-Leste (East Timor)', 'mpl/Timor-Leste (East Timor)'),\n",
|
|
" ('mpl/Togo', 'mpl/Togo'),\n",
|
|
" ('mpl/Tonga', 'mpl/Tonga'),\n",
|
|
" ('mpl/Trinidad and Tobago', 'mpl/Trinidad and Tobago'),\n",
|
|
" ('mpl/Tunisia', 'mpl/Tunisia'),\n",
|
|
" ('mpl/Turkey', 'mpl/Turkey'),\n",
|
|
" ('mpl/Turkmenistan', 'mpl/Turkmenistan'),\n",
|
|
" ('mpl/Turks and Caicos Islands', 'mpl/Turks and Caicos Islands'),\n",
|
|
" ('mpl/U.S. Pacific Islands', 'mpl/U.S. Pacific Islands'),\n",
|
|
" ('mpl/Uganda', 'mpl/Uganda'),\n",
|
|
" ('mpl/Ukraine', 'mpl/Ukraine'),\n",
|
|
" ('mpl/United Arab Emirates', 'mpl/United Arab Emirates'),\n",
|
|
" ('mpl/United Kingdom', 'mpl/United Kingdom'),\n",
|
|
" ('mpl/United States', 'mpl/United States'),\n",
|
|
" ('mpl/Uruguay', 'mpl/Uruguay'),\n",
|
|
" ('mpl/Uzbekistan', 'mpl/Uzbekistan'),\n",
|
|
" ('mpl/Vanuatu', 'mpl/Vanuatu'),\n",
|
|
" ('mpl/Venezuela', 'mpl/Venezuela'),\n",
|
|
" ('mpl/Vietnam', 'mpl/Vietnam'),\n",
|
|
" ('mpl/Virgin Islands, U.S.', 'mpl/Virgin Islands, U.S.'),\n",
|
|
" ('mpl/Virgin Islands, British', 'mpl/Virgin Islands, British'),\n",
|
|
" ('mpl/Wake Island', 'mpl/Wake Island'),\n",
|
|
" ('mpl/Western Sahara', 'mpl/Western Sahara'),\n",
|
|
" ('mpl/World', 'mpl/World'),\n",
|
|
" ('mpl/Yemen', 'mpl/Yemen'),\n",
|
|
" ('mpl/Zambia', 'mpl/Zambia'),\n",
|
|
" ('mpl/Zimbabwe', 'mpl/Zimbabwe')]"
|
|
]
|
|
},
|
|
"execution_count": 11,
|
|
"metadata": {},
|
|
"output_type": "execute_result"
|
|
}
|
|
],
|
|
"source": [
|
|
"list(zip(items, items))"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": []
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 25,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"from bokeh.charts import Line, show\n",
|
|
"from bokeh.plotting import figure"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 26,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"from bokeh.io import output_notebook"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 27,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/html": [
|
|
"\n",
|
|
" <div class=\"bk-root\">\n",
|
|
" <a href=\"http://bokeh.pydata.org\" target=\"_blank\" class=\"bk-logo bk-logo-small bk-logo-notebook\"></a>\n",
|
|
" <span id=\"aa65fd43-0e8c-4886-87fb-20b38db331b8\">Loading BokehJS ...</span>\n",
|
|
" </div>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"application/javascript": [
|
|
"\n",
|
|
"(function(global) {\n",
|
|
" function now() {\n",
|
|
" return new Date();\n",
|
|
" }\n",
|
|
"\n",
|
|
" var force = true;\n",
|
|
"\n",
|
|
" if (typeof (window._bokeh_onload_callbacks) === \"undefined\" || force === true) {\n",
|
|
" window._bokeh_onload_callbacks = [];\n",
|
|
" window._bokeh_is_loading = undefined;\n",
|
|
" }\n",
|
|
"\n",
|
|
"\n",
|
|
" \n",
|
|
" if (typeof (window._bokeh_timeout) === \"undefined\" || force === true) {\n",
|
|
" window._bokeh_timeout = Date.now() + 5000;\n",
|
|
" window._bokeh_failed_load = false;\n",
|
|
" }\n",
|
|
"\n",
|
|
" var NB_LOAD_WARNING = {'data': {'text/html':\n",
|
|
" \"<div style='background-color: #fdd'>\\n\"+\n",
|
|
" \"<p>\\n\"+\n",
|
|
" \"BokehJS does not appear to have successfully loaded. If loading BokehJS from CDN, this \\n\"+\n",
|
|
" \"may be due to a slow or bad network connection. Possible fixes:\\n\"+\n",
|
|
" \"</p>\\n\"+\n",
|
|
" \"<ul>\\n\"+\n",
|
|
" \"<li>re-rerun `output_notebook()` to attempt to load from CDN again, or</li>\\n\"+\n",
|
|
" \"<li>use INLINE resources instead, as so:</li>\\n\"+\n",
|
|
" \"</ul>\\n\"+\n",
|
|
" \"<code>\\n\"+\n",
|
|
" \"from bokeh.resources import INLINE\\n\"+\n",
|
|
" \"output_notebook(resources=INLINE)\\n\"+\n",
|
|
" \"</code>\\n\"+\n",
|
|
" \"</div>\"}};\n",
|
|
"\n",
|
|
" function display_loaded() {\n",
|
|
" if (window.Bokeh !== undefined) {\n",
|
|
" var el = document.getElementById(\"aa65fd43-0e8c-4886-87fb-20b38db331b8\");\n",
|
|
" el.textContent = \"BokehJS \" + Bokeh.version + \" successfully loaded.\";\n",
|
|
" } else if (Date.now() < window._bokeh_timeout) {\n",
|
|
" setTimeout(display_loaded, 100)\n",
|
|
" }\n",
|
|
" }\n",
|
|
"\n",
|
|
" function run_callbacks() {\n",
|
|
" window._bokeh_onload_callbacks.forEach(function(callback) { callback() });\n",
|
|
" delete window._bokeh_onload_callbacks\n",
|
|
" console.info(\"Bokeh: all callbacks have finished\");\n",
|
|
" }\n",
|
|
"\n",
|
|
" function load_libs(js_urls, callback) {\n",
|
|
" window._bokeh_onload_callbacks.push(callback);\n",
|
|
" if (window._bokeh_is_loading > 0) {\n",
|
|
" console.log(\"Bokeh: BokehJS is being loaded, scheduling callback at\", now());\n",
|
|
" return null;\n",
|
|
" }\n",
|
|
" if (js_urls == null || js_urls.length === 0) {\n",
|
|
" run_callbacks();\n",
|
|
" return null;\n",
|
|
" }\n",
|
|
" console.log(\"Bokeh: BokehJS not loaded, scheduling load and callback at\", now());\n",
|
|
" window._bokeh_is_loading = js_urls.length;\n",
|
|
" for (var i = 0; i < js_urls.length; i++) {\n",
|
|
" var url = js_urls[i];\n",
|
|
" var s = document.createElement('script');\n",
|
|
" s.src = url;\n",
|
|
" s.async = false;\n",
|
|
" s.onreadystatechange = s.onload = function() {\n",
|
|
" window._bokeh_is_loading--;\n",
|
|
" if (window._bokeh_is_loading === 0) {\n",
|
|
" console.log(\"Bokeh: all BokehJS libraries loaded\");\n",
|
|
" run_callbacks()\n",
|
|
" }\n",
|
|
" };\n",
|
|
" s.onerror = function() {\n",
|
|
" console.warn(\"failed to load library \" + url);\n",
|
|
" };\n",
|
|
" console.log(\"Bokeh: injecting script tag for BokehJS library: \", url);\n",
|
|
" document.getElementsByTagName(\"head\")[0].appendChild(s);\n",
|
|
" }\n",
|
|
" };var element = document.getElementById(\"aa65fd43-0e8c-4886-87fb-20b38db331b8\");\n",
|
|
" if (element == null) {\n",
|
|
" console.log(\"Bokeh: ERROR: autoload.js configured with elementid 'aa65fd43-0e8c-4886-87fb-20b38db331b8' but no matching script tag was found. \")\n",
|
|
" return false;\n",
|
|
" }\n",
|
|
"\n",
|
|
" var js_urls = [\"https://cdn.pydata.org/bokeh/release/bokeh-0.12.5.min.js\", \"https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.5.min.js\"];\n",
|
|
"\n",
|
|
" var inline_js = [\n",
|
|
" function(Bokeh) {\n",
|
|
" Bokeh.set_log_level(\"info\");\n",
|
|
" },\n",
|
|
" \n",
|
|
" function(Bokeh) {\n",
|
|
" \n",
|
|
" },\n",
|
|
" \n",
|
|
" function(Bokeh) {\n",
|
|
" \n",
|
|
" document.getElementById(\"aa65fd43-0e8c-4886-87fb-20b38db331b8\").textContent = \"BokehJS is loading...\";\n",
|
|
" },\n",
|
|
" function(Bokeh) {\n",
|
|
" console.log(\"Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-0.12.5.min.css\");\n",
|
|
" Bokeh.embed.inject_css(\"https://cdn.pydata.org/bokeh/release/bokeh-0.12.5.min.css\");\n",
|
|
" console.log(\"Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.5.min.css\");\n",
|
|
" Bokeh.embed.inject_css(\"https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.5.min.css\");\n",
|
|
" }\n",
|
|
" ];\n",
|
|
"\n",
|
|
" function run_inline_js() {\n",
|
|
" \n",
|
|
" if ((window.Bokeh !== undefined) || (force === true)) {\n",
|
|
" for (var i = 0; i < inline_js.length; i++) {\n",
|
|
" inline_js[i](window.Bokeh);\n",
|
|
" }if (force === true) {\n",
|
|
" display_loaded();\n",
|
|
" }} else if (Date.now() < window._bokeh_timeout) {\n",
|
|
" setTimeout(run_inline_js, 100);\n",
|
|
" } else if (!window._bokeh_failed_load) {\n",
|
|
" console.log(\"Bokeh: BokehJS failed to load within specified timeout.\");\n",
|
|
" window._bokeh_failed_load = true;\n",
|
|
" } else if (force !== true) {\n",
|
|
" var cell = $(document.getElementById(\"aa65fd43-0e8c-4886-87fb-20b38db331b8\")).parents('.cell').data().cell;\n",
|
|
" cell.output_area.append_execute_result(NB_LOAD_WARNING)\n",
|
|
" }\n",
|
|
"\n",
|
|
" }\n",
|
|
"\n",
|
|
" if (window._bokeh_is_loading === 0) {\n",
|
|
" console.log(\"Bokeh: BokehJS loaded, going straight to plotting\");\n",
|
|
" run_inline_js();\n",
|
|
" } else {\n",
|
|
" load_libs(js_urls, function() {\n",
|
|
" console.log(\"Bokeh: BokehJS plotting callback run at\", now());\n",
|
|
" run_inline_js();\n",
|
|
" });\n",
|
|
" }\n",
|
|
"}(this));"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"output_notebook()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 40,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/html": [
|
|
"\n",
|
|
"\n",
|
|
" <div class=\"bk-root\">\n",
|
|
" <div class=\"bk-plotdiv\" id=\"fcb81158-f83c-4470-a24d-6862287beffa\"></div>\n",
|
|
" </div>\n",
|
|
"<script type=\"text/javascript\">\n",
|
|
" \n",
|
|
" (function(global) {\n",
|
|
" function now() {\n",
|
|
" return new Date();\n",
|
|
" }\n",
|
|
" \n",
|
|
" var force = false;\n",
|
|
" \n",
|
|
" if (typeof (window._bokeh_onload_callbacks) === \"undefined\" || force === true) {\n",
|
|
" window._bokeh_onload_callbacks = [];\n",
|
|
" window._bokeh_is_loading = undefined;\n",
|
|
" }\n",
|
|
" \n",
|
|
" \n",
|
|
" \n",
|
|
" if (typeof (window._bokeh_timeout) === \"undefined\" || force === true) {\n",
|
|
" window._bokeh_timeout = Date.now() + 0;\n",
|
|
" window._bokeh_failed_load = false;\n",
|
|
" }\n",
|
|
" \n",
|
|
" var NB_LOAD_WARNING = {'data': {'text/html':\n",
|
|
" \"<div style='background-color: #fdd'>\\n\"+\n",
|
|
" \"<p>\\n\"+\n",
|
|
" \"BokehJS does not appear to have successfully loaded. If loading BokehJS from CDN, this \\n\"+\n",
|
|
" \"may be due to a slow or bad network connection. Possible fixes:\\n\"+\n",
|
|
" \"</p>\\n\"+\n",
|
|
" \"<ul>\\n\"+\n",
|
|
" \"<li>re-rerun `output_notebook()` to attempt to load from CDN again, or</li>\\n\"+\n",
|
|
" \"<li>use INLINE resources instead, as so:</li>\\n\"+\n",
|
|
" \"</ul>\\n\"+\n",
|
|
" \"<code>\\n\"+\n",
|
|
" \"from bokeh.resources import INLINE\\n\"+\n",
|
|
" \"output_notebook(resources=INLINE)\\n\"+\n",
|
|
" \"</code>\\n\"+\n",
|
|
" \"</div>\"}};\n",
|
|
" \n",
|
|
" function display_loaded() {\n",
|
|
" if (window.Bokeh !== undefined) {\n",
|
|
" var el = document.getElementById(\"fcb81158-f83c-4470-a24d-6862287beffa\");\n",
|
|
" el.textContent = \"BokehJS \" + Bokeh.version + \" successfully loaded.\";\n",
|
|
" } else if (Date.now() < window._bokeh_timeout) {\n",
|
|
" setTimeout(display_loaded, 100)\n",
|
|
" }\n",
|
|
" }\n",
|
|
" \n",
|
|
" function run_callbacks() {\n",
|
|
" window._bokeh_onload_callbacks.forEach(function(callback) { callback() });\n",
|
|
" delete window._bokeh_onload_callbacks\n",
|
|
" console.info(\"Bokeh: all callbacks have finished\");\n",
|
|
" }\n",
|
|
" \n",
|
|
" function load_libs(js_urls, callback) {\n",
|
|
" window._bokeh_onload_callbacks.push(callback);\n",
|
|
" if (window._bokeh_is_loading > 0) {\n",
|
|
" console.log(\"Bokeh: BokehJS is being loaded, scheduling callback at\", now());\n",
|
|
" return null;\n",
|
|
" }\n",
|
|
" if (js_urls == null || js_urls.length === 0) {\n",
|
|
" run_callbacks();\n",
|
|
" return null;\n",
|
|
" }\n",
|
|
" console.log(\"Bokeh: BokehJS not loaded, scheduling load and callback at\", now());\n",
|
|
" window._bokeh_is_loading = js_urls.length;\n",
|
|
" for (var i = 0; i < js_urls.length; i++) {\n",
|
|
" var url = js_urls[i];\n",
|
|
" var s = document.createElement('script');\n",
|
|
" s.src = url;\n",
|
|
" s.async = false;\n",
|
|
" s.onreadystatechange = s.onload = function() {\n",
|
|
" window._bokeh_is_loading--;\n",
|
|
" if (window._bokeh_is_loading === 0) {\n",
|
|
" console.log(\"Bokeh: all BokehJS libraries loaded\");\n",
|
|
" run_callbacks()\n",
|
|
" }\n",
|
|
" };\n",
|
|
" s.onerror = function() {\n",
|
|
" console.warn(\"failed to load library \" + url);\n",
|
|
" };\n",
|
|
" console.log(\"Bokeh: injecting script tag for BokehJS library: \", url);\n",
|
|
" document.getElementsByTagName(\"head\")[0].appendChild(s);\n",
|
|
" }\n",
|
|
" };var element = document.getElementById(\"fcb81158-f83c-4470-a24d-6862287beffa\");\n",
|
|
" if (element == null) {\n",
|
|
" console.log(\"Bokeh: ERROR: autoload.js configured with elementid 'fcb81158-f83c-4470-a24d-6862287beffa' but no matching script tag was found. \")\n",
|
|
" return false;\n",
|
|
" }\n",
|
|
" \n",
|
|
" var js_urls = [];\n",
|
|
" \n",
|
|
" var inline_js = [\n",
|
|
" function(Bokeh) {\n",
|
|
" (function() {\n",
|
|
" var fn = function() {\n",
|
|
" var docs_json = {\"eb63a0a0-4597-4458-bc57-97af1d5120b2\":{\"roots\":{\"references\":[{\"attributes\":{\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"156dc6eb-4ea8-4e23-a70a-6368bb742434\",\"type\":\"Line\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"cb42e8f3-86c7-4673-ac1e-5c4bcce85a96\",\"type\":\"WheelZoomTool\"},{\"attributes\":{\"bottom_units\":\"screen\",\"fill_alpha\":{\"value\":0.5},\"fill_color\":{\"value\":\"lightgrey\"},\"left_units\":\"screen\",\"level\":\"overlay\",\"line_alpha\":{\"value\":1.0},\"line_color\":{\"value\":\"black\"},\"line_dash\":[4,4],\"line_width\":{\"value\":2},\"plot\":null,\"render_mode\":\"css\",\"right_units\":\"screen\",\"top_units\":\"screen\"},\"id\":\"c9c8b8f0-c3f2-45eb-b036-579dfcd0be74\",\"type\":\"BoxAnnotation\"},{\"attributes\":{\"callback\":null},\"id\":\"8413d19b-4f3f-4643-ac4f-31b7f078a2c7\",\"type\":\"DataRange1d\"},{\"attributes\":{\"data_source\":{\"id\":\"449cacb4-6fca-4e7b-bb36-a0a544634110\",\"type\":\"ColumnDataSource\"},\"glyph\":{\"id\":\"156dc6eb-4ea8-4e23-a70a-6368bb742434\",\"type\":\"Line\"},\"hover_glyph\":null,\"muted_glyph\":null,\"nonselection_glyph\":{\"id\":\"0f117ac5-261b-4c48-b57a-820a953caf3e\",\"type\":\"Line\"},\"selection_glyph\":null},\"id\":\"6ffe6874-fc91-4928-93ea-13db2b80cb88\",\"type\":\"GlyphRenderer\"},{\"attributes\":{\"overlay\":{\"id\":\"c9c8b8f0-c3f2-45eb-b036-579dfcd0be74\",\"type\":\"BoxAnnotation\"},\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"1d59e2c2-4ec9-4711-8541-d7a44a0bd6bf\",\"type\":\"BoxZoomTool\"},{\"attributes\":{},\"id\":\"3a55024a-c4a1-4338-8ecb-0a125a961ad6\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"formatter\":{\"id\":\"3a55024a-c4a1-4338-8ecb-0a125a961ad6\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"e9efff0e-ea1e-4859-ad6d-bc8ed99c56db\",\"type\":\"BasicTicker\"}},\"id\":\"03b5426f-c326-43c3-b7c6-b60fb3f43863\",\"type\":\"LinearAxis\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"162a1f5a-342b-4239-a669-78605e25a700\",\"type\":\"ResetTool\"},{\"attributes\":{\"plot\":null,\"text\":\"Africa\"},\"id\":\"4fa38ed6-3372-4e8d-8fc1-f7ebdad1a2d4\",\"type\":\"Title\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"5d3fab04-b820-45ec-abd9-355d24e4c61e\",\"type\":\"PanTool\"},{\"attributes\":{\"line_alpha\":{\"value\":0.1},\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"0f117ac5-261b-4c48-b57a-820a953caf3e\",\"type\":\"Line\"},{\"attributes\":{},\"id\":\"e9efff0e-ea1e-4859-ad6d-bc8ed99c56db\",\"type\":\"BasicTicker\"},{\"attributes\":{},\"id\":\"309484a7-a675-44a3-959f-69764d9c2718\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"ad2536aa-187c-4e78-9a96-eab4ded95a4e\",\"type\":\"BasicTicker\"}},\"id\":\"20153cbf-6386-4515-91d1-5bf682262670\",\"type\":\"Grid\"},{\"attributes\":{},\"id\":\"4daa96f2-cc3e-45d0-b10a-d206d03c9d52\",\"type\":\"ToolEvents\"},{\"attributes\":{\"callback\":null},\"id\":\"56c7fbe4-6e9f-4a7d-ba91-435a58d41586\",\"type\":\"DataRange1d\"},{\"attributes\":{\"dimension\":1,\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"e9efff0e-ea1e-4859-ad6d-bc8ed99c56db\",\"type\":\"BasicTicker\"}},\"id\":\"ddaf52a2-3930-4c57-b4d5-c310db311eb0\",\"type\":\"Grid\"},{\"attributes\":{},\"id\":\"ad2536aa-187c-4e78-9a96-eab4ded95a4e\",\"type\":\"BasicTicker\"},{\"attributes\":{\"below\":[{\"id\":\"37309516-e24a-4832-a674-968084b4ea29\",\"type\":\"LinearAxis\"}],\"left\":[{\"id\":\"03b5426f-c326-43c3-b7c6-b60fb3f43863\",\"type\":\"LinearAxis\"}],\"renderers\":[{\"id\":\"37309516-e24a-4832-a674-968084b4ea29\",\"type\":\"LinearAxis\"},{\"id\":\"20153cbf-6386-4515-91d1-5bf682262670\",\"type\":\"Grid\"},{\"id\":\"03b5426f-c326-43c3-b7c6-b60fb3f43863\",\"type\":\"LinearAxis\"},{\"id\":\"ddaf52a2-3930-4c57-b4d5-c310db311eb0\",\"type\":\"Grid\"},{\"id\":\"c9c8b8f0-c3f2-45eb-b036-579dfcd0be74\",\"type\":\"BoxAnnotation\"},{\"id\":\"6ffe6874-fc91-4928-93ea-13db2b80cb88\",\"type\":\"GlyphRenderer\"}],\"title\":{\"id\":\"4fa38ed6-3372-4e8d-8fc1-f7ebdad1a2d4\",\"type\":\"Title\"},\"tool_events\":{\"id\":\"4daa96f2-cc3e-45d0-b10a-d206d03c9d52\",\"type\":\"ToolEvents\"},\"toolbar\":{\"id\":\"8d96ce16-a7dd-49b5-8141-7b7cd1f75a77\",\"type\":\"Toolbar\"},\"x_range\":{\"id\":\"56c7fbe4-6e9f-4a7d-ba91-435a58d41586\",\"type\":\"DataRange1d\"},\"y_range\":{\"id\":\"8413d19b-4f3f-4643-ac4f-31b7f078a2c7\",\"type\":\"DataRange1d\"}},\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},{\"attributes\":{\"formatter\":{\"id\":\"309484a7-a675-44a3-959f-69764d9c2718\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"ad2536aa-187c-4e78-9a96-eab4ded95a4e\",\"type\":\"BasicTicker\"}},\"id\":\"37309516-e24a-4832-a674-968084b4ea29\",\"type\":\"LinearAxis\"},{\"attributes\":{\"active_drag\":\"auto\",\"active_scroll\":\"auto\",\"active_tap\":\"auto\",\"logo\":null,\"tools\":[{\"id\":\"1d59e2c2-4ec9-4711-8541-d7a44a0bd6bf\",\"type\":\"BoxZoomTool\"},{\"id\":\"5d3fab04-b820-45ec-abd9-355d24e4c61e\",\"type\":\"PanTool\"},{\"id\":\"cb42e8f3-86c7-4673-ac1e-5c4bcce85a96\",\"type\":\"WheelZoomTool\"},{\"id\":\"162a1f5a-342b-4239-a669-78605e25a700\",\"type\":\"ResetTool\"}]},\"id\":\"8d96ce16-a7dd-49b5-8141-7b7cd1f75a77\",\"type\":\"Toolbar\"},{\"attributes\":{\"callback\":null,\"column_names\":[\"x\",\"y\"],\"data\":{\"x\":[1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010],\"y\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]}},\"id\":\"449cacb4-6fca-4e7b-bb36-a0a544634110\",\"type\":\"ColumnDataSource\"}],\"root_ids\":[\"ec17fdba-a3ce-4111-9857-9ea721a40d21\"]},\"title\":\"Bokeh Application\",\"version\":\"0.12.5\"}};\n",
|
|
" var render_items = [{\"docid\":\"eb63a0a0-4597-4458-bc57-97af1d5120b2\",\"elementid\":\"fcb81158-f83c-4470-a24d-6862287beffa\",\"modelid\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\"}];\n",
|
|
" \n",
|
|
" Bokeh.embed.embed_items(docs_json, render_items);\n",
|
|
" };\n",
|
|
" if (document.readyState != \"loading\") fn();\n",
|
|
" else document.addEventListener(\"DOMContentLoaded\", fn);\n",
|
|
" })();\n",
|
|
" },\n",
|
|
" function(Bokeh) {\n",
|
|
" }\n",
|
|
" ];\n",
|
|
" \n",
|
|
" function run_inline_js() {\n",
|
|
" \n",
|
|
" if ((window.Bokeh !== undefined) || (force === true)) {\n",
|
|
" for (var i = 0; i < inline_js.length; i++) {\n",
|
|
" inline_js[i](window.Bokeh);\n",
|
|
" }if (force === true) {\n",
|
|
" display_loaded();\n",
|
|
" }} else if (Date.now() < window._bokeh_timeout) {\n",
|
|
" setTimeout(run_inline_js, 100);\n",
|
|
" } else if (!window._bokeh_failed_load) {\n",
|
|
" console.log(\"Bokeh: BokehJS failed to load within specified timeout.\");\n",
|
|
" window._bokeh_failed_load = true;\n",
|
|
" } else if (force !== true) {\n",
|
|
" var cell = $(document.getElementById(\"fcb81158-f83c-4470-a24d-6862287beffa\")).parents('.cell').data().cell;\n",
|
|
" cell.output_area.append_execute_result(NB_LOAD_WARNING)\n",
|
|
" }\n",
|
|
" \n",
|
|
" }\n",
|
|
" \n",
|
|
" if (window._bokeh_is_loading === 0) {\n",
|
|
" console.log(\"Bokeh: BokehJS loaded, going straight to plotting\");\n",
|
|
" run_inline_js();\n",
|
|
" } else {\n",
|
|
" load_libs(js_urls, function() {\n",
|
|
" console.log(\"Bokeh: BokehJS plotting callback run at\", now());\n",
|
|
" run_inline_js();\n",
|
|
" });\n",
|
|
" }\n",
|
|
" }(this));\n",
|
|
"</script>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"p = figure(title=nations[1], logo=None, tools=\"box_zoom,pan,wheel_zoom,reset\",)\n",
|
|
"p.line(x=df2[nations[1]].index, y=df2[nations[1]].values)\n",
|
|
"# p.title(nations[1])\n",
|
|
"show(p)"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": []
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 41,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"from bokeh.embed import components"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 42,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"script, div = components(line)"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 43,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"name": "stdout",
|
|
"output_type": "stream",
|
|
"text": [
|
|
"\n",
|
|
"<script type=\"text/javascript\">\n",
|
|
" (function() {\n",
|
|
" var fn = function() {\n",
|
|
" Bokeh.safely(function() {\n",
|
|
" var docs_json = {\"6d161fcc-521f-4cd6-a1af-b05ae83f01ac\":{\"roots\":{\"references\":[{\"attributes\":{\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"156dc6eb-4ea8-4e23-a70a-6368bb742434\",\"type\":\"Line\"},{\"attributes\":{\"bottom_units\":\"screen\",\"fill_alpha\":{\"value\":0.5},\"fill_color\":{\"value\":\"lightgrey\"},\"left_units\":\"screen\",\"level\":\"overlay\",\"line_alpha\":{\"value\":1.0},\"line_color\":{\"value\":\"black\"},\"line_dash\":[4,4],\"line_width\":{\"value\":2},\"plot\":null,\"render_mode\":\"css\",\"right_units\":\"screen\",\"top_units\":\"screen\"},\"id\":\"c9c8b8f0-c3f2-45eb-b036-579dfcd0be74\",\"type\":\"BoxAnnotation\"},{\"attributes\":{\"plot\":null,\"text\":\"\"},\"id\":\"4b73b136-3311-4f65-8330-daea1def2864\",\"type\":\"Title\"},{\"attributes\":{\"line_alpha\":{\"value\":0.1},\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"7f837bd2-2b21-4aa5-aa61-d25c83dacc49\",\"type\":\"Line\"},{\"attributes\":{},\"id\":\"94cd5370-89be-42da-b936-abe68cbca538\",\"type\":\"BasicTicker\"},{\"attributes\":{\"data_source\":{\"id\":\"449cacb4-6fca-4e7b-bb36-a0a544634110\",\"type\":\"ColumnDataSource\"},\"glyph\":{\"id\":\"156dc6eb-4ea8-4e23-a70a-6368bb742434\",\"type\":\"Line\"},\"hover_glyph\":null,\"muted_glyph\":null,\"nonselection_glyph\":{\"id\":\"0f117ac5-261b-4c48-b57a-820a953caf3e\",\"type\":\"Line\"},\"selection_glyph\":null},\"id\":\"6ffe6874-fc91-4928-93ea-13db2b80cb88\",\"type\":\"GlyphRenderer\"},{\"attributes\":{\"formatter\":{\"id\":\"3a55024a-c4a1-4338-8ecb-0a125a961ad6\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"e9efff0e-ea1e-4859-ad6d-bc8ed99c56db\",\"type\":\"BasicTicker\"}},\"id\":\"03b5426f-c326-43c3-b7c6-b60fb3f43863\",\"type\":\"LinearAxis\"},{\"attributes\":{\"below\":[{\"id\":\"cc9604c0-5dec-4ab2-9bd4-66b05c4dd8fd\",\"type\":\"LinearAxis\"}],\"css_classes\":null,\"left\":[{\"id\":\"60111614-9140-4121-a862-6ecd025b904a\",\"type\":\"CategoricalAxis\"}],\"renderers\":[{\"id\":\"61fcbebc-91f3-4f43-b3b5-07d7fea5a5f7\",\"type\":\"BoxAnnotation\"},{\"id\":\"b22ad6bc-f1d6-4a9b-b106-a3ab73e67ad1\",\"type\":\"GlyphRenderer\"},{\"id\":\"0358e192-8451-4aa8-92f1-21ac4bf4a181\",\"type\":\"Legend\"},{\"id\":\"cc9604c0-5dec-4ab2-9bd4-66b05c4dd8fd\",\"type\":\"LinearAxis\"},{\"id\":\"60111614-9140-4121-a862-6ecd025b904a\",\"type\":\"CategoricalAxis\"},{\"id\":\"6d195c2f-d83b-4b32-a53c-e47744ecb5f7\",\"type\":\"Grid\"},{\"id\":\"6ea17408-acf9-42f1-826c-f20d54d75240\",\"type\":\"Grid\"}],\"title\":{\"id\":\"c5f7c945-40c4-46c3-b5a6-a4d1306e707e\",\"type\":\"Title\"},\"tool_events\":{\"id\":\"a42b5d60-2f8a-4a72-b3ad-22e5ed5ed7d1\",\"type\":\"ToolEvents\"},\"toolbar\":{\"id\":\"629d2530-83c3-408a-907f-08b5a6dabfb5\",\"type\":\"Toolbar\"},\"x_mapper_type\":\"auto\",\"x_range\":{\"id\":\"003e9492-e39f-4660-b44e-a1facfa9dc50\",\"type\":\"Range1d\"},\"y_mapper_type\":\"auto\",\"y_range\":{\"id\":\"fc286977-4588-46c6-8a18-058d5e2ff4f6\",\"type\":\"FactorRange\"}},\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"},{\"attributes\":{\"line_alpha\":{\"value\":0.1},\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"505330f8-66df-4e5b-b7fb-36198592add0\",\"type\":\"Line\"},{\"attributes\":{\"line_alpha\":{\"value\":0.1},\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"0f117ac5-261b-4c48-b57a-820a953caf3e\",\"type\":\"Line\"},{\"attributes\":{\"callback\":null,\"column_names\":[\"x\",\"y\"],\"data\":{\"x\":[1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010],\"y\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]}},\"id\":\"a9eada67-c43c-4079-a1e9-5d2c93e6021f\",\"type\":\"ColumnDataSource\"},{\"attributes\":{\"dimension\":1,\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"5e858cf5-6f2f-465c-b313-9024b529813c\",\"type\":\"CategoricalTicker\"}},\"id\":\"6ea17408-acf9-42f1-826c-f20d54d75240\",\"type\":\"Grid\"},{\"attributes\":{\"plot\":null,\"text\":\"line\"},\"id\":\"c5f7c945-40c4-46c3-b5a6-a4d1306e707e\",\"type\":\"Title\"},{\"attributes\":{\"callback\":null},\"id\":\"56c7fbe4-6e9f-4a7d-ba91-435a58d41586\",\"type\":\"DataRange1d\"},{\"attributes\":{\"active_drag\":\"auto\",\"active_scroll\":\"auto\",\"active_tap\":\"auto\",\"tools\":[{\"id\":\"02087c67-8e54-42ce-8feb-ba80fb4a441a\",\"type\":\"PanTool\"},{\"id\":\"26b0d08d-f17d-41b7-9cdf-4bbd8e619eb6\",\"type\":\"WheelZoomTool\"},{\"id\":\"0303dc25-9ba1-42f1-8f9a-ef67becaf4c6\",\"type\":\"BoxZoomTool\"},{\"id\":\"ac761a99-9c59-4f75-aa87-3fb6948e4a5f\",\"type\":\"SaveTool\"},{\"id\":\"7ff4227c-6ba1-4d53-a8e0-daafe5da0bc5\",\"type\":\"ResetTool\"},{\"id\":\"55989fa4-7ae2-49c7-904e-075a8ae77936\",\"type\":\"HelpTool\"}]},\"id\":\"629d2530-83c3-408a-907f-08b5a6dabfb5\",\"type\":\"Toolbar\"},{\"attributes\":{},\"id\":\"ad2536aa-187c-4e78-9a96-eab4ded95a4e\",\"type\":\"BasicTicker\"},{\"attributes\":{\"bottom_units\":\"screen\",\"fill_alpha\":{\"value\":0.5},\"fill_color\":{\"value\":\"lightgrey\"},\"left_units\":\"screen\",\"level\":\"overlay\",\"line_alpha\":{\"value\":1.0},\"line_color\":{\"value\":\"black\"},\"line_dash\":[4,4],\"line_width\":{\"value\":2},\"plot\":null,\"render_mode\":\"css\",\"right_units\":\"screen\",\"top_units\":\"screen\"},\"id\":\"61fcbebc-91f3-4f43-b3b5-07d7fea5a5f7\",\"type\":\"BoxAnnotation\"},{\"attributes\":{\"below\":[{\"id\":\"37309516-e24a-4832-a674-968084b4ea29\",\"type\":\"LinearAxis\"}],\"left\":[{\"id\":\"03b5426f-c326-43c3-b7c6-b60fb3f43863\",\"type\":\"LinearAxis\"}],\"renderers\":[{\"id\":\"37309516-e24a-4832-a674-968084b4ea29\",\"type\":\"LinearAxis\"},{\"id\":\"20153cbf-6386-4515-91d1-5bf682262670\",\"type\":\"Grid\"},{\"id\":\"03b5426f-c326-43c3-b7c6-b60fb3f43863\",\"type\":\"LinearAxis\"},{\"id\":\"ddaf52a2-3930-4c57-b4d5-c310db311eb0\",\"type\":\"Grid\"},{\"id\":\"c9c8b8f0-c3f2-45eb-b036-579dfcd0be74\",\"type\":\"BoxAnnotation\"},{\"id\":\"6ffe6874-fc91-4928-93ea-13db2b80cb88\",\"type\":\"GlyphRenderer\"}],\"title\":{\"id\":\"4fa38ed6-3372-4e8d-8fc1-f7ebdad1a2d4\",\"type\":\"Title\"},\"tool_events\":{\"id\":\"4daa96f2-cc3e-45d0-b10a-d206d03c9d52\",\"type\":\"ToolEvents\"},\"toolbar\":{\"id\":\"8d96ce16-a7dd-49b5-8141-7b7cd1f75a77\",\"type\":\"Toolbar\"},\"x_range\":{\"id\":\"56c7fbe4-6e9f-4a7d-ba91-435a58d41586\",\"type\":\"DataRange1d\"},\"y_range\":{\"id\":\"8413d19b-4f3f-4643-ac4f-31b7f078a2c7\",\"type\":\"DataRange1d\"}},\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},{\"attributes\":{},\"id\":\"57379d76-2fdc-4b5d-a512-7ad4d3be4e04\",\"type\":\"ToolEvents\"},{\"attributes\":{\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"}},\"id\":\"02087c67-8e54-42ce-8feb-ba80fb4a441a\",\"type\":\"PanTool\"},{\"attributes\":{\"callback\":null,\"column_names\":[\"x\",\"y\"],\"data\":{\"x\":[1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010],\"y\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]}},\"id\":\"449cacb4-6fca-4e7b-bb36-a0a544634110\",\"type\":\"ColumnDataSource\"},{\"attributes\":{\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"}},\"id\":\"26b0d08d-f17d-41b7-9cdf-4bbd8e619eb6\",\"type\":\"WheelZoomTool\"},{\"attributes\":{\"overlay\":{\"id\":\"61fcbebc-91f3-4f43-b3b5-07d7fea5a5f7\",\"type\":\"BoxAnnotation\"},\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"}},\"id\":\"0303dc25-9ba1-42f1-8f9a-ef67becaf4c6\",\"type\":\"BoxZoomTool\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"cb42e8f3-86c7-4673-ac1e-5c4bcce85a96\",\"type\":\"WheelZoomTool\"},{\"attributes\":{\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"}},\"id\":\"ac761a99-9c59-4f75-aa87-3fb6948e4a5f\",\"type\":\"SaveTool\"},{\"attributes\":{\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"}},\"id\":\"7ff4227c-6ba1-4d53-a8e0-daafe5da0bc5\",\"type\":\"ResetTool\"},{\"attributes\":{\"callback\":null},\"id\":\"8413d19b-4f3f-4643-ac4f-31b7f078a2c7\",\"type\":\"DataRange1d\"},{\"attributes\":{\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"}},\"id\":\"55989fa4-7ae2-49c7-904e-075a8ae77936\",\"type\":\"HelpTool\"},{\"attributes\":{\"axis_label\":\"index\",\"formatter\":{\"id\":\"4397d1e2-010d-4fa3-8a4e-2fad8a4fd615\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"bf2b267f-e444-4e77-8004-96989033f40d\",\"type\":\"BasicTicker\"}},\"id\":\"cc9604c0-5dec-4ab2-9bd4-66b05c4dd8fd\",\"type\":\"LinearAxis\"},{\"attributes\":{\"callback\":null},\"id\":\"f38c34c3-9134-4a6c-9c83-ec0f531807d3\",\"type\":\"DataRange1d\"},{\"attributes\":{\"callback\":null},\"id\":\"f028a520-737b-4104-9ec3-f9da7f524815\",\"type\":\"DataRange1d\"},{\"attributes\":{},\"id\":\"8757dd43-3c27-4036-b33b-e4639b60dafb\",\"type\":\"BasicTicker\"},{\"attributes\":{\"line_color\":{\"value\":\"#f22c40\"},\"line_width\":{\"value\":2},\"x\":{\"field\":\"x_values\"},\"y\":{\"field\":\"y_values\"}},\"id\":\"61c87224-0e9c-4da8-be61-1796a33fa696\",\"type\":\"Line\"},{\"attributes\":{\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"94cd5370-89be-42da-b936-abe68cbca538\",\"type\":\"BasicTicker\"}},\"id\":\"cd319412-d0d1-4ac7-9952-ca0eefe16ab1\",\"type\":\"Grid\"},{\"attributes\":{\"overlay\":{\"id\":\"c9c8b8f0-c3f2-45eb-b036-579dfcd0be74\",\"type\":\"BoxAnnotation\"},\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"1d59e2c2-4ec9-4711-8541-d7a44a0bd6bf\",\"type\":\"BoxZoomTool\"},{\"attributes\":{},\"id\":\"3a55024a-c4a1-4338-8ecb-0a125a961ad6\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"262844fc-9117-4358-b8bc-916297cb1f58\",\"type\":\"Line\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"162a1f5a-342b-4239-a669-78605e25a700\",\"type\":\"ResetTool\"},{\"attributes\":{\"plot\":null,\"text\":\"Africa\"},\"id\":\"4fa38ed6-3372-4e8d-8fc1-f7ebdad1a2d4\",\"type\":\"Title\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"5d3fab04-b820-45ec-abd9-355d24e4c61e\",\"type\":\"PanTool\"},{\"attributes\":{\"data_source\":{\"id\":\"a9eec0ba-fee3-4cc1-b8f0-eddc3b11957c\",\"type\":\"ColumnDataSource\"},\"glyph\":{\"id\":\"61c87224-0e9c-4da8-be61-1796a33fa696\",\"type\":\"Line\"},\"hover_glyph\":null,\"muted_glyph\":null},\"id\":\"b22ad6bc-f1d6-4a9b-b106-a3ab73e67ad1\",\"type\":\"GlyphRenderer\"},{\"attributes\":{\"below\":[{\"id\":\"ab8fe524-6b8d-4653-a357-76f229f5d12a\",\"type\":\"LinearAxis\"}],\"left\":[{\"id\":\"b9bacd78-dd5c-458b-8094-564bea1c1191\",\"type\":\"LinearAxis\"}],\"renderers\":[{\"id\":\"ab8fe524-6b8d-4653-a357-76f229f5d12a\",\"type\":\"LinearAxis\"},{\"id\":\"cd319412-d0d1-4ac7-9952-ca0eefe16ab1\",\"type\":\"Grid\"},{\"id\":\"b9bacd78-dd5c-458b-8094-564bea1c1191\",\"type\":\"LinearAxis\"},{\"id\":\"7fb57784-7cbf-432d-be0a-5d25dabc77d8\",\"type\":\"Grid\"},{\"id\":\"2a3b581d-fff5-40eb-bc4c-11ac6b3b4dc1\",\"type\":\"BoxAnnotation\"},{\"id\":\"f60b781d-06ca-474b-ba32-d997b6b3c1f2\",\"type\":\"GlyphRenderer\"}],\"title\":{\"id\":\"9bc86622-8f01-40a7-8030-2f62896d2827\",\"type\":\"Title\"},\"tool_events\":{\"id\":\"57379d76-2fdc-4b5d-a512-7ad4d3be4e04\",\"type\":\"ToolEvents\"},\"toolbar\":{\"id\":\"6486eada-a460-46c0-97be-c892fa377ff2\",\"type\":\"Toolbar\"},\"x_range\":{\"id\":\"f38c34c3-9134-4a6c-9c83-ec0f531807d3\",\"type\":\"DataRange1d\"},\"y_range\":{\"id\":\"f028a520-737b-4104-9ec3-f9da7f524815\",\"type\":\"DataRange1d\"}},\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"},{\"attributes\":{},\"id\":\"e9efff0e-ea1e-4859-ad6d-bc8ed99c56db\",\"type\":\"BasicTicker\"},{\"attributes\":{},\"id\":\"27c926bc-837d-45ce-9426-e4de54392823\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"below\":[{\"id\":\"b5e0f6eb-9f90-4057-8799-17bff22d6a82\",\"type\":\"LinearAxis\"}],\"css_classes\":null,\"left\":[{\"id\":\"7fbb2276-3057-4915-b08b-7d9274deae3d\",\"type\":\"LinearAxis\"}],\"renderers\":[{\"id\":\"b5e0f6eb-9f90-4057-8799-17bff22d6a82\",\"type\":\"LinearAxis\"},{\"id\":\"3986e6f7-6a83-4ae3-a25c-03098b578f9c\",\"type\":\"Grid\"},{\"id\":\"7fbb2276-3057-4915-b08b-7d9274deae3d\",\"type\":\"LinearAxis\"},{\"id\":\"87c91aeb-c07c-4677-a09d-f1ee693398c8\",\"type\":\"Grid\"},{\"id\":\"33152d07-24f9-40ad-8504-36ac23eeb697\",\"type\":\"BoxAnnotation\"},{\"id\":\"30fc3d15-58cd-46c4-a55d-1154cb44561d\",\"type\":\"GlyphRenderer\"}],\"title\":{\"id\":\"4927f247-8afc-4c0f-a2a8-84f88fc27d94\",\"type\":\"Title\"},\"tool_events\":{\"id\":\"1ca4410a-ed3f-4e5d-a506-e4758d0d8463\",\"type\":\"ToolEvents\"},\"toolbar\":{\"id\":\"81509534-f5c7-4530-81e9-6a774664e436\",\"type\":\"Toolbar\"},\"x_mapper_type\":\"auto\",\"x_range\":{\"id\":\"4510dc1a-21b1-4edc-a717-58b451549570\",\"type\":\"DataRange1d\"},\"y_mapper_type\":\"auto\",\"y_range\":{\"id\":\"b5fe3105-4eab-441f-b73c-47d1ec898fad\",\"type\":\"DataRange1d\"}},\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"},{\"attributes\":{\"callback\":null,\"factors\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]},\"id\":\"fc286977-4588-46c6-8a18-058d5e2ff4f6\",\"type\":\"FactorRange\"},{\"attributes\":{\"callback\":null,\"column_names\":[\"x\",\"y\"],\"data\":{\"x\":[1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010],\"y\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]}},\"id\":\"bfcedb37-6405-4d8f-b5ce-035691691504\",\"type\":\"ColumnDataSource\"},{\"attributes\":{\"data_source\":{\"id\":\"bfcedb37-6405-4d8f-b5ce-035691691504\",\"type\":\"ColumnDataSource\"},\"glyph\":{\"id\":\"b6abeae3-2519-49bf-a182-b36cac2491f2\",\"type\":\"Line\"},\"hover_glyph\":null,\"muted_glyph\":null,\"nonselection_glyph\":{\"id\":\"74637d69-06b4-4a58-bc5f-6e15f8ad5dd3\",\"type\":\"Line\"},\"selection_glyph\":null},\"id\":\"30fc3d15-58cd-46c4-a55d-1154cb44561d\",\"type\":\"GlyphRenderer\"},{\"attributes\":{},\"id\":\"309484a7-a675-44a3-959f-69764d9c2718\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"plot\":null,\"text\":\"Africa\"},\"id\":\"4927f247-8afc-4c0f-a2a8-84f88fc27d94\",\"type\":\"Title\"},{\"attributes\":{\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"ad2536aa-187c-4e78-9a96-eab4ded95a4e\",\"type\":\"BasicTicker\"}},\"id\":\"20153cbf-6386-4515-91d1-5bf682262670\",\"type\":\"Grid\"},{\"attributes\":{\"callback\":null},\"id\":\"4510dc1a-21b1-4edc-a717-58b451549570\",\"type\":\"DataRange1d\"},{\"attributes\":{\"active_drag\":\"auto\",\"active_scroll\":\"auto\",\"active_tap\":\"auto\",\"logo\":null,\"tools\":[{\"id\":\"582ba521-f2f4-42b6-af9b-1adc7d8dacf4\",\"type\":\"PanTool\"},{\"id\":\"4fd6be2e-5948-426e-9377-9efc142a3148\",\"type\":\"WheelZoomTool\"},{\"id\":\"eed33c79-33c6-4ddf-942c-0acc1088aacd\",\"type\":\"BoxZoomTool\"},{\"id\":\"7bc542db-0561-4468-8a4e-8fec31132aa7\",\"type\":\"SaveTool\"},{\"id\":\"0bb2e107-51f7-43ed-801a-1ead536fb959\",\"type\":\"ResetTool\"},{\"id\":\"549b512c-950a-4b19-80d4-e32c5840e686\",\"type\":\"HelpTool\"}]},\"id\":\"6486eada-a460-46c0-97be-c892fa377ff2\",\"type\":\"Toolbar\"},{\"attributes\":{},\"id\":\"1ca4410a-ed3f-4e5d-a506-e4758d0d8463\",\"type\":\"ToolEvents\"},{\"attributes\":{\"plot\":null,\"text\":\"Africa\"},\"id\":\"9bc86622-8f01-40a7-8030-2f62896d2827\",\"type\":\"Title\"},{\"attributes\":{\"active_drag\":\"auto\",\"active_scroll\":\"auto\",\"active_tap\":\"auto\",\"tools\":[{\"id\":\"dd67276a-4775-4f1e-9ef3-01257fe68116\",\"type\":\"PanTool\"},{\"id\":\"4de1aa07-725e-46c5-9bc2-20cee9525a8c\",\"type\":\"WheelZoomTool\"},{\"id\":\"e6c4f64d-911d-4710-a31f-5bde1b27e54c\",\"type\":\"BoxZoomTool\"},{\"id\":\"86a73317-1642-4cce-9f7e-2df1085a8eda\",\"type\":\"SaveTool\"},{\"id\":\"1fb06377-dc44-42c1-a372-57ce44ede6a1\",\"type\":\"ResetTool\"},{\"id\":\"5469b094-e111-419a-b038-a9173a75bac8\",\"type\":\"HelpTool\"}]},\"id\":\"81509534-f5c7-4530-81e9-6a774664e436\",\"type\":\"Toolbar\"},{\"attributes\":{},\"id\":\"4daa96f2-cc3e-45d0-b10a-d206d03c9d52\",\"type\":\"ToolEvents\"},{\"attributes\":{\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"bf2b267f-e444-4e77-8004-96989033f40d\",\"type\":\"BasicTicker\"}},\"id\":\"6d195c2f-d83b-4b32-a53c-e47744ecb5f7\",\"type\":\"Grid\"},{\"attributes\":{},\"id\":\"fb4f1e27-1e74-41cc-9ce4-8f04cbd62163\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"callback\":null},\"id\":\"b5fe3105-4eab-441f-b73c-47d1ec898fad\",\"type\":\"DataRange1d\"},{\"attributes\":{\"dimension\":1,\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"e9efff0e-ea1e-4859-ad6d-bc8ed99c56db\",\"type\":\"BasicTicker\"}},\"id\":\"ddaf52a2-3930-4c57-b4d5-c310db311eb0\",\"type\":\"Grid\"},{\"attributes\":{\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"b6abeae3-2519-49bf-a182-b36cac2491f2\",\"type\":\"Line\"},{\"attributes\":{\"data_source\":{\"id\":\"a9eada67-c43c-4079-a1e9-5d2c93e6021f\",\"type\":\"ColumnDataSource\"},\"glyph\":{\"id\":\"262844fc-9117-4358-b8bc-916297cb1f58\",\"type\":\"Line\"},\"hover_glyph\":null,\"muted_glyph\":null,\"nonselection_glyph\":{\"id\":\"7f837bd2-2b21-4aa5-aa61-d25c83dacc49\",\"type\":\"Line\"},\"selection_glyph\":null},\"id\":\"f60b781d-06ca-474b-ba32-d997b6b3c1f2\",\"type\":\"GlyphRenderer\"},{\"attributes\":{},\"id\":\"bf2b267f-e444-4e77-8004-96989033f40d\",\"type\":\"BasicTicker\"},{\"attributes\":{\"formatter\":{\"id\":\"27c926bc-837d-45ce-9426-e4de54392823\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"4a70c28b-e2e2-4722-9ce6-cf40120705a1\",\"type\":\"BasicTicker\"}},\"id\":\"b5e0f6eb-9f90-4057-8799-17bff22d6a82\",\"type\":\"LinearAxis\"},{\"attributes\":{\"formatter\":{\"id\":\"694e9257-e445-4b6c-8498-1e0954ab1d4d\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"8757dd43-3c27-4036-b33b-e4639b60dafb\",\"type\":\"BasicTicker\"}},\"id\":\"b9bacd78-dd5c-458b-8094-564bea1c1191\",\"type\":\"LinearAxis\"},{\"attributes\":{},\"id\":\"5e858cf5-6f2f-465c-b313-9024b529813c\",\"type\":\"CategoricalTicker\"},{\"attributes\":{},\"id\":\"4a70c28b-e2e2-4722-9ce6-cf40120705a1\",\"type\":\"BasicTicker\"},{\"attributes\":{\"formatter\":{\"id\":\"309484a7-a675-44a3-959f-69764d9c2718\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"ec17fdba-a3ce-4111-9857-9ea721a40d21\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"ad2536aa-187c-4e78-9a96-eab4ded95a4e\",\"type\":\"BasicTicker\"}},\"id\":\"37309516-e24a-4832-a674-968084b4ea29\",\"type\":\"LinearAxis\"},{\"attributes\":{\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"4a70c28b-e2e2-4722-9ce6-cf40120705a1\",\"type\":\"BasicTicker\"}},\"id\":\"3986e6f7-6a83-4ae3-a25c-03098b578f9c\",\"type\":\"Grid\"},{\"attributes\":{\"location\":\"top_left\",\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"}},\"id\":\"0358e192-8451-4aa8-92f1-21ac4bf4a181\",\"type\":\"Legend\"},{\"attributes\":{\"formatter\":{\"id\":\"f81331eb-859c-4764-9a18-df64f3cf39c8\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"a4c60638-8575-4b29-aeec-b1b92c31714c\",\"type\":\"BasicTicker\"}},\"id\":\"7fbb2276-3057-4915-b08b-7d9274deae3d\",\"type\":\"LinearAxis\"},{\"attributes\":{},\"id\":\"a4c60638-8575-4b29-aeec-b1b92c31714c\",\"type\":\"BasicTicker\"},{\"attributes\":{\"axis_label\":\"population\",\"formatter\":{\"id\":\"124ab899-89aa-47c9-a6a7-a6d3f56b6506\",\"type\":\"CategoricalTickFormatter\"},\"major_label_orientation\":0.7853981633974483,\"plot\":{\"id\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"subtype\":\"Chart\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"5e858cf5-6f2f-465c-b313-9024b529813c\",\"type\":\"CategoricalTicker\"}},\"id\":\"60111614-9140-4121-a862-6ecd025b904a\",\"type\":\"CategoricalAxis\"},{\"attributes\":{\"dimension\":1,\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"a4c60638-8575-4b29-aeec-b1b92c31714c\",\"type\":\"BasicTicker\"}},\"id\":\"87c91aeb-c07c-4677-a09d-f1ee693398c8\",\"type\":\"Grid\"},{\"attributes\":{\"line_alpha\":{\"value\":0.1},\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"74637d69-06b4-4a58-bc5f-6e15f8ad5dd3\",\"type\":\"Line\"},{\"attributes\":{\"active_drag\":\"auto\",\"active_scroll\":\"auto\",\"active_tap\":\"auto\",\"logo\":null,\"tools\":[{\"id\":\"1d59e2c2-4ec9-4711-8541-d7a44a0bd6bf\",\"type\":\"BoxZoomTool\"},{\"id\":\"5d3fab04-b820-45ec-abd9-355d24e4c61e\",\"type\":\"PanTool\"},{\"id\":\"cb42e8f3-86c7-4673-ac1e-5c4bcce85a96\",\"type\":\"WheelZoomTool\"},{\"id\":\"162a1f5a-342b-4239-a669-78605e25a700\",\"type\":\"ResetTool\"}]},\"id\":\"8d96ce16-a7dd-49b5-8141-7b7cd1f75a77\",\"type\":\"Toolbar\"},{\"attributes\":{\"formatter\":{\"id\":\"68df76ff-3219-4d98-8e5a-6352d2c87b2b\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"ec6e6a05-4005-4653-8e23-96ee5ec1a312\",\"type\":\"BasicTicker\"}},\"id\":\"6fcc1db4-2539-4c7f-ad87-50e77f8c9ddd\",\"type\":\"LinearAxis\"},{\"attributes\":{},\"id\":\"a62f85af-7d50-4afc-bb73-a11a0618c5c5\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"bottom_units\":\"screen\",\"fill_alpha\":{\"value\":0.5},\"fill_color\":{\"value\":\"lightgrey\"},\"left_units\":\"screen\",\"level\":\"overlay\",\"line_alpha\":{\"value\":1.0},\"line_color\":{\"value\":\"black\"},\"line_dash\":[4,4],\"line_width\":{\"value\":2},\"plot\":null,\"render_mode\":\"css\",\"right_units\":\"screen\",\"top_units\":\"screen\"},\"id\":\"33152d07-24f9-40ad-8504-36ac23eeb697\",\"type\":\"BoxAnnotation\"},{\"attributes\":{},\"id\":\"b9b73742-aa77-460f-91f0-233e18f33137\",\"type\":\"BasicTicker\"},{\"attributes\":{\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"f32d2548-0316-4e1a-bdc2-74872ed1dc7c\",\"type\":\"PanTool\"},{\"attributes\":{\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"dd67276a-4775-4f1e-9ef3-01257fe68116\",\"type\":\"PanTool\"},{\"attributes\":{\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"4fd6be2e-5948-426e-9377-9efc142a3148\",\"type\":\"WheelZoomTool\"},{\"attributes\":{\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"4de1aa07-725e-46c5-9bc2-20cee9525a8c\",\"type\":\"WheelZoomTool\"},{\"attributes\":{\"formatter\":{\"id\":\"fb4f1e27-1e74-41cc-9ce4-8f04cbd62163\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"94cd5370-89be-42da-b936-abe68cbca538\",\"type\":\"BasicTicker\"}},\"id\":\"ab8fe524-6b8d-4653-a357-76f229f5d12a\",\"type\":\"LinearAxis\"},{\"attributes\":{\"overlay\":{\"id\":\"33152d07-24f9-40ad-8504-36ac23eeb697\",\"type\":\"BoxAnnotation\"},\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"e6c4f64d-911d-4710-a31f-5bde1b27e54c\",\"type\":\"BoxZoomTool\"},{\"attributes\":{\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"7bc542db-0561-4468-8a4e-8fec31132aa7\",\"type\":\"SaveTool\"},{\"attributes\":{\"active_drag\":\"auto\",\"active_scroll\":\"auto\",\"active_tap\":\"auto\",\"tools\":[{\"id\":\"8ebc9849-59e8-4316-bf92-a72c999a4d45\",\"type\":\"PanTool\"},{\"id\":\"6f198f95-ac1c-4503-9b00-314de74586dc\",\"type\":\"WheelZoomTool\"},{\"id\":\"6735a7e3-54b7-4e76-aaaf-cafe1c432c3f\",\"type\":\"BoxZoomTool\"},{\"id\":\"2aa5dc7f-ff19-4aaa-89f9-9bf56498bb08\",\"type\":\"SaveTool\"},{\"id\":\"3e76a734-c4f6-442f-b995-ca0d0ebedd9a\",\"type\":\"ResetTool\"},{\"id\":\"7193a4ec-9dc3-4578-bef0-2093cd7fa92a\",\"type\":\"HelpTool\"}]},\"id\":\"9d5742ac-66ba-4ccf-be91-6c4a8ba7aea4\",\"type\":\"Toolbar\"},{\"attributes\":{\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"86a73317-1642-4cce-9f7e-2df1085a8eda\",\"type\":\"SaveTool\"},{\"attributes\":{},\"id\":\"83a85d35-afe4-44cb-abdf-24a2d91aac1f\",\"type\":\"ToolEvents\"},{\"attributes\":{\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"1fb06377-dc44-42c1-a372-57ce44ede6a1\",\"type\":\"ResetTool\"},{\"attributes\":{\"callback\":null},\"id\":\"ad376ae8-6340-42c5-a92b-12388d8894dc\",\"type\":\"DataRange1d\"},{\"attributes\":{\"plot\":{\"id\":\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"5469b094-e111-419a-b038-a9173a75bac8\",\"type\":\"HelpTool\"},{\"attributes\":{\"dimension\":1,\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"7adf8814-7b22-405d-8a97-1609591e5503\",\"type\":\"BasicTicker\"}},\"id\":\"d47705b3-25f7-41ac-96d6-583880e99497\",\"type\":\"Grid\"},{\"attributes\":{\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"c969e5b7-84c6-4110-8c31-0ae4063aaed7\",\"type\":\"SaveTool\"},{\"attributes\":{},\"id\":\"f81331eb-859c-4764-9a18-df64f3cf39c8\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"callback\":null},\"id\":\"08f7a174-067d-4796-8683-6219b7d5b773\",\"type\":\"DataRange1d\"},{\"attributes\":{\"plot\":null,\"text\":\"\"},\"id\":\"43e1cff4-6bb7-47f7-bbaf-b5cd9472887d\",\"type\":\"Title\"},{\"attributes\":{\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"0bb2e107-51f7-43ed-801a-1ead536fb959\",\"type\":\"ResetTool\"},{\"attributes\":{},\"id\":\"ec6e6a05-4005-4653-8e23-96ee5ec1a312\",\"type\":\"BasicTicker\"},{\"attributes\":{\"overlay\":{\"id\":\"2a3b581d-fff5-40eb-bc4c-11ac6b3b4dc1\",\"type\":\"BoxAnnotation\"},\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"eed33c79-33c6-4ddf-942c-0acc1088aacd\",\"type\":\"BoxZoomTool\"},{\"attributes\":{\"callback\":null,\"column_names\":[\"x_values\",\"y_values\"],\"data\":{\"chart_index\":[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null],\"x_values\":[1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010],\"y_values\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]}},\"id\":\"a9eec0ba-fee3-4cc1-b8f0-eddc3b11957c\",\"type\":\"ColumnDataSource\"},{\"attributes\":{},\"id\":\"660c8a53-ef7b-43c0-aaa1-89bb7ba03b74\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"formatter\":{\"id\":\"199545ce-dd62-4574-83ed-a1116e5911e5\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"b9b73742-aa77-460f-91f0-233e18f33137\",\"type\":\"BasicTicker\"}},\"id\":\"fda6a9a1-6fdb-4d9a-85f2-4dee310408cf\",\"type\":\"LinearAxis\"},{\"attributes\":{\"dimension\":1,\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"ec6e6a05-4005-4653-8e23-96ee5ec1a312\",\"type\":\"BasicTicker\"}},\"id\":\"4700d127-aad1-467b-b567-1e87c92163f9\",\"type\":\"Grid\"},{\"attributes\":{},\"id\":\"7adf8814-7b22-405d-8a97-1609591e5503\",\"type\":\"BasicTicker\"},{\"attributes\":{\"callback\":null,\"column_names\":[\"x\",\"y\"],\"data\":{\"x\":[1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010],\"y\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]}},\"id\":\"a4f35b60-f1f6-4fee-927f-e78beb96d7b4\",\"type\":\"ColumnDataSource\"},{\"attributes\":{\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"39dab8aa-a670-4dc0-92ad-ccef59ebd9ec\",\"type\":\"WheelZoomTool\"},{\"attributes\":{\"bottom_units\":\"screen\",\"fill_alpha\":{\"value\":0.5},\"fill_color\":{\"value\":\"lightgrey\"},\"left_units\":\"screen\",\"level\":\"overlay\",\"line_alpha\":{\"value\":1.0},\"line_color\":{\"value\":\"black\"},\"line_dash\":[4,4],\"line_width\":{\"value\":2},\"plot\":null,\"render_mode\":\"css\",\"right_units\":\"screen\",\"top_units\":\"screen\"},\"id\":\"2a3b581d-fff5-40eb-bc4c-11ac6b3b4dc1\",\"type\":\"BoxAnnotation\"},{\"attributes\":{\"data_source\":{\"id\":\"a4f35b60-f1f6-4fee-927f-e78beb96d7b4\",\"type\":\"ColumnDataSource\"},\"glyph\":{\"id\":\"093700ff-4a7f-45ef-9b02-7f165695c9af\",\"type\":\"Line\"},\"hover_glyph\":null,\"muted_glyph\":null,\"nonselection_glyph\":{\"id\":\"505330f8-66df-4e5b-b7fb-36198592add0\",\"type\":\"Line\"},\"selection_glyph\":null},\"id\":\"b3ed0319-1e00-4bd2-aea7-6bdf549ad1f7\",\"type\":\"GlyphRenderer\"},{\"attributes\":{\"below\":[{\"id\":\"fda6a9a1-6fdb-4d9a-85f2-4dee310408cf\",\"type\":\"LinearAxis\"}],\"css_classes\":null,\"left\":[{\"id\":\"6fcc1db4-2539-4c7f-ad87-50e77f8c9ddd\",\"type\":\"LinearAxis\"}],\"renderers\":[{\"id\":\"fda6a9a1-6fdb-4d9a-85f2-4dee310408cf\",\"type\":\"LinearAxis\"},{\"id\":\"bf0e1fcf-6224-473d-9431-fc669443ddc9\",\"type\":\"Grid\"},{\"id\":\"6fcc1db4-2539-4c7f-ad87-50e77f8c9ddd\",\"type\":\"LinearAxis\"},{\"id\":\"4700d127-aad1-467b-b567-1e87c92163f9\",\"type\":\"Grid\"},{\"id\":\"12f9298a-99f4-453e-b118-6db1c67dc1b1\",\"type\":\"BoxAnnotation\"},{\"id\":\"b3ed0319-1e00-4bd2-aea7-6bdf549ad1f7\",\"type\":\"GlyphRenderer\"}],\"title\":{\"id\":\"4b73b136-3311-4f65-8330-daea1def2864\",\"type\":\"Title\"},\"tool_events\":{\"id\":\"83a85d35-afe4-44cb-abdf-24a2d91aac1f\",\"type\":\"ToolEvents\"},\"toolbar\":{\"id\":\"9d5742ac-66ba-4ccf-be91-6c4a8ba7aea4\",\"type\":\"Toolbar\"},\"x_mapper_type\":\"auto\",\"x_range\":{\"id\":\"ad376ae8-6340-42c5-a92b-12388d8894dc\",\"type\":\"DataRange1d\"},\"y_mapper_type\":\"auto\",\"y_range\":{\"id\":\"08f7a174-067d-4796-8683-6219b7d5b773\",\"type\":\"DataRange1d\"}},\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"},{\"attributes\":{\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"b9b73742-aa77-460f-91f0-233e18f33137\",\"type\":\"BasicTicker\"}},\"id\":\"bf0e1fcf-6224-473d-9431-fc669443ddc9\",\"type\":\"Grid\"},{\"attributes\":{\"overlay\":{\"id\":\"12f9298a-99f4-453e-b118-6db1c67dc1b1\",\"type\":\"BoxAnnotation\"},\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"6735a7e3-54b7-4e76-aaaf-cafe1c432c3f\",\"type\":\"BoxZoomTool\"},{\"attributes\":{},\"id\":\"cb96529f-a950-4967-b425-26750b664b44\",\"type\":\"BasicTicker\"},{\"attributes\":{\"below\":[{\"id\":\"74e89614-d366-4ea3-a2d0-e4577d10ba35\",\"type\":\"LinearAxis\"}],\"css_classes\":null,\"left\":[{\"id\":\"075a9978-b91f-4a37-8d19-8ecda9dd0f8d\",\"type\":\"LinearAxis\"}],\"renderers\":[{\"id\":\"74e89614-d366-4ea3-a2d0-e4577d10ba35\",\"type\":\"LinearAxis\"},{\"id\":\"d64b66e5-c68f-4983-ab9e-df4fe4c9f9fd\",\"type\":\"Grid\"},{\"id\":\"075a9978-b91f-4a37-8d19-8ecda9dd0f8d\",\"type\":\"LinearAxis\"},{\"id\":\"d47705b3-25f7-41ac-96d6-583880e99497\",\"type\":\"Grid\"},{\"id\":\"3c19b188-91a2-46bd-83d4-6eac6a6fb92b\",\"type\":\"BoxAnnotation\"},{\"id\":\"a572ea9d-f984-4a4f-a47a-9cf5a9ed1bff\",\"type\":\"GlyphRenderer\"}],\"title\":{\"id\":\"43e1cff4-6bb7-47f7-bbaf-b5cd9472887d\",\"type\":\"Title\"},\"tool_events\":{\"id\":\"13f31456-67fb-42d7-8249-c38f90cb89b1\",\"type\":\"ToolEvents\"},\"toolbar\":{\"id\":\"fca29c07-29c8-42f5-a43e-34116ecc8cf3\",\"type\":\"Toolbar\"},\"x_mapper_type\":\"auto\",\"x_range\":{\"id\":\"4028b453-9ba7-47d0-b62a-f0126ca5e862\",\"type\":\"DataRange1d\"},\"y_mapper_type\":\"auto\",\"y_range\":{\"id\":\"345d1038-d70d-43a4-a6a1-3e1c7eb960cb\",\"type\":\"DataRange1d\"}},\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"},{\"attributes\":{\"callback\":null,\"end\":2013.0,\"start\":1977.0},\"id\":\"003e9492-e39f-4660-b44e-a1facfa9dc50\",\"type\":\"Range1d\"},{\"attributes\":{\"overlay\":{\"id\":\"3c19b188-91a2-46bd-83d4-6eac6a6fb92b\",\"type\":\"BoxAnnotation\"},\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"d0cb1e29-3cfb-46be-8d6f-d8d8c94d9bd8\",\"type\":\"BoxZoomTool\"},{\"attributes\":{\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"87a5e126-b017-4cd4-a6fa-96121494bd44\",\"type\":\"Line\"},{\"attributes\":{\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"549b512c-950a-4b19-80d4-e32c5840e686\",\"type\":\"HelpTool\"},{\"attributes\":{\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"8ebc9849-59e8-4316-bf92-a72c999a4d45\",\"type\":\"PanTool\"},{\"attributes\":{},\"id\":\"199545ce-dd62-4574-83ed-a1116e5911e5\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"3e76a734-c4f6-442f-b995-ca0d0ebedd9a\",\"type\":\"ResetTool\"},{\"attributes\":{\"data_source\":{\"id\":\"c6f19665-6801-4804-a668-f52e648f1452\",\"type\":\"ColumnDataSource\"},\"glyph\":{\"id\":\"87a5e126-b017-4cd4-a6fa-96121494bd44\",\"type\":\"Line\"},\"hover_glyph\":null,\"muted_glyph\":null,\"nonselection_glyph\":{\"id\":\"7c03f4a5-0e1b-4e6b-a3bb-305314f0d9d9\",\"type\":\"Line\"},\"selection_glyph\":null},\"id\":\"a572ea9d-f984-4a4f-a47a-9cf5a9ed1bff\",\"type\":\"GlyphRenderer\"},{\"attributes\":{},\"id\":\"4397d1e2-010d-4fa3-8a4e-2fad8a4fd615\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{},\"id\":\"694e9257-e445-4b6c-8498-1e0954ab1d4d\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{},\"id\":\"124ab899-89aa-47c9-a6a7-a6d3f56b6506\",\"type\":\"CategoricalTickFormatter\"},{\"attributes\":{\"bottom_units\":\"screen\",\"fill_alpha\":{\"value\":0.5},\"fill_color\":{\"value\":\"lightgrey\"},\"left_units\":\"screen\",\"level\":\"overlay\",\"line_alpha\":{\"value\":1.0},\"line_color\":{\"value\":\"black\"},\"line_dash\":[4,4],\"line_width\":{\"value\":2},\"plot\":null,\"render_mode\":\"css\",\"right_units\":\"screen\",\"top_units\":\"screen\"},\"id\":\"12f9298a-99f4-453e-b118-6db1c67dc1b1\",\"type\":\"BoxAnnotation\"},{\"attributes\":{\"bottom_units\":\"screen\",\"fill_alpha\":{\"value\":0.5},\"fill_color\":{\"value\":\"lightgrey\"},\"left_units\":\"screen\",\"level\":\"overlay\",\"line_alpha\":{\"value\":1.0},\"line_color\":{\"value\":\"black\"},\"line_dash\":[4,4],\"line_width\":{\"value\":2},\"plot\":null,\"render_mode\":\"css\",\"right_units\":\"screen\",\"top_units\":\"screen\"},\"id\":\"3c19b188-91a2-46bd-83d4-6eac6a6fb92b\",\"type\":\"BoxAnnotation\"},{\"attributes\":{},\"id\":\"a42b5d60-2f8a-4a72-b3ad-22e5ed5ed7d1\",\"type\":\"ToolEvents\"},{\"attributes\":{\"callback\":null},\"id\":\"4028b453-9ba7-47d0-b62a-f0126ca5e862\",\"type\":\"DataRange1d\"},{\"attributes\":{\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"2aa5dc7f-ff19-4aaa-89f9-9bf56498bb08\",\"type\":\"SaveTool\"},{\"attributes\":{\"callback\":null},\"id\":\"345d1038-d70d-43a4-a6a1-3e1c7eb960cb\",\"type\":\"DataRange1d\"},{\"attributes\":{\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"7193a4ec-9dc3-4578-bef0-2093cd7fa92a\",\"type\":\"HelpTool\"},{\"attributes\":{\"line_alpha\":{\"value\":0.1},\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"7c03f4a5-0e1b-4e6b-a3bb-305314f0d9d9\",\"type\":\"Line\"},{\"attributes\":{\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"cb96529f-a950-4967-b425-26750b664b44\",\"type\":\"BasicTicker\"}},\"id\":\"d64b66e5-c68f-4983-ab9e-df4fe4c9f9fd\",\"type\":\"Grid\"},{\"attributes\":{\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"a8bf4fad-f179-4b6c-9399-50ec982566dc\",\"type\":\"ResetTool\"},{\"attributes\":{\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"582ba521-f2f4-42b6-af9b-1adc7d8dacf4\",\"type\":\"PanTool\"},{\"attributes\":{},\"id\":\"13f31456-67fb-42d7-8249-c38f90cb89b1\",\"type\":\"ToolEvents\"},{\"attributes\":{\"plot\":{\"id\":\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"6f198f95-ac1c-4503-9b00-314de74586dc\",\"type\":\"WheelZoomTool\"},{\"attributes\":{\"active_drag\":\"auto\",\"active_scroll\":\"auto\",\"active_tap\":\"auto\",\"tools\":[{\"id\":\"f32d2548-0316-4e1a-bdc2-74872ed1dc7c\",\"type\":\"PanTool\"},{\"id\":\"39dab8aa-a670-4dc0-92ad-ccef59ebd9ec\",\"type\":\"WheelZoomTool\"},{\"id\":\"d0cb1e29-3cfb-46be-8d6f-d8d8c94d9bd8\",\"type\":\"BoxZoomTool\"},{\"id\":\"c969e5b7-84c6-4110-8c31-0ae4063aaed7\",\"type\":\"SaveTool\"},{\"id\":\"a8bf4fad-f179-4b6c-9399-50ec982566dc\",\"type\":\"ResetTool\"},{\"id\":\"dba7a316-778f-45db-be4b-e6c6980d3cd2\",\"type\":\"HelpTool\"}]},\"id\":\"fca29c07-29c8-42f5-a43e-34116ecc8cf3\",\"type\":\"Toolbar\"},{\"attributes\":{\"callback\":null,\"column_names\":[\"x\",\"y\"],\"data\":{\"x\":[1980,1981,1982,1983,1984,1985,1986,1987,1988,1989,1990,1991,1992,1993,1994,1995,1996,1997,1998,1999,2000,2001,2002,2003,2004,2005,2006,2007,2008,2009,2010],\"y\":[\"478.96479\",\"493.63386\",\"508.69882\",\"523.66026\",\"538.6777\",\"553.7385\",\"569.05927\",\"584.06285\",\"599.18529\",\"614.7485\",\"630.91638\",\"647.76698\",\"664.43368\",\"680.91751\",\"696.76671\",\"713.37126\",\"730.48755\",\"747.90581\",\"765.93193\",\"784.59937\",\"803.61288\",\"823.10298\",\"843.06171\",\"863.1923\",\"883.59024\",\"904.41715\",\"925.68403\",\"947.55885\",\"969.97221\",\"992.58225\",\"1015.47842\"]}},\"id\":\"c6f19665-6801-4804-a668-f52e648f1452\",\"type\":\"ColumnDataSource\"},{\"attributes\":{},\"id\":\"68df76ff-3219-4d98-8e5a-6352d2c87b2b\",\"type\":\"BasicTickFormatter\"},{\"attributes\":{\"line_color\":{\"value\":\"#1f77b4\"},\"x\":{\"field\":\"x\"},\"y\":{\"field\":\"y\"}},\"id\":\"093700ff-4a7f-45ef-9b02-7f165695c9af\",\"type\":\"Line\"},{\"attributes\":{\"formatter\":{\"id\":\"660c8a53-ef7b-43c0-aaa1-89bb7ba03b74\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"cb96529f-a950-4967-b425-26750b664b44\",\"type\":\"BasicTicker\"}},\"id\":\"74e89614-d366-4ea3-a2d0-e4577d10ba35\",\"type\":\"LinearAxis\"},{\"attributes\":{\"dimension\":1,\"plot\":{\"id\":\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"8757dd43-3c27-4036-b33b-e4639b60dafb\",\"type\":\"BasicTicker\"}},\"id\":\"7fb57784-7cbf-432d-be0a-5d25dabc77d8\",\"type\":\"Grid\"},{\"attributes\":{\"formatter\":{\"id\":\"a62f85af-7d50-4afc-bb73-a11a0618c5c5\",\"type\":\"BasicTickFormatter\"},\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"},\"ticker\":{\"id\":\"7adf8814-7b22-405d-8a97-1609591e5503\",\"type\":\"BasicTicker\"}},\"id\":\"075a9978-b91f-4a37-8d19-8ecda9dd0f8d\",\"type\":\"LinearAxis\"},{\"attributes\":{\"plot\":{\"id\":\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"subtype\":\"Figure\",\"type\":\"Plot\"}},\"id\":\"dba7a316-778f-45db-be4b-e6c6980d3cd2\",\"type\":\"HelpTool\"}],\"root_ids\":[\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\",\"b590e55f-8444-46ab-aedf-e99d40bbd75a\",\"f09a9a95-58dc-42ff-8d0f-fbfebec65473\",\"9c4d9103-2736-45bb-867a-7aabd1afb532\",\"27420f4a-7dd4-445d-a5f8-b8f072faf6cd\",\"ec17fdba-a3ce-4111-9857-9ea721a40d21\"]},\"title\":\"Bokeh Application\",\"version\":\"0.12.5\"}};\n",
|
|
" var render_items = [{\"docid\":\"6d161fcc-521f-4cd6-a1af-b05ae83f01ac\",\"elementid\":\"6f77071c-fe0e-43bb-afd5-8bd84b7d9d11\",\"modelid\":\"bfcd674f-e43f-4d7f-993f-6dd170ea1a7a\"}];\n",
|
|
" \n",
|
|
" Bokeh.embed.embed_items(docs_json, render_items);\n",
|
|
" });\n",
|
|
" };\n",
|
|
" if (document.readyState != \"loading\") fn();\n",
|
|
" else document.addEventListener(\"DOMContentLoaded\", fn);\n",
|
|
"})();\n",
|
|
"\n",
|
|
"</script>\n"
|
|
]
|
|
}
|
|
],
|
|
"source": [
|
|
"print(script)"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 21,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"name": "stdout",
|
|
"output_type": "stream",
|
|
"text": [
|
|
"\n",
|
|
"<div class=\"bk-root\">\n",
|
|
" <div class=\"bk-plotdiv\" id=\"878f6d02-4d72-4189-8357-bf6b6339dcf0\"></div>\n",
|
|
"</div>\n"
|
|
]
|
|
}
|
|
],
|
|
"source": [
|
|
"print(div)"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"import json"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"id_pos = script.find('elementid\":\"') + 12\n",
|
|
"divid = script[id_pos:id_pos+36]\n",
|
|
"script = script.replace(divid, 'bokeh-line')"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"print(script)"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"x_start = script.find('\"x_values\":') + 11\n",
|
|
"x_end = script.find(',\"y_values\":')\n",
|
|
"y_start = script.find('\"y_values\":') + 11\n",
|
|
"y_end = script[y_start:].find('}}') + y_start\n",
|
|
"\n",
|
|
"script = script.replace(script[x_start:x_end], 'newXvalues')\n",
|
|
"script = script.replace(script[y_start:y_end], 'newYvalues')"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"len('\"y_values\":')"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"script[y_start:].find('}}') + y_start"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 22,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
"import bokeh"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 23,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/plain": [
|
|
"'0.12.5'"
|
|
]
|
|
},
|
|
"execution_count": 23,
|
|
"metadata": {},
|
|
"output_type": "execute_result"
|
|
}
|
|
],
|
|
"source": [
|
|
"bokeh.__version__"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {
|
|
"collapsed": true
|
|
},
|
|
"outputs": [],
|
|
"source": []
|
|
}
|
|
],
|
|
"metadata": {
|
|
"kernelspec": {
|
|
"display_name": "Python [default]",
|
|
"language": "python",
|
|
"name": "python3"
|
|
},
|
|
"language_info": {
|
|
"codemirror_mode": {
|
|
"name": "ipython",
|
|
"version": 3
|
|
},
|
|
"file_extension": ".py",
|
|
"mimetype": "text/x-python",
|
|
"name": "python",
|
|
"nbconvert_exporter": "python",
|
|
"pygments_lexer": "ipython3",
|
|
"version": "3.6.1"
|
|
}
|
|
},
|
|
"nbformat": 4,
|
|
"nbformat_minor": 2
|
|
}
|