-
-
Notifications
You must be signed in to change notification settings - Fork 544
Choropleth Docs #879
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Choropleth Docs #879
Conversation
@cldougl whenever you want to have a look. Still some todos in this PR but the doc is written. |
@Kully if you move https://plot.ly/python/county-level-choropleth/ to |
<div class="prompt input_prompt">In [1]:</div> | ||
<div class="inner_cell"> | ||
<div class="input_area"> | ||
<div class=" highlight hl-ipython2"><pre><span></span><span class="n">pwd</span> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rm pwd
|
||
|
||
<div class="output_text output_subarea output_execute_result"> | ||
<pre>u'/Users/adamkulidjian/Desktop/Adam/Plotly/documentation/_posts/python/maps/county_choropleth'</pre> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rm pwd output
</div> | ||
<div class="inner_cell"> | ||
<div class="text_cell_render border-box-sizing rendered_html"> | ||
<h4 id="Version-Check">Version Check<a class="anchor-link" href="#Version-Check">¶</a></h4><p>Note: <code>County Choropleths</code> are available in version <b>2.4.1+</b><br> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice 2.4.1 is already in there <3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<3
</div> | ||
<div class="inner_cell"> | ||
<div class="text_cell_render border-box-sizing rendered_html"> | ||
<h4 id="Version-Check">Version Check<a class="anchor-link" href="#Version-Check">¶</a></h4><p>Note: <code>County Choropleths</code> are available in version <b>2.4.1+</b><br> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are only US counties available? If so we should probably say: Note: United States County Choropleths are available in version 2.4.1+
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wdyt about changing the doc name to USA County Choropleths
then? Just the title, not the url
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good idea!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would change both - title and Note: US County Choropleths are available in version 2.4.1+
(just want to make this clear as we get asked pretty often about choropleths for other regions outside of the US)
</div> | ||
<div class="inner_cell"> | ||
<div class="text_cell_render border-box-sizing rendered_html"> | ||
<h4 id="FIPS-and-Values">FIPS and Values<a class="anchor-link" href="#FIPS-and-Values">¶</a></h4><p>Every US State and County has an assined ID regulated by the US Federal Government under the term FIPS (Federal Information Processing Standards) Codes. There are State codes and County codes: the 2016 State and County FIPS Codes can be found at the <a href="https://www.census.gov/geographies/reference-files/2016/demo/popest/2016-fips.html">US Census Website</a>.</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are State codes and County codes: the 2016 State and County FIPS...
state and county don't need to be capitalized there
</div> | ||
<div class="inner_cell"> | ||
<div class="text_cell_render border-box-sizing rendered_html"> | ||
<h4 id="Change-your-Scope">Change your Scope<a class="anchor-link" href="#Change-your-Scope">¶</a></h4><p>Even if your FIPS values belong to a single state, changing the <code>scope</code> of the choropleth shifts the zoom and position of the USA map to include any states. Specify a list of state names and the camera automatically adjusts to include the state outlines of the selected states.</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change the Scope
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even if your FIPS values belong to a single state, changing the scope of the choropleth shifts the zoom and position of the USA map to include any states. Specify a list of state names and the camera automatically adjusts to include the state outlines of the selected states.
Even if your FIPS values belong to a single state, the scope
defaults to the entire United States as displayed in the example above. Changing the scope of the choropleth shifts the zoom and position of the USA map. You can define the scope
with a list of state names and the zoom will automatically adjust to include the state outlines of the selected states.
</div> | ||
<div class="inner_cell"> | ||
<div class="text_cell_render border-box-sizing rendered_html"> | ||
<h4 id="Florida">Florida<a class="anchor-link" href="#Florida">¶</a></h4> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
instead of the name of the state- let's make this title more informative:
Single State
</div> | ||
<div class="inner_cell"> | ||
<div class="text_cell_render border-box-sizing rendered_html"> | ||
<h4 id="Offline-Choropleth">Offline Choropleth<a class="anchor-link" href="#Offline-Choropleth">¶</a></h4><p>Setting <code>offline_mode=True</code> modifies the centroid markers so that they are only visible if you hoverdrag a box over them.</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how does this offline_mode
relate to plotly.offline
? That should be clarified in this section. As well as linking to the getting started offline doc section: https://plot.ly/python/getting-started/#initialization-for-offline-plotting
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cool! I'd just remove this from the doc or change it to an online example if you still want to include this example.
|
||
|
||
<div class="output_html rendered_html output_subarea "> | ||
<div id="b3400adb-0882-4efa-9ade-a51aa48e6c32" style="height: 450px; width: 900px;" class="plotly-graph-div"></div><script type="text/javascript">require(["plotly"], function(Plotly) { window.PLOTLYENV=window.PLOTLYENV || {};window.PLOTLYENV.BASE_URL="https://plot.ly";Plotly.newPlot("b3400adb-0882-4efa-9ade-a51aa48e6c32", [{"name": 1424, "fillcolor": "#8dd3c7", "mode": "lines", "hoverinfo": "text", "y": [45.068279, 45.067789999999995, 45.067219, 45.067353999999995, 45.065453, 45.065397999999995, 45.065224, 45.065582, 45.065591, 45.066927, 45.067927999999995, 45.067865999999995, 45.067783, 45.067823, 45.023517, 44.994755, 44.994816, 44.995193, 44.995117, 44.823343, 44.823299, 44.762701, 44.652252, 44.652251, 44.621784999999996, 44.534130999999995, 44.461287999999996, 44.454961, 44.38917, 44.389206, 44.34547, 44.307044999999995, 44.306619999999995, 44.389575, 44.389457, 44.388968, 44.389103999999996, 44.389727, 44.389686999999995, 44.438793, 44.43821, 44.437751, 44.437014999999995, 44.436082999999996, 44.476624, 44.476624, 44.564009, 44.578606, 44.653068, 44.761175, 44.761979, 44.763228999999995, 44.767886, 44.769866, 44.771637999999996, 44.773306999999996, 44.776973, 44.778766999999995, 44.78073, 44.782665, 44.784272, 44.786038, 44.788413999999996, 44.789950999999995, 44.792694999999995, 44.794719, 44.797861, 44.799834999999995, 44.802357, 44.803968999999995, 44.802712, 44.797013, 44.795784, 44.796406, 44.798474, 44.800720999999996, 44.80298, 44.806314, 44.807351999999995, 44.807041, 44.809674, 44.809965999999996, 44.810984999999995, 44.8119, 44.812034, 44.814826, 44.817938, 44.819357, 44.82037, 44.821768999999996, 44.822846, 44.825007, 44.826876999999996, 44.826871999999995, 44.829257, 44.829733, 44.829201, 44.829377, 44.830109, 44.830842999999994, 44.833779, 44.838677999999994, 44.839273999999996, 44.839552, 44.840381, 44.845693, 44.848417, 44.852174, 44.852906999999995, 44.853761999999996, 44.853468, 44.853685999999996, 44.85675, 44.860147999999995, 44.862316, 44.863606999999995, 44.863811999999996, 44.863057999999995, 44.8644, 44.865607, 44.869667, 44.872612, 44.873867, 44.874285, 44.876113, 44.878215999999995, 44.881198999999995, 44.88281, 44.884215, 44.884591, 44.886700999999995, 44.888013, 44.894064, 44.894791, 44.899629, 44.904258, 44.908663, 44.908317, 44.907264, 44.905131999999995, 44.903735999999995, 44.903973, 44.905528, 44.907439, 44.907436, 44.908162, 44.909661, 44.913388, 44.913847, 44.916909, 44.919343, 44.922126, 44.924502, 44.927367, 44.929493, 44.932196999999995, 44.933343, 44.935458, 44.940262, 44.942457999999995, 44.943141999999995, 44.945507, 44.947337, 44.949244, 44.950682, 44.951299, 44.954046999999996, 44.955769, 44.956472, 44.959686, 44.960691999999995, 44.962748999999995, 44.965194, 44.965188, 44.966344, 44.967456, 44.970088, 44.972277999999996, 44.972941, 44.972849, 44.975432, 44.978676, 44.980374, 44.981876, 44.984595999999996, 44.988537, 44.989762999999996, 44.992757999999995, 44.998224, 45.000113, 45.00165, 45.002949, 45.00615, 45.007686, 45.009024, 45.01105, 45.015249999999995, 45.01895, 45.02115, 45.027049999999996, 45.02915, 45.03255, 45.03415, 45.03705, 45.03895, 45.04315, 45.047149999999995, 45.04855, 45.05195, 45.05345, 45.056349999999995, 45.05695, 45.057849999999995, 45.05855, 45.06095, 45.06315, 45.06295, 45.06355, 45.068279, null], "x": [-120.49516, -120.309328, -120.18845999999999, -120.13192599999999, -120.128661, -120.086479, -120.028785, -120.005372, -120.000045, -119.91054, -119.91053600000001, -119.876525, -119.850941, -119.790699, -119.790961, -119.791162, -119.781719, -119.77024399999999, -119.672228, -119.671532, -119.652431, -119.653184, -119.653347, -119.653476, -119.653538, -119.653885, -119.653673, -119.653832, -119.653696, -119.655108, -119.655248, -119.655517, -119.899002, -119.899283, -119.960375, -119.97053199999999, -120.000617, -120.010547, -120.020708, -120.021621, -120.101166, -120.14354399999999, -120.36646, -120.38607400000001, -120.385775, -120.387186, -120.386561, -120.385768, -120.38637800000001, -120.385687, -120.387642, -120.38811799999999, -120.387452, -120.387782, -120.389667, -120.393046, -120.398603, -120.399248, -120.397984, -120.394825, -120.394254, -120.394668, -120.39737, -120.400743, -120.404685, -120.404676, -120.40165400000001, -120.399226, -120.398292, -120.395872, -120.394109, -120.39317299999999, -120.390987, -120.385062, -120.385877, -120.381376, -120.379794, -120.379005, -120.380814, -120.384813, -120.385489, -120.386498, -120.38603499999999, -120.38353000000001, -120.377797, -120.377062, -120.38071099999999, -120.379053, -120.372635, -120.371441, -120.372173, -120.376617, -120.378686, -120.38024899999999, -120.387086, -120.390315, -120.394199, -120.397282, -120.400495, -120.401587, -120.405023, -120.405045, -120.405558, -120.40829, -120.410061, -120.410794, -120.411979, -120.41257999999999, -120.413864, -120.41846, -120.424464, -120.427549, -120.433469, -120.43556699999999, -120.43628, -120.439561, -120.443361, -120.445746, -120.452471, -120.455204, -120.454163, -120.454706, -120.45620199999999, -120.459592, -120.460353, -120.460126, -120.458764, -120.455737, -120.451259, -120.446918, -120.440553, -120.438784, -120.436139, -120.436328, -120.43946, -120.444521, -120.450991, -120.453485, -120.454775, -120.455771, -120.458259, -120.460798, -120.46249399999999, -120.467323, -120.469777, -120.473566, -120.474136, -120.468899, -120.468709, -120.471074, -120.471271, -120.47012699999999, -120.470495, -120.472776, -120.476621, -120.47708, -120.474898, -120.472884, -120.476528, -120.478641, -120.480293, -120.481685, -120.47938500000001, -120.482655, -120.488231, -120.489133, -120.487029, -120.486572, -120.485083, -120.48491899999999, -120.485821, -120.485982, -120.482025, -120.47970699999999, -120.477292, -120.476778, -120.476773, -120.477712, -120.47928999999999, -120.48367, -120.483766, -120.480902, -120.47751, -120.477168, -120.479487, -120.478688, -120.480046, -120.481248, -120.482877, -120.483767, -120.487246, -120.487646, -120.486545, -120.482573, -120.480864, -120.481745, -120.479645, -120.479545, -120.48094499999999, -120.488946, -120.488946, -120.485646, -120.483446, -120.481346, -120.48104599999999, -120.488046, -120.489747, -120.489047, -120.484947, -120.48364699999999, -120.482647, -120.483347, -120.488547, -120.489347, -120.48964699999999, -120.490647, -120.49404799999999, -120.495548, -120.49516, null], "line": {"color": "rgb(15, 15, 55)", "width": 0.5}, "type": "scatter", "fill": "toself"}, {"name": 1732, "fillcolor": "#ffffb3", "mode": "lines", "hoverinfo": "text", "y": [45.285857, 45.288917, 45.289725, 45.291385999999996, 45.294684, 45.297022, 45.301504, 45.305139999999994, 45.307148, 45.309269, 45.31006, 45.309698, 45.307643999999996, 45.306543999999995, 45.307444, 45.309343999999996, 45.312644, 45.318543, 45.320256, 45.321963, 45.322652, 45.320315, 45.319027, 45.316643, 45.312945, 45.309899, 45.308634999999995, 45.307437, 45.30694, 45.306844999999996, 45.307945, 45.310345, 45.313444999999994, 45.316745, 45.323445, 45.325044999999996, 45.327144999999994, 45.331345, 45.333445, 45.334444999999995, 45.335645, 45.337244999999996, 45.337644999999995, 45.336745, 45.332645, 45.331345, 45.330844, 45.331343, 45.332443, 45.336442999999996, 45.337843, 45.340244, 45.342045999999996, 45.345588, 45.346844999999995, 45.347744999999996, 45.347744999999996, 45.347345, 45.348045, 45.349244999999996, 45.351645, 45.356144, 45.359344, 45.361345, 45.362645, 45.362145, 45.360745, 45.361596, 45.364245, 45.370245, 45.374445, 45.378322, 45.383145, 45.387277999999995, 45.390457, 45.392551999999995, 45.392413999999995, 45.391687, 45.388216, 45.38852, 45.389224, 45.391231, 45.393451, 45.397878999999996, 45.401146, 45.409346, 45.412746, 45.422746, 45.425346, 45.427346, 45.428414, 45.428644999999996, 45.426944999999996, 45.427144999999996, 45.428545, 45.431445, 45.433645, 45.434644999999996, 45.435846, 45.439046, 45.440546, 45.445046, 45.446045999999996, 45.448446, 45.450345999999996, 45.454546, 45.456246, 45.459945999999995, 45.461546, 45.461946, 45.462745999999996, 45.467346, 45.469145999999995, 45.471246, 45.474546, 45.475646, 45.479546, 45.483245, 45.485645, 45.493046, 45.494645999999996, 45.497344999999996, 45.501841, 45.502441, 45.504841, 45.506741999999996, 45.507742, 45.509944999999995, 45.511466, 45.514077, 45.515307, 45.515968, 45.515746, 45.517545999999996, 45.521846, 45.523446, 45.528746, 45.528391, 45.526944, 45.526771, 45.527564, 45.529435, 45.531695, 45.537458, 45.539325999999996, 45.541613999999996, 45.54268, 45.543979, 45.549261, 45.553405999999995, 45.558240999999995, 45.559951, 45.561147999999996, 45.564496999999996, 45.565661999999996, 45.568928, 45.571842, 45.576068, 45.579032999999995, 45.585913999999995, 45.586684999999996, 45.589040999999995, 45.592332999999996, 45.596399, 45.598386999999995, 45.600345, 45.602444999999996, 45.605245, 45.608838999999996, 45.613245, 45.615745, 45.617145, 45.621645, 45.626731, 45.627939, 45.632495999999996, 45.634693, 45.636345, 45.641301218792, 45.640045, 45.642945, 45.6500815780723, 45.661242, 45.671544999999995, 45.6758434879127, 45.686246, 45.706446, 45.715847, 45.730146999999995, 45.7372486812962, 45.732946999999996, 45.730246, 45.726146, 45.723946, 45.722345999999995, 45.721046, 45.720845999999995, 45.721546, 45.720645999999995, 45.721346, 45.722046999999996, 45.721447, 45.717847, 45.715847, 45.714546999999996, 45.713046999999996, 45.706647, 45.704747, 45.702847, 45.702247, 45.701547999999995, 45.701648, 45.700047999999995, 45.698648, 45.696048, 45.695448, 45.693748, 45.690647999999996, 45.686048, 45.682348, 45.681647999999996, 45.679448, 45.678348, 45.677547999999994, 45.672548, 45.670148, 45.669048, 45.669194999999995, 45.671164999999995, 45.671852, 45.671898999999996, 45.671177, 45.668983, 45.667379, 45.666866999999996, 45.66608, 45.66596, 45.665119, 45.663944, 45.661515, 45.656275, 45.655788, 45.655522, 45.656147, 45.655946, 45.654990999999995, 45.654793999999995, 45.651677, 45.648976999999995, 45.648871, 45.643504, 45.643311999999995, 45.645171, 45.645177, 45.645165999999996, 45.645151, 45.644858, 45.642019, 45.640653, 45.639517999999995, 45.639181, 45.639390999999996, 45.638269, 45.637158, 45.635036, 45.634178, 45.633047, 45.630668, 45.628747, 45.627752, 45.626368, 45.624826999999996, 45.622828999999996, 45.620066, 45.619321, 45.619673, 45.621576999999995, 45.622015999999995, 45.624286, 45.625859999999996, 45.626584, 45.627030999999995, 45.626112, 45.622848, 45.621291, 45.618006, 45.615691999999996, 45.613944, 45.607454, 45.602365, 45.598437999999994, 45.597302, 45.597164, 45.597601999999995, 45.597026, 45.596067, 45.595318, 45.592507999999995, 45.589051999999995, 45.583655, 45.581893, 45.576727999999996, 45.574605, 45.569936, 45.567051, 45.565666, 45.563100999999996, 45.559754, 45.557779, 45.556725, 45.555641, 45.554154, 45.551701, 45.549859, 45.548722999999995, 45.546732, 45.544309999999996, 45.541528, 45.538807999999996, 45.537535, 45.537732999999996, 45.537248999999996, 45.535359, 45.533713, 45.531459, 45.530316, 45.53113, 45.531392, 45.530643999999995, 45.528385, 45.527587999999994, 45.523731, 45.521584, 45.519428, 45.518166, 45.518094999999995, 45.516641, 45.515253, 45.51424, 45.51263, 45.509831999999996, 45.508033999999995, 45.505691, 45.501064, 45.49725, 45.49655, 45.49525, 45.493714, 45.49295, 45.49445, 45.496787, 45.497049999999994, 45.49695, 45.49745, 45.49825, 45.49875, 45.50051, 45.497949999999996, 45.49395, 45.491949999999996, 45.48605, 45.48365, 45.48285, 45.48305, 45.482549999999996, 45.48185, 45.47445, 45.473147, 45.470332, 45.468636, 45.468016999999996, 45.469243, 45.471716, 45.472994, 45.475767999999995, 45.478877, 45.483689999999996, 45.485275, 45.485194, 45.480211999999995, 45.478808, 45.476929, 45.476149, 45.472649, 45.471982999999994, 45.470248999999995, 45.468948999999995, 45.465348999999996, 45.462649, 45.462049, 45.462449, 45.461749, 45.459548999999996, 45.456548999999995, 45.455349, 45.453649, 45.451848999999996, 45.450548999999995, 45.446949, 45.444049, 45.443649, 45.442549, 45.440715999999995, 45.438548, 45.435548999999995, 45.434349, 45.434249, 45.434549, 45.433999, 45.433248999999996, 45.431748999999996, 45.430648999999995, 45.428249, 45.427949, 45.428249, 45.426949, 45.422849, 45.420549, 45.419249, 45.416849, 45.417348999999994, 45.418648999999995, 45.419049, 45.418749, 45.417249, 45.407748999999995, 45.405749, 45.405049, 45.404348999999996, 45.405449, 45.405249, 45.403448999999995, 45.400349, 45.396349, 45.394649, 45.388849, 45.387249, 45.386548999999995, 45.385449, 45.383249, 45.381549, 45.380449, 45.381848999999995, 45.381149, 45.380649, 45.378648999999996, 45.376849, 45.375648999999996, 45.375749, 45.377849, 45.376849, 45.373549, 45.372549, 45.371849, 45.371249, 45.370249, 45.368449, 45.366149, 45.363848999999995, 45.358149, 45.352948999999995, 45.351749, 45.349948999999995, 45.347649, 45.346049, 45.345248999999995, 45.344148999999994, 45.343649, 45.342048999999996, 45.339248999999995, 45.336549, 45.335149, 45.332249, 45.331449, 45.331449, 45.330649, 45.329349, 45.327749, 45.328449, 45.328148999999996, 45.324248999999995, 45.320949, 45.319148999999996, 45.317549, 45.315849, 45.314749, 45.311549, 45.309749, 45.309048999999995, 45.305749, 45.304049, 45.300149999999995, 45.29915, 45.295949, 45.294748999999996, 45.295049, 45.296349, 45.297849, 45.302749, 45.304348999999995, 45.304548999999994, 45.302549, 45.298348999999995, 45.296448999999996, 45.295549, 45.291449, 45.288049, 45.285649, 45.284448999999995, 45.284448999999995, 45.283249, 45.281248999999995, 45.279649, 45.281048999999996, 45.281048999999996, 45.279649, 45.279049, 45.276049, 45.274864, 45.271848999999996, 45.269048999999995, 45.267249, 45.262949, 45.261649, 45.261649, 45.262449, 45.261849999999995, 45.259049999999995, 45.255849999999995, 45.25495, 45.253254999999996, 45.253848999999995, 45.253349, 45.252749, 45.250448999999996, 45.246649, 45.244146, 45.242425999999995, 45.240849, 45.237249, 45.236649, 45.235149, 45.231949, 45.228449, 45.223949, 45.222449, 45.220248999999995, 45.219848999999996, 45.22325, 45.22465, 45.22465, 45.22385, 45.22255, 45.220349999999996, 45.218849999999996, 45.21675, 45.21635, 45.21665, 45.21785, 45.217048999999996, 45.213649, 45.212506999999995, 45.210349, 45.209948999999995, 45.211149999999996, 45.21125, 45.21065, 45.20605, 45.20475, 45.20445, 45.205349999999996, 45.20445, 45.20265, 45.201049999999995, 45.19925, 45.197849999999995, 45.196149999999996, 45.19555, 45.19575, 45.197649999999996, 45.197233, 45.194849999999995, 45.193349999999995, 45.19125, 45.18895, 45.18665, 45.18365, 45.180749999999996, 45.17955, 45.179449999999996, 45.18015, 45.17975, 45.17765, 45.17565, 45.173249999999996, 45.172349999999994, 45.172349999999994, 45.171549999999996, 45.170249999999996, 45.168949999999995, 45.16835, 45.165949999999995, 45.16494, 45.16355, 45.16215, 45.159549999999996, 45.15775, 45.15645, 45.15415, 45.151849999999996, 45.15105, 45.146685999999995, 45.144196, 45.14405, 45.145483, 45.14545, 45.143184999999995, 45.140882999999995, 45.139253, 45.13945, 45.13885, 45.13795, 45.13505, 45.130126999999995, 45.125985, 45.123149999999995, 45.12065, 45.11945, 45.11625, 45.11165, 45.10865, 45.105149999999995, 45.10375, 45.10115, 45.10015, 45.101549999999996, 45.10285, 45.10695, 45.10855, 45.11165, 45.11015, 45.10505, 45.10435, 45.10585, 45.10575, 45.104549999999996, 45.1041, 45.10265, 45.102778, 45.10135, 45.09465, 45.09095, 45.08725, 45.08565, 45.083476999999995, 45.083476999999995, 45.083588999999996, 45.083695, 45.083731, 45.085907, 45.086873, 45.088764999999995, 45.089884999999995, 45.091091999999996, 45.093143, 45.095639, 45.097334, 45.099714999999996, 45.100224999999995, 45.103615999999995, 45.105245, 45.106348, 45.106595999999996, 45.111056, 45.114616, 45.117582999999996, 45.119628999999996, 45.121756999999995, 45.124848, 45.126089, 45.127871999999996, 45.129577999999995, 45.130522, 45.131673, 45.132357999999996, 45.133054, 45.135076999999995, 45.134533, 45.1344, 45.134805, 45.136159, 45.136322, 45.137567, 45.139556999999996, 45.140314, 45.142267, 45.142427999999995, 45.144023999999995, 45.144321, 45.143845, 45.144461, 45.145745, 45.149271999999996, 45.150189, 45.153147, 45.155435, 45.156510999999995, 45.157140999999996, 45.158736999999995, 45.160367, 45.162337, 45.162693999999995, 45.162405, 45.163256, 45.162707999999995, 45.164184, 45.163077, 45.163301999999995, 45.164828, 45.165085999999995, 45.164483, 45.165388, 45.165420999999995, 45.166441999999996, 45.167929, 45.168318, 45.167193999999995, 45.170074, 45.170973, 45.172641, 45.172219, 45.172810999999996, 45.175916, 45.17698, 45.175965, 45.176742999999995, 45.178981, 45.179206, 45.180175999999996, 45.181245999999994, 45.184218, 45.185869, 45.1877, 45.189509, 45.190205999999996, 45.189710999999996, 45.193073, 45.193861999999996, 45.195111999999995, 45.194649999999996, 45.196763999999995, 45.198991, 45.198138, 45.199481, 45.200624, 45.199802, 45.202304999999996, 45.202158, 45.201015999999996, 45.200703999999995, 45.202121, 45.203030999999996, 45.203406, 45.202794, 45.203095999999995, 45.200337, 45.199614, 45.199504999999995, 45.198189, 45.197810999999994, 45.198744, 45.201803999999996, 45.20288, 45.201783, 45.20033, 45.199780999999994, 45.200555, 45.203523, 45.203314999999996, 45.201543, 45.200106, 45.2006, 45.199611999999995, 45.198147, 45.198131, 45.200084, 45.200797, 45.200171, 45.200435, 45.201916, 45.201454, 45.200533, 45.199129, 45.196588999999996, 45.196231999999995, 45.197026, 45.198343, 45.198167, 45.200064, 45.199855, 45.200423, 45.19887, 45.198831999999996, 45.200164, 45.20007, 45.197787999999996, 45.198916999999994, 45.200376, 45.204263999999995, 45.204361999999996, 45.203313, 45.204881, 45.206421999999996, 45.208369, 45.20892, 45.20822, 45.209421999999996, 45.211071, 45.211051, 45.208977, 45.210142999999995, 45.212129999999995, 45.212996, 45.213307, 45.212388999999995, 45.212678, 45.215472999999996, 45.216733, 45.217611, 45.217971999999996, 45.218455, 45.219530999999996, 45.220811, 45.22145, 45.222909, 45.223769999999995, 45.225218999999996, 45.227813, 45.229872, 45.23038, 45.232197, 45.235346, 45.236331, 45.237762, 45.23835, 45.239548, 45.241133, 45.241928, 45.245501, 45.246643, 45.249845, 45.251225999999996, 45.261002, 45.264106999999996, 45.264793, 45.266282, 45.268668, 45.270475999999995, 45.271766, 45.275175999999995, 45.27644, 45.278572999999994, 45.281969, 45.284738, 45.286179999999995, 45.284327999999995, 45.28481, 45.285857, null], "x": [-121.03120200000001, -121.026348, -121.024374, -121.022556, -121.019811, -121.018483, -121.018588, -121.01742899999999, -121.01569, -121.01079, -121.007455, -121.005447, -121.000973, -120.99767299999999, -120.992973, -120.990473, -120.988673, -120.986474, -120.985498, -120.982776, -120.979647, -120.973089, -120.972589, -120.97387, -120.974381, -120.973344, -120.97218, -120.969577, -120.966974, -120.963672, -120.959771, -120.956471, -120.955773, -120.954171, -120.947171, -120.946071, -120.94577100000001, -120.946472, -120.953872, -120.955372, -120.955072, -120.953672, -120.949472, -120.946372, -120.940771, -120.93847099999999, -120.93587099999999, -120.93377, -120.93236999999999, -120.932169, -120.93306799999999, -120.935868, -120.939568, -120.939628, -120.93847199999999, -120.93417099999999, -120.930471, -120.923671, -120.921771, -120.92047099999999, -120.919771, -120.920475, -120.920371, -120.918671, -120.914371, -120.909271, -120.90467100000001, -120.901065, -120.899371, -120.899771, -120.89817099999999, -120.89428, -120.889071, -120.883445, -120.883039, -120.881064, -120.879164, -120.877522, -120.872479, -120.868265, -120.866962, -120.865759, -120.866075, -120.868235, -120.86856900000001, -120.86607000000001, -120.86657, -120.86157, -120.86267, -120.86287, -120.86209, -120.85917, -120.854872, -120.852271, -120.84987, -120.84947, -120.851771, -120.856371, -120.859571, -120.86397099999999, -120.865071, -120.865771, -120.865371, -120.862871, -120.86187100000001, -120.861471, -120.860972, -120.859072, -120.856571, -120.84767099999999, -120.845671, -120.837971, -120.836073, -120.835571, -120.83737099999999, -120.837471, -120.839171, -120.839071, -120.838172, -120.833377, -120.833178, -120.83458, -120.838981, -120.838881, -120.837783, -120.836184, -120.834585, -120.828587, -120.82629, -120.82573099999999, -120.827084, -120.833877, -120.83797200000001, -120.841972, -120.853673, -120.854473, -120.86407299999999, -120.869928, -120.874893, -120.877966, -120.882656, -120.88431800000001, -120.884777, -120.884579, -120.884983, -120.890264, -120.896833, -120.898438, -120.899356, -120.903006, -120.908459, -120.909213, -120.909382, -120.908205, -120.906528, -120.90565699999999, -120.905899, -120.904815, -120.903013, -120.896872, -120.895674, -120.895139, -120.896478, -120.898788, -120.90117599999999, -120.906075, -120.909275, -120.911675, -120.911282, -120.906375, -120.904375, -120.903975, -120.904775, -120.907361, -120.909223, -120.912191, -120.914281, -120.914976, -120.915795173154, -120.913476, -120.895575, -120.88561608608401, -120.870042, -120.855674, -120.836141479114, -120.788872, -120.724171, -120.68937, -120.668869, -120.65353434410001, -120.649368, -120.649368, -120.646168, -120.646068, -120.64366799999999, -120.640368, -120.63856799999999, -120.635868, -120.63166799999999, -120.62906699999999, -120.624467, -120.618567, -120.612267, -120.609967, -120.606167, -120.604867, -120.603466, -120.60376600000001, -120.60246599999999, -120.600466, -120.593766, -120.587066, -120.583366, -120.57756499999999, -120.574265, -120.572265, -120.569465, -120.567465, -120.566965, -120.560065, -120.558264, -120.556464, -120.553064, -120.552064, -120.551164, -120.549064, -120.547364, -120.544783, -120.539245, -120.535308, -120.531013, -120.528516, -120.524742, -120.52092400000001, -120.517573, -120.515688, -120.513313, -120.510188, -120.508107, -120.506384, -120.499805, -120.49846099999999, -120.496624, -120.493853, -120.490833, -120.488779, -120.488689, -120.489739, -120.492223, -120.492223, -120.491732, -120.489585, -120.485156, -120.48244, -120.48231, -120.47990300000001, -120.479474, -120.478341, -120.47836, -120.479181, -120.480276, -120.482367, -120.485326, -120.486421, -120.484741, -120.481042, -120.479303, -120.477833, -120.478087, -120.477475, -120.472696, -120.469915, -120.47018, -120.46897, -120.46795, -120.464725, -120.459735, -120.45746, -120.453915, -120.452159, -120.449588, -120.44422, -120.440538, -120.438299, -120.439925, -120.444612, -120.446258, -120.446592, -120.444248, -120.438889, -120.432693, -120.428135, -120.426305, -120.421999, -120.41605200000001, -120.411699, -120.410742, -120.409413, -120.408982, -120.409128, -120.408536, -120.40536, -120.404938, -120.402654, -120.402578, -120.404832, -120.407117, -120.407663, -120.407038, -120.40567300000001, -120.402107, -120.40132299999999, -120.392574, -120.39076299999999, -120.388305, -120.386122, -120.385845, -120.384579, -120.381856, -120.377466, -120.372265, -120.365267, -120.359875, -120.35798, -120.357804, -120.359512, -120.36540099999999, -120.369313, -120.372139, -120.375793, -120.376156, -120.38048599999999, -120.380493, -120.379469, -120.377837, -120.376304, -120.370994, -120.367013, -120.365217, -120.364122, -120.360771, -120.359976, -120.360827, -120.363246, -120.364955, -120.365655, -120.36785499999999, -120.37342699999999, -120.377756, -120.382056, -120.386686, -120.39445599999999, -120.399056, -120.405557, -120.409557, -120.414957, -120.422581, -120.426856, -120.426057, -120.423357, -120.424257, -120.423257, -120.420557, -120.417857, -120.412857, -120.411057, -120.407256, -120.407022, -120.409948, -120.416409, -120.421449, -120.42290299999999, -120.429082, -120.43323, -120.438779, -120.441284, -120.446592, -120.449907, -120.45441, -120.459937, -120.462291, -120.46966, -120.472759, -120.477559, -120.481228, -120.483859, -120.490359, -120.495859, -120.493459, -120.491759, -120.489859, -120.486359, -120.482359, -120.481559, -120.483459, -120.489859, -120.493659, -120.495159, -120.496859, -120.496059, -120.492159, -120.487859, -120.48443499999999, -120.482941, -120.48365799999999, -120.486758, -120.492259, -120.493959, -120.501159, -120.501859, -120.505859, -120.506459, -120.506059, -120.502959, -120.494059, -120.489058, -120.48415800000001, -120.482958, -120.484258, -120.489258, -120.49225799999999, -120.49575899999999, -120.498759, -120.501159, -120.502659, -120.506259, -120.507959, -120.509659, -120.514759, -120.519859, -120.525059, -120.527559, -120.528659, -120.519359, -120.51845900000001, -120.523059, -120.525259, -120.528159, -120.530159, -120.532059, -120.53255899999999, -120.529759, -120.522659, -120.515159, -120.513358, -120.512558, -120.513158, -120.51495800000001, -120.516659, -120.521859, -120.524059, -120.523459, -120.52445900000001, -120.527059, -120.532059, -120.534459, -120.534659, -120.531859, -120.530659, -120.533659, -120.533659, -120.535559, -120.540159, -120.543059, -120.543359, -120.541459, -120.533958, -120.53245799999999, -120.531258, -120.530458, -120.531258, -120.53075799999999, -120.530958, -120.531958, -120.534358, -120.539658, -120.541258, -120.539358, -120.535158, -120.529458, -120.52735799999999, -120.528058, -120.527458, -120.530358, -120.538758, -120.540458, -120.540758, -120.538858, -120.531858, -120.525558, -120.524658, -120.524057, -120.524457, -120.527757, -120.531558, -120.53465800000001, -120.536858, -120.537758, -120.538558, -120.540358, -120.542258, -120.545458, -120.548158, -120.547758, -120.54665800000001, -120.544258, -120.54275799999999, -120.543158, -120.544858, -120.547358, -120.553358, -120.55555799999999, -120.553158, -120.549158, -120.54785799999999, -120.542858, -120.541758, -120.540257, -120.540289, -120.541857, -120.545158, -120.546358, -120.547057, -120.544657, -120.541657, -120.538157, -120.535957, -120.533657, -120.534457, -120.535757, -120.540657, -120.542857, -120.550957, -120.554457, -120.556057, -120.55205699999999, -120.550663, -120.551139, -120.55035699999999, -120.546457, -120.544157, -120.542956, -120.541656, -120.543656, -120.545356, -120.544856, -120.541956, -120.54005599999999, -120.534156, -120.530056, -120.528456, -120.52595600000001, -120.524455, -120.523855, -120.524455, -120.527555, -120.529355, -120.53305499999999, -120.537556, -120.540256, -120.542856, -120.543008, -120.541755, -120.540955, -120.536755, -120.534055, -120.532555, -120.531655, -120.529055, -120.52415500000001, -120.521555, -120.520455, -120.521254, -120.51935399999999, -120.516054, -120.509454, -120.506254, -120.502854, -120.497954, -120.49355299999999, -120.48849, -120.484853, -120.481653, -120.480953, -120.481153, -120.482353, -120.487153, -120.487653, -120.485552, -120.483352, -120.480152, -120.474752, -120.472652, -120.473652, -120.476752, -120.480152, -120.482552, -120.48405199999999, -120.483552, -120.48025200000001, -120.476852, -120.472951, -120.469549, -120.46855099999999, -120.468951, -120.471551, -120.474951, -120.47625099999999, -120.47675100000001, -120.47625099999999, -120.475351, -120.466995, -120.464991, -120.46295, -120.457069, -120.45224999999999, -120.44886, -120.450097, -120.453041, -120.45505, -120.45865, -120.46045, -120.46215, -120.465706, -120.463787, -120.460249, -120.458449, -120.458449, -120.461049, -120.460549, -120.461249, -120.463448, -120.463648, -120.462548, -120.46454800000001, -120.46744799999999, -120.46844899999999, -120.468849, -120.470649, -120.476849, -120.479249, -120.482849, -120.486949, -120.491949, -120.494749, -120.498149, -120.50115, -120.50345, -120.50686400000001, -120.51005, -120.51485, -120.512249, -120.508549, -120.504449, -120.503733, -120.504419, -120.626232, -120.688617, -120.729792, -120.730182, -120.729292, -120.729487, -120.728574, -120.72632899999999, -120.727391, -120.727052, -120.728455, -120.727736, -120.726605, -120.725299, -120.72258099999999, -120.721768, -120.720072, -120.718099, -120.719022, -120.718381, -120.718645, -120.722032, -120.722779, -120.72414, -120.72332, -120.724375, -120.72316599999999, -120.726786, -120.727515, -120.731003, -120.733197, -120.734189, -120.737715, -120.739885, -120.742358, -120.744025, -120.745747, -120.74656999999999, -120.747881, -120.74927, -120.75116, -120.753057, -120.75507999999999, -120.757615, -120.761281, -120.761838, -120.76098999999999, -120.764167, -120.765987, -120.76907, -120.769379, -120.76791399999999, -120.767269, -120.769803, -120.770957, -120.77188699999999, -120.77646899999999, -120.779175, -120.781447, -120.785207, -120.789015, -120.790705, -120.79168899999999, -120.793721, -120.79614, -120.797512, -120.79951299999999, -120.801544, -120.802598, -120.804459, -120.807057, -120.810019, -120.810337, -120.814098, -120.81657200000001, -120.818038, -120.82114, -120.824421, -120.826779, -120.82870199999999, -120.830944, -120.8339, -120.83473000000001, -120.837282, -120.838408, -120.841194, -120.846485, -120.848278, -120.850241, -120.852133, -120.855029, -120.857412, -120.858274, -120.862649, -120.866917, -120.869892, -120.874104, -120.880732, -120.883252, -120.885464, -120.889357, -120.890777, -120.891826, -120.893665, -120.89586, -120.89626200000001, -120.900336, -120.90386699999999, -120.906598, -120.907903, -120.91103, -120.913498, -120.915516, -120.92040399999999, -120.921218, -120.918168, -120.919952, -120.92356, -120.925671, -120.92825500000001, -120.929924, -120.930986, -120.932135, -120.933105, -120.934796, -120.93758199999999, -120.939568, -120.940399, -120.94174100000001, -120.943269, -120.944643, -120.945892, -120.94881699999999, -120.949477, -120.95345, -120.955009, -120.952541, -120.952936, -120.95376999999999, -120.960641, -120.96269, -120.965499, -120.969286, -120.971202, -120.976906, -120.978751, -120.979915, -120.981623, -120.98290399999999, -120.984454, -120.987364, -120.987691, -120.99060399999999, -120.992661, -120.994305, -120.996115, -120.996341, -120.99801099999999, -121.002122, -121.004846, -121.005607, -121.00779, -121.009205, -121.012104, -121.013426, -121.01275799999999, -121.01339, -121.015251, -121.017818, -121.018916, -121.01921300000001, -121.017603, -121.017866, -121.022616, -121.024, -121.024294, -121.023358, -121.021783, -121.020802, -121.023205, -121.02369, -121.019103, -121.020535, -121.022339, -121.024289, -121.020562, -121.022387, -121.022886, -121.025146, -121.025194, -121.023648, -121.023799, -121.02170000000001, -121.022667, -121.022588, -121.023321, -121.022639, -121.024033, -121.022217, -121.020367, -121.018924, -121.019468, -121.023617, -121.024876, -121.024135, -121.021053, -121.017426, -121.017771, -121.02073899999999, -121.028421, -121.03044, -121.03120200000001, null], "line": {"color": "rgb(15, 15, 55)", "width": 0.5}, "type": "scatter", "fill": "toself"}, {"name": 1953, "fillcolor": "#bebada", "mode": "lines", "hoverinfo": "text", "y": [45.7372486812962, 45.745847, 45.746547, 45.7383479999999 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it seems like a lot of the options here are set to their default?
I would double check these and remove/simplify any attributes that are set to their default, for example:
isn't the scope default 'usa'?
|
||
<span class="n">fig</span> <span class="o">=</span> <span class="n">ff</span><span class="o">.</span><span class="n">create_choropleth</span><span class="p">(</span> | ||
<span class="n">fips</span><span class="o">=</span><span class="n">fips</span><span class="p">,</span> <span class="n">values</span><span class="o">=</span><span class="n">values</span><span class="p">,</span> <span class="n">scope</span><span class="o">=</span><span class="p">[</span><span class="s1">'CA'</span><span class="p">,</span> <span class="s1">'AZ'</span><span class="p">,</span> <span class="s1">'Nevada'</span><span class="p">,</span> <span class="s1">'Oregon'</span><span class="p">,</span> <span class="s1">' Idaho'</span><span class="p">],</span> | ||
<span class="n">binning_endpoints</span><span class="o">=</span><span class="p">[</span><span class="mi">14348</span><span class="p">,</span> <span class="mi">63983</span><span class="p">,</span> <span class="mi">134827</span><span class="p">,</span> <span class="mi">426762</span><span class="p">,</span> <span class="mi">2081313</span><span class="p">],</span> <span class="n">colorscale</span><span class="o">=</span><span class="n">colorscale</span><span class="p">,</span> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would be good to explain what binning endpoints is
I think |
@Kully sure |
@cldougl whenever you have time for a 2nd 👀 NB I removed Can you check if my syntax is correct? |
looks like the |
I don't see the folder in my local branch. Where do you see the folder? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
overall looks good!
"name": "stdout", | ||
"output_type": "stream", | ||
"text": [ | ||
"The draw time for this plot will be slow for clients without much RAM.\n" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this warning is ok
"name": "stderr", | ||
"output_type": "stream", | ||
"text": [ | ||
"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/plotly/api/v1/clientresp.py:40: UserWarning:\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you remove this warning from the docs?
(you can run the cell twice or run:
import warnings
warnings.filterwarnings('ignore')
in the beginning of your notebook )
"collapsed": false | ||
}, | ||
"execution_count": 5, | ||
"metadata": {}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm looks like there's no reference section in this doc- can you add a reference section pointing to: https://plot.ly/python/reference/#choropleth
<div class="text_cell_render border-box-sizing rendered_html"> | ||
<h4 id="FIPS-and-Values">FIPS and Values<a class="anchor-link" href="#FIPS-and-Values">¶</a></h4><p>Every US state and county has an assined ID regulated by the US Federal Government under the term FIPS (Federal Information Processing Standards) codes. There are state codes and county codes: the 2016 state and county FIPS codes can be found at the <a href="https://www.census.gov/geographies/reference-files/2016/demo/popest/2016-fips.html">US Census Website</a>.</p> | ||
<p>Combine a state FIPS code (eg. <code>06</code> for California) with a county FIPS code of the state (eg. <code>059</code> for Orange county) and this new state-county FIPS code (<code>06059</code>) uniquely refers to the specified state and county.</p> | ||
<p><code>ff.create_choropleth</code> only needs a list of FIPS codes and a list of values.</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<p>By default <code>scope</code> is set to <code>['USA']</code> which the API treats as identical to passing a list of all 50 state names:<br></p> | ||
<p><code>['AK', 'AL', 'CA', ...]</code></p> | ||
<p>State abbreviations (eg. <code>CA</code>) or the proper names (eg. <code>California</code>) as strings are accepted. If the state name is not recognized, the API will throw a Warning and indicate which FIPS values were ignored.</p> | ||
<p>Another param used in the example below is <code>binning_endpoints</code>. If your <code>values</code> is a list of numbers, you can bin your values into half-open intervals on the real line.</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah I see!
<p><code>['AK', 'AL', 'CA', ...]</code></p> | ||
<p>State abbreviations (eg. <code>CA</code>) or the proper names (eg. <code>California</code>) as strings are accepted. If the state name is not recognized, the API will throw a Warning and indicate which FIPS values were ignored.</p> | ||
<p>Another param used in the example below is <code>binning_endpoints</code>. If your <code>values</code> is a list of numbers, you can bin your values into half-open intervals on the real line.</p> | ||
<p>For example if <code>binning_endpoints = [4, 7]</code> then each <code>x</code> from <code>values</code> will be grouped into one of the following bins:</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cldougl all comments addressed |
💃 💃 💃 |
todo: