{"size":{"Width":770,"Height":453},"appearance":{"background":null,"padding":14,"font":{"family":"Courier New","size":10.0,"bold":false,"italic":false,"underline":false,"strikeout":false,"color":"rgb(0,72,168)"},"border":{"on":true,"size":0.0,"style":"solid","color":"#666"},"text":{"wrap":false,"hAlign":"left","vAlign":"top"}},"outputType":"WIDGET","widgetState":null,"wikiPageTitle":null,"outputs":{"htmlwidgets":"<div id=\"htmlwidget_container\">\n <div id=\"htmlwidget-ac9edbfbee9220a3a35a\" style=\"width:100%;height:400px;\" class=\"plotly html-widget\"></div>\n</div>\n<script type=\"application/json\" data-for=\"htmlwidget-ac9edbfbee9220a3a35a\">{\"x\":{\"visdat\":{\"463b57cb042c\":[\"function () \",\"plotlyVisDat\"]},\"cur_data\":\"463b57cb042c\",\"attrs\":{\"463b57cb042c\":{\"locationmode\":\"USA-states\",\"alpha_stroke\":1,\"sizes\":[10,100],\"spans\":[1,20],\"hoverinfo\":\"location+text\",\"z\":[0.6208,0.5128,0.4867,0.6057,0.3162,0.4325,0.4093,0.4172,0.0407,0.4902,0.5077,0.3003,0.5926,0.3876,0.5682,0.5115,0.5665,0.6252,0.5809,0.4487,0.3391,0.3281,0.475,0.4492,0.5794,0.5677,0.5617,0.5875,0.455,0.4661,0.41,0.4004,0.3652,0.4983,0.6296,0.5169,0.6532,0.3909,0.4818,0.389,0.5494,0.6153,0.6072,0.5223,0.4554,0.3027,0.4441,0.3683,0.685,0.4722,0.674],\"zmin\":0,\"zmax\":1,\"color\":[0.6208,0.5128,0.4867,0.6057,0.3162,0.4325,0.4093,0.4172,0.0407,0.4902,0.5077,0.3003,0.5926,0.3876,0.5682,0.5115,0.5665,0.6252,0.5809,0.4487,0.3391,0.3281,0.475,0.4492,0.5794,0.5677,0.5617,0.5875,0.455,0.4661,0.41,0.4004,0.3652,0.4983,0.6296,0.5169,0.6532,0.3909,0.4818,0.389,0.5494,0.6153,0.6072,0.5223,0.4554,0.3027,0.4441,0.3683,0.685,0.4722,0.674],\"colors\":[\"#0000FF\",\"#FFFFFF\",\"#FF0000\"],\"locations\":[\"AL\",\"AK\",\"AZ\",\"AR\",\"CA\",\"CO\",\"CT\",\"DE\",\"DC\",\"FL\",\"GA\",\"HI\",\"ID\",\"IL\",\"IN\",\"IA\",\"KS\",\"KY\",\"LA\",\"ME\",\"MD\",\"MA\",\"MI\",\"MN\",\"MS\",\"MO\",\"MT\",\"NE\",\"NV\",\"NH\",\"NJ\",\"NM\",\"NY\",\"NC\",\"ND\",\"OH\",\"OK\",\"OR\",\"PA\",\"RI\",\"SC\",\"SD\",\"TN\",\"TX\",\"UT\",\"VT\",\"VA\",\"WA\",\"WV\",\"WI\",\"WY\"],\"text\":[\"62%\",\"51%\",\"49%\",\"61%\",\"32%\",\"43%\",\"41%\",\"42%\",\"4%\",\"49%\",\"51%\",\"30%\",\"59%\",\"39%\",\"57%\",\"51%\",\"57%\",\"63%\",\"58%\",\"45%\",\"34%\",\"33%\",\"48%\",\"45%\",\"58%\",\"57%\",\"56%\",\"59%\",\"46%\",\"47%\",\"41%\",\"40%\",\"37%\",\"50%\",\"63%\",\"52%\",\"65%\",\"39%\",\"48%\",\"39%\",\"55%\",\"62%\",\"61%\",\"52%\",\"46%\",\"30%\",\"44%\",\"37%\",\"68%\",\"47%\",\"67%\"],\"marker\":{\"line\":{\"color\":\"#666666\",\"width\":0}},\"inherit\":true}},\"layout\":{\"margin\":{\"b\":40,\"l\":70,\"t\":48.8,\"r\":70,\"pad\":0},\"mapType\":\"geo\",\"scene\":{\"zaxis\":{\"title\":[]}},\"geo\":{\"domain\":{\"x\":[0,1],\"y\":[0,1]},\"scope\":\"usa\",\"showframe\":false,\"showcoastlines\":true,\"showland\":true,\"landcolor\":\"#808080\",\"showcountries\":true,\"coastlinecolor\":\"#FFFFFF\",\"coastlinewidth\":0.25,\"countrycolor\":\"#666666\",\"countrywidth\":0.25,\"showocean\":true,\"oceancolor\":\"#FFFFFF\",\"showlakes\":true,\"lakecolor\":\"#FFFFFF\",\"projection\":{\"type\":\"Mercator\"},\"resolution\":110,\"lataxis\":[],\"bgcolor\":\"rgba(255,255,255,0)\"},\"hovermode\":\"closest\",\"showlegend\":false,\"legend\":{\"yanchor\":\"top\",\"y\":0.5},\"title\":\"Custom palette\",\"titlefont\":{\"family\":\"Arial\",\"color\":\"#2C2C2C\",\"size\":16},\"annotations\":[{\"text\":\"Results of the US 2016 presidential election\",\"font\":{\"family\":\"Arial\",\"color\":\"#2C2C2C\",\"size\":12},\"xref\":\"paper\",\"x\":0.5,\"xshift\":0,\"yref\":\"paper\",\"y\":1,\"yanchor\":\"bottom\",\"showarrow\":false},{\"text\":\" <br>Data source: https://en.wikipedia.org/wiki/United_States_presidential_election,_2016\",\"font\":{\"family\":\"Arial\",\"color\":\"#2C2C2C\",\"size\":8},\"xref\":\"paper\",\"x\":0.5,\"yref\":\"paper\",\"y\":0,\"yanchor\":\"top\",\"xanchor\":\"center\",\"showarrow\":false}],\"hoverlabel\":{\"namelength\":-1,\"font\":{\"family\":\"Arial\",\"color\":\"white\",\"size\":12}},\"paper_bgcolor\":\"transparent\"},\"source\":\"A\",\"config\":{\"modeBarButtonsToAdd\":[{\"name\":\"Collaborate\",\"icon\":{\"width\":1000,\"ascent\":500,\"descent\":-50,\"path\":\"M487 375c7-10 9-23 5-36l-79-259c-3-12-11-23-22-31-11-8-22-12-35-12l-263 0c-15 0-29 5-43 15-13 10-23 23-28 37-5 13-5 25-1 37 0 0 0 3 1 7 1 5 1 8 1 11 0 2 0 4-1 6 0 3-1 5-1 6 1 2 2 4 3 6 1 2 2 4 4 6 2 3 4 5 5 7 5 7 9 16 13 26 4 10 7 19 9 26 0 2 0 5 0 9-1 4-1 6 0 8 0 2 2 5 4 8 3 3 5 5 5 7 4 6 8 15 12 26 4 11 7 19 7 26 1 1 0 4 0 9-1 4-1 7 0 8 1 2 3 5 6 8 4 4 6 6 6 7 4 5 8 13 13 24 4 11 7 20 7 28 1 1 0 4 0 7-1 3-1 6-1 7 0 2 1 4 3 6 1 1 3 4 5 6 2 3 3 5 5 6 1 2 3 5 4 9 2 3 3 7 5 10 1 3 2 6 4 10 2 4 4 7 6 9 2 3 4 5 7 7 3 2 7 3 11 3 3 0 8 0 13-1l0-1c7 2 12 2 14 2l218 0c14 0 25-5 32-16 8-10 10-23 6-37l-79-259c-7-22-13-37-20-43-7-7-19-10-37-10l-248 0c-5 0-9-2-11-5-2-3-2-7 0-12 4-13 18-20 41-20l264 0c5 0 10 2 16 5 5 3 8 6 10 11l85 282c2 5 2 10 2 17 7-3 13-7 17-13z m-304 0c-1-3-1-5 0-7 1-1 3-2 6-2l174 0c2 0 4 1 7 2 2 2 4 4 5 7l6 18c0 3 0 5-1 7-1 1-3 2-6 2l-173 0c-3 0-5-1-8-2-2-2-4-4-4-7z m-24-73c-1-3-1-5 0-7 2-2 3-2 6-2l174 0c2 0 5 0 7 2 3 2 4 4 5 7l6 18c1 2 0 5-1 6-1 2-3 3-5 3l-174 0c-3 0-5-1-7-3-3-1-4-4-5-6z\"},\"click\":\"function(gd) { \\n // is this being viewed in RStudio?\\n if (location.search == '?viewer_pane=1') {\\n alert('To learn about plotly for collaboration, visit:\\\\n https://cpsievert.github.io/plotly_book/plot-ly-for-collaboration.html');\\n } else {\\n window.open('https://cpsievert.github.io/plotly_book/plot-ly-for-collaboration.html', '_blank');\\n }\\n }\"}],\"cloud\":false,\"displayModeBar\":false},\"data\":[{\"colorbar\":{\"title\":\"Republican<br>voters\",\"ticklen\":2,\"len\":0.5,\"lenmode\":\"fraction\",\"y\":0.5,\"yanchor\":\"middle\",\"x\":1,\"outlinewidth\":0,\"ypad\":0,\"tickfont\":{\"family\":\"Arial\",\"color\":\"#2C2C2C\",\"size\":10},\"titlefont\":{\"family\":\"Arial\",\"color\":\"#2C2C2C\",\"size\":10},\"tickformat\":\".0%\",\"separatethousands\":false},\"colorscale\":[[\"0\",\"rgba(0,0,255,1)\"],[\"0.408388949247245\",\"rgba(230,212,255,1)\"],[\"0.448910962802007\",\"rgba(241,231,255,1)\"],[\"0.504850225050442\",\"rgba(255,253,252,1)\"],[\"0.539138082673703\",\"rgba(255,240,235,1)\"],[\"0.549679238449997\",\"rgba(255,236,229,1)\"],[\"0.572636970355424\",\"rgba(255,227,217,1)\"],[\"0.598207356821356\",\"rgba(255,218,204,1)\"],[\"0.630865538827668\",\"rgba(255,205,188,1)\"],[\"0.640772931864038\",\"rgba(255,201,183,1)\"],[\"0.657483573904496\",\"rgba(255,195,175,1)\"],[\"0.673702726473175\",\"rgba(255,188,167,1)\"],[\"0.692224119199131\",\"rgba(255,181,157,1)\"],[\"0.71144394433235\",\"rgba(255,174,148,1)\"],[\"0.731051787469605\",\"rgba(255,166,139,1)\"],[\"0.741191991308397\",\"rgba(255,162,134,1)\"],[\"0.795902529877386\",\"rgba(255,139,108,1)\"],[\"0.816855502095297\",\"rgba(255,130,98,1)\"],[\"0.82740959180506\",\"rgba(255,126,93,1)\"],[\"0.84440478038181\",\"rgba(255,118,85,1)\"],[\"0.870143307982824\",\"rgba(255,106,73,1)\"],[\"0.888677634642247\",\"rgba(255,97,64,1)\"],[\"0.906047907289565\",\"rgba(255,88,56,1)\"],[\"0.947591701588287\",\"rgba(255,63,35,1)\"],[\"1\",\"rgba(255,0,0,1)\"]],\"showscale\":true,\"locationmode\":\"USA-states\",\"hoverinfo\":[\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\",\"location+text\"],\"z\":[0.6208,0.5128,0.4867,0.6057,0.3162,0.4325,0.4093,0.4172,0.0407,0.4902,0.5077,0.3003,0.5926,0.3876,0.5682,0.5115,0.5665,0.6252,0.5809,0.4487,0.3391,0.3281,0.475,0.4492,0.5794,0.5677,0.5617,0.5875,0.455,0.4661,0.41,0.4004,0.3652,0.4983,0.6296,0.5169,0.6532,0.3909,0.4818,0.389,0.5494,0.6153,0.6072,0.5223,0.4554,0.3027,0.4441,0.3683,0.685,0.4722,0.674],\"zmin\":0,\"zmax\":1,\"locations\":[\"AL\",\"AK\",\"AZ\",\"AR\",\"CA\",\"CO\",\"CT\",\"DE\",\"DC\",\"FL\",\"GA\",\"HI\",\"ID\",\"IL\",\"IN\",\"IA\",\"KS\",\"KY\",\"LA\",\"ME\",\"MD\",\"MA\",\"MI\",\"MN\",\"MS\",\"MO\",\"MT\",\"NE\",\"NV\",\"NH\",\"NJ\",\"NM\",\"NY\",\"NC\",\"ND\",\"OH\",\"OK\",\"OR\",\"PA\",\"RI\",\"SC\",\"SD\",\"TN\",\"TX\",\"UT\",\"VT\",\"VA\",\"WA\",\"WV\",\"WI\",\"WY\"],\"text\":[\"62%\",\"51%\",\"49%\",\"61%\",\"32%\",\"43%\",\"41%\",\"42%\",\"4%\",\"49%\",\"51%\",\"30%\",\"59%\",\"39%\",\"57%\",\"51%\",\"57%\",\"63%\",\"58%\",\"45%\",\"34%\",\"33%\",\"48%\",\"45%\",\"58%\",\"57%\",\"56%\",\"59%\",\"46%\",\"47%\",\"41%\",\"40%\",\"37%\",\"50%\",\"63%\",\"52%\",\"65%\",\"39%\",\"48%\",\"39%\",\"55%\",\"62%\",\"61%\",\"52%\",\"46%\",\"30%\",\"44%\",\"37%\",\"68%\",\"47%\",\"67%\"],\"marker\":{\"line\":{\"colorbar\":{\"title\":\"\",\"ticklen\":2},\"cmin\":0.0407,\"cmax\":0.685,\"colorscale\":[[\"0\",\"rgba(0,0,255,1)\"],[\"0.408388949247245\",\"rgba(230,212,255,1)\"],[\"0.448910962802007\",\"rgba(241,231,255,1)\"],[\"0.504850225050442\",\"rgba(255,253,252,1)\"],[\"0.539138082673703\",\"rgba(255,240,235,1)\"],[\"0.549679238449997\",\"rgba(255,236,229,1)\"],[\"0.572636970355424\",\"rgba(255,227,217,1)\"],[\"0.598207356821356\",\"rgba(255,218,204,1)\"],[\"0.630865538827668\",\"rgba(255,205,188,1)\"],[\"0.640772931864038\",\"rgba(255,201,183,1)\"],[\"0.657483573904496\",\"rgba(255,195,175,1)\"],[\"0.673702726473175\",\"rgba(255,188,167,1)\"],[\"0.692224119199131\",\"rgba(255,181,157,1)\"],[\"0.71144394433235\",\"rgba(255,174,148,1)\"],[\"0.731051787469605\",\"rgba(255,166,139,1)\"],[\"0.741191991308397\",\"rgba(255,162,134,1)\"],[\"0.795902529877386\",\"rgba(255,139,108,1)\"],[\"0.816855502095297\",\"rgba(255,130,98,1)\"],[\"0.82740959180506\",\"rgba(255,126,93,1)\"],[\"0.84440478038181\",\"rgba(255,118,85,1)\"],[\"0.870143307982824\",\"rgba(255,106,73,1)\"],[\"0.888677634642247\",\"rgba(255,97,64,1)\"],[\"0.906047907289565\",\"rgba(255,88,56,1)\"],[\"0.947591701588287\",\"rgba(255,63,35,1)\"],[\"1\",\"rgba(255,0,0,1)\"]],\"showscale\":false,\"color\":\"#666666\",\"width\":0}},\"type\":\"choropleth\",\"geo\":\"geo\",\"frame\":null}],\"highlight\":{\"on\":\"plotly_click\",\"persistent\":false,\"dynamic\":false,\"selectize\":false,\"opacityDim\":0.2,\"selected\":{\"opacity\":1},\"debounce\":0},\"base_url\":\"https://plot.ly\"},\"evals\":[\"config.modeBarButtonsToAdd.0.click\"],\"jsHooks\":[]}</script>\n<script type=\"application/htmlwidget-sizing\" data-for=\"htmlwidget-ac9edbfbee9220a3a35a\">{\"viewer\":{\"width\":\"100%\",\"height\":400,\"padding\":15,\"fill\":true},\"browser\":{\"width\":\"100%\",\"height\":400,\"padding\":0,\"fill\":true}}</script>","htmlwidget-head":"{\"stylesheets\":[\"https://rserverhtmlwidgetasset.azureedge.net/crosstalk-b25ccf47e9892cf2654d5ded8a45d9b7.css\",\"https://rserverhtmlwidgetasset.azureedge.net/plotly-htmlwidgets-ef6d87e1454c6f9f50a1a5a3e8b42646.css\"],\"javascript\":[\"https://rserverhtmlwidgetasset.azureedge.net/htmlwidgets-917a66c6e5036eb1bfd1fb672a82635a.js\",\"https://rserverhtmlwidgetasset.azureedge.net/plotly-c1d49eded87001936f93debf9b25b2d0.js\",\"https://rserverhtmlwidgetasset.azureedge.net/typedarray.min-830ee97537deb99885d830da3312e14d.js\",\"https://rserverhtmlwidgetasset.azureedge.net/jquery.min-91a24ea414e8c447d647cecab86866c2.js\",\"https://rserverhtmlwidgetasset.azureedge.net/crosstalk.min-b1936a0f8f135773de79f3a54af76d20.js\",\"https://rserverhtmlwidgetasset.azureedge.net/plotly-latest.min-a03b8e00ce1a91ef1a582ba5349a6a60.js\"],\"attachments\":[],\"widget-cannot-re-render\":false}","warning":""},"secondsTaken":5.2031265000000007,"updated":"2018-09-11T23:21:08.2531079Z","lastUpdatedMessage":null,"executedCode":null,"lastSavedCode":null,"highlightedCodeSpans":[{"start":121,"length":13,"index":4},{"start":137,"length":7,"index":6},{"start":146,"length":17,"index":6},{"start":2695,"length":13,"index":4},{"start":5041,"length":13,"index":4},{"start":5099,"length":13,"index":4},{"start":8960,"length":9,"index":4},{"start":9446,"length":10,"index":4},{"start":12277,"length":13,"index":4},{"start":12387,"length":13,"index":4},{"start":13024,"length":13,"index":4}],"tableTransformations":"<TabularTransformer>\r\n <TabularTransform type=\"Truncation\" truncationHeaderType=\"Column\" />\r\n <TabularTransform />\r\n</TabularTransformer>","tabularFilteringOptions":null,"hasGuiControls":true,"calculating":"Idle","showDebug":false,"layout":"OutputOnly","vSplit":0.25,"hSplit":0.45,"updateWarnings":true,"updateMode":"Manual","warnSlow":false,"Options":{"debugconsole":false,"codeposition":"OutputOnly","splitH":0.45,"splitV":0.25,"update warnings":true,"updating":"Manual","warn slow":false}}