Last active
January 1, 2016 17:08
-
-
Save ramnathv/8174770 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype HTML> | |
<meta charset = 'utf-8'> | |
<html> | |
<head> | |
<script src='http://d3js.org/d3.v3.min.js' type='text/javascript'></script> | |
<script src='http://d3js.org/topojson.v1.min.js' type='text/javascript'></script> | |
<script src='http://datamaps.github.io/scripts/datamaps.all.min.js' type='text/javascript'></script> | |
<script src='http://cdnjs.cloudflare.com/ajax/libs/handlebars.js/1.0.0/handlebars.min.js' type='text/javascript'></script> | |
<style> | |
.rChart { | |
display: block; | |
margin-left: auto; | |
margin-right: auto; | |
width: 800px; | |
height: 400px; | |
} | |
</style> | |
</head> | |
<body> | |
<div id='chart4fd14a53066b' class='rChart datamaps'></div> | |
<script id='popup-template' type='text/x-handlebars-template'> | |
</script> | |
<script> | |
var chartParams = { | |
"dom": "chart4fd14a53066b", | |
"width": 800, | |
"height": 400, | |
"scope": "usa", | |
"fills": { | |
"5": "#F1EEF6", | |
"1": "#D7B5D8", | |
"4": "#DF65B0", | |
"3": "#DD1C77", | |
"2": "#980043" | |
}, | |
"data": { | |
"AK": { | |
"State": "Alaska", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.11, | |
"Adult_Obesity_Rate": 0.624, | |
"state": "AK", | |
"fillKey": 5 | |
}, | |
"AL": { | |
"State": "Alabama", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.17, | |
"Adult_Obesity_Rate": 0.623, | |
"state": "AL", | |
"fillKey": 5 | |
}, | |
"AR": { | |
"State": "Arkansas", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " Yes ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.16, | |
"Adult_Obesity_Rate": 0.619, | |
"state": "AR", | |
"fillKey": 4 | |
}, | |
"AZ": { | |
"State": "Arizona", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.12, | |
"Adult_Obesity_Rate": 0.535, | |
"state": "AZ", | |
"fillKey": 1 | |
}, | |
"CA": { | |
"State": "California", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.13, | |
"Adult_Obesity_Rate": 0.579, | |
"state": "CA", | |
"fillKey": 3 | |
}, | |
"CO": { | |
"State": "Colorado", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.1, | |
"Adult_Obesity_Rate": 0.523, | |
"state": "CO", | |
"fillKey": 1 | |
}, | |
"CT": { | |
"State": "Connecticut", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.12, | |
"Adult_Obesity_Rate": 0.552, | |
"state": "CT", | |
"fillKey": 2 | |
}, | |
"DE": { | |
"State": "Delaware", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.15, | |
"Adult_Obesity_Rate": 0.605, | |
"state": "DE", | |
"fillKey": 4 | |
}, | |
"FL": { | |
"State": "Florida", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " Yes ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.582, | |
"state": "FL", | |
"fillKey": 3 | |
}, | |
"GA": { | |
"State": "Georgia", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " Yes ", | |
"Childhood_Obesity_Rate": 0.16, | |
"Adult_Obesity_Rate": 0.605, | |
"state": "GA", | |
"fillKey": 4 | |
}, | |
"HI": { | |
"State": "Hawaii", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.13, | |
"Adult_Obesity_Rate": 0.514, | |
"state": "HI", | |
"fillKey": 1 | |
}, | |
"IA": { | |
"State": "Iowa", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.13, | |
"Adult_Obesity_Rate": 0.602, | |
"state": "IA", | |
"fillKey": 4 | |
}, | |
"ID": { | |
"State": "Idaho", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.1, | |
"Adult_Obesity_Rate": 0.583, | |
"state": "ID", | |
"fillKey": 3 | |
}, | |
"IL": { | |
"State": "Illinois", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " Yes ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.16, | |
"Adult_Obesity_Rate": 0.582, | |
"state": "IL", | |
"fillKey": 3 | |
}, | |
"IN": { | |
"State": "Indiana", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " Yes ", | |
"Childhood_Obesity_Rate": 0.16, | |
"Adult_Obesity_Rate": 0.595, | |
"state": "IN", | |
"fillKey": 3 | |
}, | |
"KS": { | |
"State": "Kansas", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.58, | |
"state": "KS", | |
"fillKey": 3 | |
}, | |
"KY": { | |
"State": "Kentucky", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.21, | |
"Adult_Obesity_Rate": 0.625, | |
"state": "KY", | |
"fillKey": 5 | |
}, | |
"LA": { | |
"State": "Louisiana", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.17, | |
"Adult_Obesity_Rate": 0.623, | |
"state": "LA", | |
"fillKey": 5 | |
}, | |
"MA": { | |
"State": "Massachusetts", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.529, | |
"state": "MA", | |
"fillKey": 1 | |
}, | |
"MD": { | |
"State": "Maryland", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " Yes ", | |
"Childhood_Obesity_Rate": 0.13, | |
"Adult_Obesity_Rate": 0.582, | |
"state": "MD", | |
"fillKey": 3 | |
}, | |
"ME": { | |
"State": "Maine", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.13, | |
"Adult_Obesity_Rate": 0.569, | |
"state": "ME", | |
"fillKey": 3 | |
}, | |
"MI": { | |
"State": "Michigan", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.605, | |
"state": "MI", | |
"fillKey": 4 | |
}, | |
"MN": { | |
"State": "Minnesota", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.1, | |
"Adult_Obesity_Rate": 0.594, | |
"state": "MN", | |
"fillKey": 3 | |
}, | |
"MO": { | |
"State": "Missouri", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " Yes ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.16, | |
"Adult_Obesity_Rate": 0.624, | |
"state": "MO", | |
"fillKey": 5 | |
}, | |
"MS": { | |
"State": "Mississippi", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.18, | |
"Adult_Obesity_Rate": 0.649, | |
"state": "MS", | |
"fillKey": 5 | |
}, | |
"MT": { | |
"State": "Montana", | |
"Approach_to_Address_Childhood_Obesity": " Physical education program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.11, | |
"Adult_Obesity_Rate": 0.547, | |
"state": "MT", | |
"fillKey": 2 | |
}, | |
"NC": { | |
"State": "North Carolina", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.19, | |
"Adult_Obesity_Rate": 0.594, | |
"state": "NC", | |
"fillKey": 3 | |
}, | |
"ND": { | |
"State": "North Dakota", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.12, | |
"Adult_Obesity_Rate": 0.62, | |
"state": "ND", | |
"fillKey": 4 | |
}, | |
"NE": { | |
"State": "Nebraska", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.12, | |
"Adult_Obesity_Rate": 0.602, | |
"state": "NE", | |
"fillKey": 4 | |
}, | |
"NH": { | |
"State": "New Hampshire", | |
"Approach_to_Address_Childhood_Obesity": " Physical education program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.13, | |
"Adult_Obesity_Rate": 0.574, | |
"state": "NH", | |
"fillKey": 3 | |
}, | |
"NJ": { | |
"State": "New Jersey", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.553, | |
"state": "NJ", | |
"fillKey": 2 | |
}, | |
"NM": { | |
"State": "New Mexico", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.17, | |
"Adult_Obesity_Rate": 0.582, | |
"state": "NM", | |
"fillKey": 3 | |
}, | |
"NV": { | |
"State": "Nevada", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.12, | |
"Adult_Obesity_Rate": 0.562, | |
"state": "NV", | |
"fillKey": 2 | |
}, | |
"NY": { | |
"State": "New York", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.15, | |
"Adult_Obesity_Rate": 0.568, | |
"state": "NY", | |
"fillKey": 3 | |
}, | |
"OH": { | |
"State": "Ohio", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.603, | |
"state": "OH", | |
"fillKey": 4 | |
}, | |
"OK": { | |
"State": "Oklahoma", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.15, | |
"Adult_Obesity_Rate": 0.606, | |
"state": "OK", | |
"fillKey": 4 | |
}, | |
"OR": { | |
"State": "Oregon", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.565, | |
"state": "OR", | |
"fillKey": 2 | |
}, | |
"PA": { | |
"State": "Pennsylvania", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " Yes ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.13, | |
"Adult_Obesity_Rate": 0.592, | |
"state": "PA", | |
"fillKey": 3 | |
}, | |
"RI": { | |
"State": "Rhode Island", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.12, | |
"Adult_Obesity_Rate": 0.558, | |
"state": "RI", | |
"fillKey": 2 | |
}, | |
"SC": { | |
"State": "South Carolina", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.19, | |
"Adult_Obesity_Rate": 0.623, | |
"state": "SC", | |
"fillKey": 5 | |
}, | |
"SD": { | |
"State": "South Dakota", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.12, | |
"Adult_Obesity_Rate": 0.607, | |
"state": "SD", | |
"fillKey": 4 | |
}, | |
"TN": { | |
"State": "Tennessee", | |
"Approach_to_Address_Childhood_Obesity": " School nutrition program ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " Yes ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.2, | |
"Adult_Obesity_Rate": 0.593, | |
"state": "TN", | |
"fillKey": 3 | |
}, | |
"TX": { | |
"State": "Texas", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.19, | |
"Adult_Obesity_Rate": 0.588, | |
"state": "TX", | |
"fillKey": 3 | |
}, | |
"UT": { | |
"State": "Utah", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.11, | |
"Adult_Obesity_Rate": 0.543, | |
"state": "UT", | |
"fillKey": 2 | |
}, | |
"VA": { | |
"State": "Virginia", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " Yes ", | |
"Childhood_Obesity_Rate": 0.11, | |
"Adult_Obesity_Rate": 0.589, | |
"state": "VA", | |
"fillKey": 3 | |
}, | |
"VT": { | |
"State": "Vermont", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.542, | |
"state": "VT", | |
"fillKey": 2 | |
}, | |
"WA": { | |
"State": "Washington", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.21, | |
"Adult_Obesity_Rate": 0.565, | |
"state": "WA", | |
"fillKey": 2 | |
}, | |
"WI": { | |
"State": "Wisconsin", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.09, | |
"Adult_Obesity_Rate": 0.591, | |
"state": "WI", | |
"fillKey": 3 | |
}, | |
"WV": { | |
"State": "West Virginia", | |
"Approach_to_Address_Childhood_Obesity": " Both ", | |
"State_Task_Force_Committee": " Yes ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.14, | |
"Adult_Obesity_Rate": 0.636, | |
"state": "WV", | |
"fillKey": 5 | |
}, | |
"WY": { | |
"State": "Wyoming", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " Yes ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.15, | |
"Adult_Obesity_Rate": 0.596, | |
"state": "WY", | |
"fillKey": 4 | |
}, | |
"NA": { | |
"State": "District of Columbia", | |
"Approach_to_Address_Childhood_Obesity": " None ", | |
"State_Task_Force_Committee": " No ", | |
"Mandates_BMI_Screening": " No ", | |
"Mandates_Obesity_Treatment_Coverage": " No ", | |
"Childhood_Obesity_Rate": 0.23, | |
"Adult_Obesity_Rate": 0.521, | |
"state": null, | |
"fillKey": 1 | |
} | |
}, | |
"id": "chart4fd14a53066b" | |
} | |
chartParams.element = document.getElementById('chart4fd14a53066b') | |
var mapchart4fd14a53066b = new Datamap(chartParams); | |
// draw a bubble map if specified | |
if (chartParams.bubbles) { | |
var bubbles = chartParams.bubbles | |
mapchart4fd14a53066b.bubbles(bubbles) | |
} | |
if (chartParams.labels){ | |
mapchart4fd14a53066b.labels() | |
} | |
</script> | |
<style> | |
.datamaps { | |
position: relative; | |
} | |
</style> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"metadata": { | |
"name": "rCharts_choro" | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ | |
{ | |
"cell_type": "heading", | |
"level": 1, | |
"metadata": {}, | |
"source": "Choropleth Maps with rCharts" | |
}, | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": "This is just a quick script expounding a bit on the example provided by [Ramnath Vaidyanathan](http://rcharts.io/viewer/?6735051#.Ur3MGN_xCak)." | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "%load_ext rmagic", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"output_type": "stream", | |
"stream": "stdout", | |
"text": "The rmagic extension is already loaded. To reload it, use:\n %reload_ext rmagic\n" | |
} | |
], | |
"prompt_number": 11 | |
}, | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": "We can first grab the example obesity data from Berkeley." | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "%%R\n\n# read data and replace dots in names with underscores\nobesity = read.csv(\n 'http://www.stat.berkeley.edu/classes/s133/data/obesity.csv',\n stringsAsFactors = F\n)\n\nprint(head(obesity))", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"metadata": {}, | |
"output_type": "display_data", | |
"text": " State Approach.to.Address.Childhood.Obesity State.Task.Force.Committee\n1 Alabama Both Yes \n2 Alaska None No \n3 Arizona Both Yes \n4 Arkansas Both Yes \n5 California School nutrition program No \n6 Colorado School nutrition program Yes \n Mandates.BMI.Screening Mandates.Obesity.Treatment.Coverage\n1 No No \n2 No No \n3 No No \n4 Yes No \n5 No No \n6 No No \n Childhood.Obesity.Rate Adult.Obesity.Rate\n1 0.17 0.623\n2 0.11 0.624\n3 0.12 0.535\n4 0.16 0.619\n5 0.13 0.579\n6 0.10 0.523\n" | |
} | |
], | |
"prompt_number": 12 | |
}, | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": "For some reason that may soon be apparenty, Ramnath has chosen to replace the periods in the variable names with underscores." | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "%%R\n\nnames(obesity) = gsub(\"\\\\.\", \"_\", names(obesity))\n\nprint(head(obesity))", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"metadata": {}, | |
"output_type": "display_data", | |
"text": " State Approach_to_Address_Childhood_Obesity State_Task_Force_Committee\n1 Alabama Both Yes \n2 Alaska None No \n3 Arizona Both Yes \n4 Arkansas Both Yes \n5 California School nutrition program No \n6 Colorado School nutrition program Yes \n Mandates_BMI_Screening Mandates_Obesity_Treatment_Coverage\n1 No No \n2 No No \n3 No No \n4 Yes No \n5 No No \n6 No No \n Childhood_Obesity_Rate Adult_Obesity_Rate\n1 0.17 0.623\n2 0.11 0.624\n3 0.12 0.535\n4 0.16 0.619\n5 0.13 0.579\n6 0.10 0.523\n" | |
} | |
], | |
"prompt_number": 13 | |
}, | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": "We also need to add abbreviated state names, presumably to sync up with the map." | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "%%R\n\nlibrary(plyr)\nlibrary(stringr)\n\n#Trim the white space from State and create an abbreviated version called state\nobesity = plyr::mutate(obesity, \n State = str_trim(State),\n state = state.abb[match(State, state.name)],\n)\n\nprint(head(obesity))", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"metadata": {}, | |
"output_type": "display_data", | |
"text": " State Approach_to_Address_Childhood_Obesity State_Task_Force_Committee\n1 Alabama Both Yes \n2 Alaska None No \n3 Arizona Both Yes \n4 Arkansas Both Yes \n5 California School nutrition program No \n6 Colorado School nutrition program Yes \n Mandates_BMI_Screening Mandates_Obesity_Treatment_Coverage\n1 No No \n2 No No \n3 No No \n4 Yes No \n5 No No \n6 No No \n Childhood_Obesity_Rate Adult_Obesity_Rate state\n1 0.17 0.623 AL\n2 0.11 0.624 AK\n3 0.12 0.535 AZ\n4 0.16 0.619 AR\n5 0.13 0.579 CA\n6 0.10 0.523 CO\n" | |
} | |
], | |
"prompt_number": 14 | |
}, | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": "A little reminder on what mutate does..." | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "%%R\nlibrary(plyr)\n\nprint(help(mutate))", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"output_type": "stream", | |
"stream": "stdout", | |
"text": "R Help on \u2018mutate\u2019mutate package:plyr R Documentation\n\n_\bM_\bu_\bt_\ba_\bt_\be _\ba _\bd_\ba_\bt_\ba _\bf_\br_\ba_\bm_\be _\bb_\by _\ba_\bd_\bd_\bi_\bn_\bg _\bn_\be_\bw _\bo_\br _\br_\be_\bp_\bl_\ba_\bc_\bi_\bn_\bg _\be_\bx_\bi_\bs_\bt_\bi_\bn_\bg _\bc_\bo_\bl_\bu_\bm_\bn_\bs.\n\n_\bD_\be_\bs_\bc_\br_\bi_\bp_\bt_\bi_\bo_\bn:\n\n This function is very similar to \u2018transform\u2019 but it executes the\n transformations iteratively so that later transformations can use\n the columns created by earlier transformations. Like transform,\n unnamed components are silently dropped.\n\n_\bU_\bs_\ba_\bg_\be:\n\n mutate(.data, ...)\n \n_\bA_\br_\bg_\bu_\bm_\be_\bn_\bt_\bs:\n\n .data: the data frame to transform\n\n ...: named parameters giving definitions of new columns.\n\n_\bD_\be_\bt_\ba_\bi_\bl_\bs:\n\n Mutate seems to be considerably faster than transform for large\n data frames.\n\n_\bS_\be_\be _\bA_\bl_\bs_\bo:\n\n \u2018subset\u2019, \u2018summarise\u2019, \u2018arrange\u2019. For another somewhat different\n approach to solving the same problem, see \u2018within\u2019.\n\n_\bE_\bx_\ba_\bm_\bp_\bl_\be_\bs:\n\n # Examples from transform\n mutate(airquality, Ozone = -Ozone)\n mutate(airquality, new = -Ozone, Temp = (Temp - 32) / 1.8)\n \n # Things transform can't do\n mutate(airquality, Temp = (Temp - 32) / 1.8, OzT = Ozone / Temp)\n \n # mutate is rather faster than transform\n system.time(transform(baseball, avg_ab = ab / g))\n system.time(mutate(baseball, avg_ab = ab / g))\n \n" | |
} | |
], | |
"prompt_number": 15 | |
}, | |
{ | |
"cell_type": "markdown", | |
"metadata": {}, | |
"source": "Here is the part I was unclear about. I see no shapefile being read in, so we need to dissect the `choropleth` method." | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "%%R\n\n#Create map\nmap<-rCharts::choropleth(\n cut(Adult_Obesity_Rate, 5, labels = F) ~ state,\n data = obesity,\n pal = 'PuRd'\n)\n\n#Save map to HTML\nmap$save('rChart_map.html',cdn=TRUE)", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [], | |
"prompt_number": 16 | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "#Define display function\ndef display_rchart(filename):\n from IPython.display import display, HTML, Javascript\n display(HTML(\"<iframe src=files/\" + filename + \"/\" + \" width=850 height=430 seamless></iframe>\"))\ndisplay_rchart('rChart_map.html')", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"html": "<iframe src=files/rChart_map.html/ width=850 height=430 seamless></iframe>", | |
"metadata": {}, | |
"output_type": "display_data", | |
"text": "<IPython.core.display.HTML at 0x109a1bc90>" | |
} | |
], | |
"prompt_number": 20 | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "map2 = %R paste(capture.output(map$show('iframesrc', cdn = TRUE)), collapse = '\\n')\nfrom IPython.display import display, HTML\nHTML(map2[0])", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"html": "<iframe srcdoc='\n<!doctype HTML>\n<meta charset = 'utf-8'>\n<html>\n <head>\n \n <script src='http://d3js.org/d3.v3.min.js' type='text/javascript'></script>\n <script src='http://d3js.org/topojson.v1.min.js' type='text/javascript'></script>\n <script src='http://datamaps.github.io/scripts/datamaps.all.min.js' type='text/javascript'></script>\n <script src='http://cdnjs.cloudflare.com/ajax/libs/handlebars.js/1.0.0/handlebars.min.js' type='text/javascript'></script>\n \n <style>\n .rChart {\n display: block;\n margin-left: auto; \n margin-right: auto;\n width: 800px;\n height: 400px;\n } \n </style>\n \n </head>\n <body>\n <div id='chart4fd15ed60e90' class='rChart datamaps'></div> \n \n <script id='popup-template' type='text/x-handlebars-template'>\n \n</script>\n<script>\n var chartParams = {\n "dom": "chart4fd15ed60e90",\n"width": 800,\n"height": 400,\n"scope": "usa",\n"fills": {\n "5": "#F1EEF6",\n"1": "#D7B5D8",\n"4": "#DF65B0",\n"3": "#DD1C77",\n"2": "#980043" \n},\n"data": {\n "AK": {\n "State": "Alaska",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.11,\n"Adult_Obesity_Rate": 0.624,\n"state": "AK",\n"fillKey": 5 \n},\n"AL": {\n "State": "Alabama",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.17,\n"Adult_Obesity_Rate": 0.623,\n"state": "AL",\n"fillKey": 5 \n},\n"AR": {\n "State": "Arkansas",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " Yes ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.16,\n"Adult_Obesity_Rate": 0.619,\n"state": "AR",\n"fillKey": 4 \n},\n"AZ": {\n "State": "Arizona",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.12,\n"Adult_Obesity_Rate": 0.535,\n"state": "AZ",\n"fillKey": 1 \n},\n"CA": {\n "State": "California",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.13,\n"Adult_Obesity_Rate": 0.579,\n"state": "CA",\n"fillKey": 3 \n},\n"CO": {\n "State": "Colorado",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.1,\n"Adult_Obesity_Rate": 0.523,\n"state": "CO",\n"fillKey": 1 \n},\n"CT": {\n "State": "Connecticut",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.12,\n"Adult_Obesity_Rate": 0.552,\n"state": "CT",\n"fillKey": 2 \n},\n"DE": {\n "State": "Delaware",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.15,\n"Adult_Obesity_Rate": 0.605,\n"state": "DE",\n"fillKey": 4 \n},\n"FL": {\n "State": "Florida",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " Yes ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.582,\n"state": "FL",\n"fillKey": 3 \n},\n"GA": {\n "State": "Georgia",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " Yes ",\n"Childhood_Obesity_Rate": 0.16,\n"Adult_Obesity_Rate": 0.605,\n"state": "GA",\n"fillKey": 4 \n},\n"HI": {\n "State": "Hawaii",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.13,\n"Adult_Obesity_Rate": 0.514,\n"state": "HI",\n"fillKey": 1 \n},\n"IA": {\n "State": "Iowa",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.13,\n"Adult_Obesity_Rate": 0.602,\n"state": "IA",\n"fillKey": 4 \n},\n"ID": {\n "State": "Idaho",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.1,\n"Adult_Obesity_Rate": 0.583,\n"state": "ID",\n"fillKey": 3 \n},\n"IL": {\n "State": "Illinois",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " Yes ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.16,\n"Adult_Obesity_Rate": 0.582,\n"state": "IL",\n"fillKey": 3 \n},\n"IN": {\n "State": "Indiana",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " Yes ",\n"Childhood_Obesity_Rate": 0.16,\n"Adult_Obesity_Rate": 0.595,\n"state": "IN",\n"fillKey": 3 \n},\n"KS": {\n "State": "Kansas",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.58,\n"state": "KS",\n"fillKey": 3 \n},\n"KY": {\n "State": "Kentucky",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.21,\n"Adult_Obesity_Rate": 0.625,\n"state": "KY",\n"fillKey": 5 \n},\n"LA": {\n "State": "Louisiana",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.17,\n"Adult_Obesity_Rate": 0.623,\n"state": "LA",\n"fillKey": 5 \n},\n"MA": {\n "State": "Massachusetts",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.529,\n"state": "MA",\n"fillKey": 1 \n},\n"MD": {\n "State": "Maryland",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " Yes ",\n"Childhood_Obesity_Rate": 0.13,\n"Adult_Obesity_Rate": 0.582,\n"state": "MD",\n"fillKey": 3 \n},\n"ME": {\n "State": "Maine",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.13,\n"Adult_Obesity_Rate": 0.569,\n"state": "ME",\n"fillKey": 3 \n},\n"MI": {\n "State": "Michigan",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.605,\n"state": "MI",\n"fillKey": 4 \n},\n"MN": {\n "State": "Minnesota",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.1,\n"Adult_Obesity_Rate": 0.594,\n"state": "MN",\n"fillKey": 3 \n},\n"MO": {\n "State": "Missouri",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " Yes ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.16,\n"Adult_Obesity_Rate": 0.624,\n"state": "MO",\n"fillKey": 5 \n},\n"MS": {\n "State": "Mississippi",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.18,\n"Adult_Obesity_Rate": 0.649,\n"state": "MS",\n"fillKey": 5 \n},\n"MT": {\n "State": "Montana",\n"Approach_to_Address_Childhood_Obesity": " Physical education program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.11,\n"Adult_Obesity_Rate": 0.547,\n"state": "MT",\n"fillKey": 2 \n},\n"NC": {\n "State": "North Carolina",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.19,\n"Adult_Obesity_Rate": 0.594,\n"state": "NC",\n"fillKey": 3 \n},\n"ND": {\n "State": "North Dakota",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.12,\n"Adult_Obesity_Rate": 0.62,\n"state": "ND",\n"fillKey": 4 \n},\n"NE": {\n "State": "Nebraska",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.12,\n"Adult_Obesity_Rate": 0.602,\n"state": "NE",\n"fillKey": 4 \n},\n"NH": {\n "State": "New Hampshire",\n"Approach_to_Address_Childhood_Obesity": " Physical education program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.13,\n"Adult_Obesity_Rate": 0.574,\n"state": "NH",\n"fillKey": 3 \n},\n"NJ": {\n "State": "New Jersey",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.553,\n"state": "NJ",\n"fillKey": 2 \n},\n"NM": {\n "State": "New Mexico",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.17,\n"Adult_Obesity_Rate": 0.582,\n"state": "NM",\n"fillKey": 3 \n},\n"NV": {\n "State": "Nevada",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.12,\n"Adult_Obesity_Rate": 0.562,\n"state": "NV",\n"fillKey": 2 \n},\n"NY": {\n "State": "New York",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.15,\n"Adult_Obesity_Rate": 0.568,\n"state": "NY",\n"fillKey": 3 \n},\n"OH": {\n "State": "Ohio",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.603,\n"state": "OH",\n"fillKey": 4 \n},\n"OK": {\n "State": "Oklahoma",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.15,\n"Adult_Obesity_Rate": 0.606,\n"state": "OK",\n"fillKey": 4 \n},\n"OR": {\n "State": "Oregon",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.565,\n"state": "OR",\n"fillKey": 2 \n},\n"PA": {\n "State": "Pennsylvania",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " Yes ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.13,\n"Adult_Obesity_Rate": 0.592,\n"state": "PA",\n"fillKey": 3 \n},\n"RI": {\n "State": "Rhode Island",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.12,\n"Adult_Obesity_Rate": 0.558,\n"state": "RI",\n"fillKey": 2 \n},\n"SC": {\n "State": "South Carolina",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.19,\n"Adult_Obesity_Rate": 0.623,\n"state": "SC",\n"fillKey": 5 \n},\n"SD": {\n "State": "South Dakota",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.12,\n"Adult_Obesity_Rate": 0.607,\n"state": "SD",\n"fillKey": 4 \n},\n"TN": {\n "State": "Tennessee",\n"Approach_to_Address_Childhood_Obesity": " School nutrition program ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " Yes ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.2,\n"Adult_Obesity_Rate": 0.593,\n"state": "TN",\n"fillKey": 3 \n},\n"TX": {\n "State": "Texas",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.19,\n"Adult_Obesity_Rate": 0.588,\n"state": "TX",\n"fillKey": 3 \n},\n"UT": {\n "State": "Utah",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.11,\n"Adult_Obesity_Rate": 0.543,\n"state": "UT",\n"fillKey": 2 \n},\n"VA": {\n "State": "Virginia",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " Yes ",\n"Childhood_Obesity_Rate": 0.11,\n"Adult_Obesity_Rate": 0.589,\n"state": "VA",\n"fillKey": 3 \n},\n"VT": {\n "State": "Vermont",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.542,\n"state": "VT",\n"fillKey": 2 \n},\n"WA": {\n "State": "Washington",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.21,\n"Adult_Obesity_Rate": 0.565,\n"state": "WA",\n"fillKey": 2 \n},\n"WI": {\n "State": "Wisconsin",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.09,\n"Adult_Obesity_Rate": 0.591,\n"state": "WI",\n"fillKey": 3 \n},\n"WV": {\n "State": "West Virginia",\n"Approach_to_Address_Childhood_Obesity": " Both ",\n"State_Task_Force_Committee": " Yes ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.14,\n"Adult_Obesity_Rate": 0.636,\n"state": "WV",\n"fillKey": 5 \n},\n"WY": {\n "State": "Wyoming",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " Yes ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.15,\n"Adult_Obesity_Rate": 0.596,\n"state": "WY",\n"fillKey": 4 \n},\n"NA": {\n "State": "District of Columbia",\n"Approach_to_Address_Childhood_Obesity": " None ",\n"State_Task_Force_Committee": " No ",\n"Mandates_BMI_Screening": " No ",\n"Mandates_Obesity_Treatment_Coverage": " No ",\n"Childhood_Obesity_Rate": 0.23,\n"Adult_Obesity_Rate": 0.521,\n"state": null,\n"fillKey": 1 \n} \n},\n"id": "chart4fd15ed60e90" \n}\n chartParams.element = document.getElementById('chart4fd15ed60e90')\n \n \n var mapchart4fd15ed60e90 = new Datamap(chartParams);\n \n \n \n // draw a bubble map if specified\n if (chartParams.bubbles) {\n var bubbles = chartParams.bubbles\n mapchart4fd15ed60e90.bubbles(bubbles)\n }\n \n if (chartParams.labels){\n mapchart4fd15ed60e90.labels()\n }\n</script>\n\n<style>\n.datamaps {\n position: relative;\n}\n</style>\n \n </body>\n</html>\n' scrolling='no' seamless></iframe>\n<style>iframe{ width: 100%; height: 400px;}</style>", | |
"metadata": {}, | |
"output_type": "pyout", | |
"prompt_number": 18, | |
"text": "<IPython.core.display.HTML at 0x109a1ce50>" | |
} | |
], | |
"prompt_number": 18 | |
}, | |
{ | |
"cell_type": "code", | |
"collapsed": false, | |
"input": "", | |
"language": "python", | |
"metadata": {}, | |
"outputs": [], | |
"prompt_number": 18 | |
} | |
], | |
"metadata": {} | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment