Skip to content

Instantly share code, notes, and snippets.

@jeremycflin
Created September 14, 2017 16:51
Show Gist options
  • Save jeremycflin/e49bd7a68194f940bdd6677ea0a4ccea to your computer and use it in GitHub Desktop.
Save jeremycflin/e49bd7a68194f940bdd6677ea0a4ccea to your computer and use it in GitHub Desktop.
flubberized US states to/from hex
license: mit

This is a combination of quite a few numerous generous open-source contributions. Thanks especially to Mike Bostock, Noah Veltman, Bob Rudis, and Andy Teucher.

Code in R

library(d3r)
library(albersusa)
library(sf)
library(geojsonio)
library(rmapshaper)
library(htmltools)

tl <- tagList(
  tags$head(tags$script(src="https://unpkg.com/flubber")),
  tag("svg",list(id="map",style="height:400px; width:900px;")),
  tags$script(HTML(
sprintf(
"
  var us_geo = %s;
  var us_hex = %s;
  var projection = d3.geoAlbersUsa();
  projection.fitSize([450,400], us_geo);
  var path = d3.geoPath().projection(projection);
  var path_hex = d3.geoPath()
    .projection(d3.geoMercator().fitSize([450,400], us_hex));
  var svg = d3.select('#map');

  var states = svg.append('g')
    .attr('class','states')
    .selectAll('path')
    .data(us_geo.features)
    .enter()
      .append('path')
      .attr('d', path)
      .style('stroke', 'black')
      .style('fill', 'none')
      .style('pointer-events', 'all');

  var hexstates = svg.append('g')
    .attr('class', 'hex')
    .style('transform', 'translate(450px,0)')
    .selectAll('path')
    .data(us_hex.features)
    .enter()
      .append('path')
      .attr('d', path_hex)
      .style('stroke', 'black')
      .style('fill', 'none')
      .style('pointer-events', 'all');

  states.on('click', function(d) {
    var path_strings = flubber.splitPathString(path(d));

    var hex_path = hexstates.nodes()
          .filter(function(hd) {
            return d.properties.iso_3166_2 === d3.select(hd).datum().properties.iso3166_2
          })[0]
          .getAttribute('d');

    if(path_strings.length == 1) {
      var interpolator = flubber.interpolate(
        d3.select(this).attr('d'),
        hex_path
      );
    } else {
      var interpolator = flubber.combine(
        path_strings,
        hex_path,
        {single: true}
      );
    }

    var cloned = d3.select(
      d3.select('g.states')
        .node()
        .appendChild(this.cloneNode(true))
    );

    cloned
      .transition()
      .duration(2000)
      .attr('transform', 'translate(450,0)')
      .style('stroke', 'red')
      .style('stroke-width', '3px')
      .attrTween('d', function(){ return interpolator; })
      .transition()
      .style('opacity',0.001)
      .remove();
  })

  hexstates.on('click', function(d) {

    
    var state_path = states.nodes()
      .filter(function(hd) {
        return d.properties.iso3166_2 === d3.select(hd).datum().properties.iso_3166_2;
      })[0]
      .getAttribute('d');

    var path_strings = flubber.splitPathString(state_path);
    
    if(path_strings.length == 1) {
      var interpolator = flubber.interpolate(
        d3.select(this).attr('d'),
        state_path
      );
    } else {
      var interpolator = flubber.separate(
        d3.select(this).attr('d'),
        path_strings,
        {single: true}
      );
    }
    
    var cloned = d3.select(
      d3.select('g.hex')
        .node()
        .appendChild(this.cloneNode(true))
      );
    
    cloned
      .transition()
      .duration(2000)
      .attr('transform', 'translate(-450,0)')
      .style('stroke', 'red')
      .style('stroke-width', '3px')
      .attrTween('d', function(){ return interpolator; })
      .transition()
      .style('opacity',0.001)
      .remove();
  })
",
ms_simplify(geojson_json(usa_sf()), keep=0.03),
paste0(readLines("us_states_hexgrid.geojson"), collapse = "\n")
)
  )),
  d3_dep_v4(offline=FALSE)
)

browsable(tl)

forked from timelyportfolio's block: flubberized US states to/from hex

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/4.9.1/d3.min.js"></script>
<script src="https://unpkg.com/flubber"></script>
</head>
<body style="background-color:white;">
<h3>
<a href="https://github.com/veltman/flubber">Flubbered</a>
(thx <a href="https://noahveltman.com/">Noah Veltman</a>)
US States
</h3>
<svg id="map" style="height:400px; width:900px;"></svg>
<script>
var us_geo = {"type":"FeatureCollection","features":[
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-109.045223,36.999084],[-109.046481,35.546326],[-109.046182,34.522393],[-109.04687,33.372654],[-109.047926,32.426376],[-109.050044,31.332502],[-110.460172,31.333051],[-111.098097,31.339836],[-112.246102,31.704195],[-113.125961,31.97278],[-114.813613,32.494277],[-114.719633,32.718763],[-114.496827,32.822119],[-114.468605,32.971649],[-114.707819,33.091102],[-114.627125,33.433554],[-114.496489,33.696901],[-114.518434,33.917518],[-114.43338,34.088413],[-114.138282,34.30323],[-114.339627,34.451435],[-114.465607,34.69226],[-114.633051,34.869971],[-114.633013,35.002085],[-114.572747,35.138725],[-114.677643,35.489742],[-114.755618,36.087166],[-114.381446,36.141665],[-114.15413,36.023862],[-114.046838,36.194069],[-114.0506,37.000396],[-112.966471,37.000219],[-111.189888,37.000959],[-110.000677,36.997968],[-109.045223,36.999084]]]},"properties":{"geo_id":"0400000US04","fips_state":"04","name":"Arizona","lsad":"","census_area":113594.084,"iso_3166_2":"AZ","census":6392017,"pop_estimataes_base":6392310,"pop_2010":6411999,"pop_2011":6472867,"pop_2012":6556236,"pop_2013":6634997,"pop_2014":6731484,"rmapshaperid":0}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-94.042964,33.019219],[-94.04345,33.552253],[-94.355945,33.54318],[-94.485875,33.637867],[-94.431215,35.39429],[-94.617919,36.499414],[-93.426989,36.498585],[-91.404915,36.49712],[-90.152481,36.497952],[-90.06398,36.303038],[-90.368718,35.995812],[-89.733095,36.000608],[-89.686924,35.947716],[-89.884932,35.655107],[-90.179265,35.385194],[-90.064612,35.140621],[-90.309297,34.995694],[-90.307384,34.846195],[-90.537345,34.78417],[-90.565809,34.4354],[-90.764143,34.363396],[-90.913212,34.210355],[-90.887413,34.032505],[-91.139869,33.777117],[-91.215671,33.529423],[-91.085984,33.221644],[-91.166073,33.004106],[-92.222825,33.00908],[-94.042964,33.019219]]]},"properties":{"geo_id":"0400000US05","fips_state":"05","name":"Arkansas","lsad":"","census_area":52035.477,"iso_3166_2":"AR","census":2915918,"pop_estimataes_base":2915958,"pop_2010":2922297,"pop_2011":2938430,"pop_2012":2949300,"pop_2013":2958765,"pop_2014":2966369,"rmapshaperid":1}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-124.211605,41.99846],[-122.378193,42.009518],[-121.035195,41.993323],[-119.999168,41.99454],[-119.999866,41.183974],[-119.997291,40.071803],[-120.001014,38.999574],[-118.428581,37.895613],[-117.000895,36.847694],[-116.097216,36.158346],[-114.633013,35.002085],[-114.633051,34.869971],[-114.465607,34.69226],[-114.339627,34.451435],[-114.138282,34.30323],[-114.43338,34.088413],[-114.518434,33.917518],[-114.496489,33.696901],[-114.627125,33.433554],[-114.707819,33.091102],[-114.468605,32.971649],[-114.496827,32.822119],[-114.719633,32.718763],[-115.465164,32.6671],[-117.124862,32.534156],[-117.246069,32.669352],[-117.328359,33.121842],[-117.50565,33.334063],[-118.088896,33.729817],[-118.411211,33.741985],[-118.519514,34.027509],[-118.805114,34.001239],[-119.216441,34.146105],[-119.270144,34.252903],[-119.559459,34.413395],[-119.873971,34.408795],[-120.141165,34.473405],[-120.471376,34.447846],[-120.645739,34.581035],[-120.609898,34.842751],[-120.698906,35.171192],[-120.89679,35.247877],[-120.869209,35.403276],[-121.284973,35.674109],[-121.717176,36.195146],[-121.894714,36.317806],[-121.923866,36.634559],[-121.788278,36.803994],[-121.862266,36.931552],[-122.105976,36.955951],[-122.405073,37.195791],[-122.40085,37.359225],[-122.516689,37.52134],[-122.163049,37.667933],[-122.33079,37.78383],[-122.262861,38.0446],[-122.491283,38.108087],[-122.505383,37.822128],[-122.939711,38.031908],[-122.968569,38.242879],[-123.128825,38.450418],[-123.331899,38.565542],[-123.725367,38.917438],[-123.693969,39.057363],[-123.826306,39.36871],[-123.766475,39.552803],[-123.851714,39.832041],[-124.110549,40.103765],[-124.363414,40.260974],[-124.409591,40.438076],[-124.158322,40.876069],[-124.063076,41.439579],[-124.143479,41.709284],[-124.255994,41.783014],[-124.211605,41.99846]]]},"properties":{"geo_id":"0400000US06","fips_state":"06","name":"California","lsad":"","census_area":155779.22,"iso_3166_2":"CA","census":37253956,"pop_estimataes_base":37254503,"pop_2010":37336011,"pop_2011":37701901,"pop_2012":38062780,"pop_2013":38431393,"pop_2014":38802500,"rmapshaperid":2}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-104.053249,41.001406],[-102.051614,41.002377],[-102.051744,40.003078],[-102.045263,38.505395],[-102.04224,36.993083],[-103.002199,37.000104],[-104.732031,36.993447],[-106.869796,36.992426],[-109.045223,36.999084],[-109.042062,38.15549],[-109.051516,39.124982],[-109.050873,40.058915],[-109.050076,41.000659],[-107.317794,41.002957],[-105.730421,40.996886],[-104.053249,41.001406]]]},"properties":{"geo_id":"0400000US08","fips_state":"08","name":"Colorado","lsad":"","census_area":103641.888,"iso_3166_2":"CO","census":5029196,"pop_estimataes_base":5029324,"pop_2010":5048575,"pop_2011":5119661,"pop_2012":5191709,"pop_2013":5272086,"pop_2014":5355866,"rmapshaperid":3}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-71.799242,42.008065],[-71.797683,41.416709],[-71.85957,41.322399],[-72.386629,41.261798],[-72.9082,41.282932],[-73.130253,41.146797],[-73.657336,40.985171],[-73.727775,41.100696],[-73.550961,41.295422],[-73.487314,42.049638],[-71.799242,42.008065]]]},"properties":{"geo_id":"0400000US09","fips_state":"09","name":"Connecticut","lsad":"","census_area":4842.355,"iso_3166_2":"CT","census":3574097,"pop_estimataes_base":3574096,"pop_2010":3579345,"pop_2011":3590537,"pop_2012":3594362,"pop_2013":3599341,"pop_2014":3596677,"rmapshaperid":4}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-84.321869,34.988408],[-83.108535,35.000771],[-83.32406,34.788691],[-83.338194,34.687924],[-83.006848,34.474376],[-82.882864,34.479003],[-82.717507,34.150504],[-82.564582,33.95581],[-82.247472,33.752591],[-82.046335,33.56383],[-81.852136,33.247544],[-81.51169,33.024506],[-81.389338,32.595436],[-81.199029,32.467286],[-81.117234,32.117605],[-80.885517,32.0346],[-81.130634,31.722692],[-81.177254,31.517074],[-81.420474,31.016703],[-81.444124,30.709714],[-82.023213,30.781987],[-82.050069,30.362338],[-82.165192,30.358035],[-82.214385,30.566958],[-83.390062,30.639333],[-84.864693,30.711542],[-85.002368,31.000682],[-85.107516,31.186451],[-85.041305,31.540987],[-85.132931,31.88826],[-85.047865,32.142033],[-85.001324,32.512973],[-85.184131,32.870525],[-85.361844,33.773951],[-85.605165,34.984678],[-84.321869,34.988408]]]},"properties":{"geo_id":"0400000US13","fips_state":"13","name":"Georgia","lsad":"","census_area":57513.485,"iso_3166_2":"GA","census":9687653,"pop_estimataes_base":9688681,"pop_2010":9714464,"pop_2011":9813201,"pop_2012":9919000,"pop_2013":9994759,"pop_2014":10097343,"rmapshaperid":5}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-87.800477,42.49192],[-87.834769,42.301522],[-87.682359,42.075729],[-87.524044,41.708335],[-87.526809,40.46217],[-87.531646,39.347888],[-87.658746,39.135997],[-87.512187,38.954417],[-87.495211,38.78306],[-87.656144,38.521668],[-88.013118,38.103527],[-88.02803,37.799224],[-88.160187,37.657592],[-88.083395,37.473683],[-88.476592,37.386875],[-88.458948,37.073796],[-88.916934,37.224291],[-89.086526,37.165602],[-89.132685,36.9822],[-89.378277,37.039605],[-89.517032,37.28192],[-89.43604,37.344441],[-89.515436,37.67137],[-89.844786,37.905572],[-90.243116,38.112669],[-90.370819,38.333554],[-90.17801,38.63375],[-90.113327,38.849306],[-90.472122,38.958838],[-90.663372,38.928042],[-90.726981,39.251173],[-91.042351,39.452062],[-91.367753,39.729029],[-91.512974,40.181062],[-91.419422,40.378264],[-91.359873,40.601805],[-91.122421,40.670675],[-90.952233,40.954047],[-90.946627,41.096632],[-91.114186,41.250029],[-91.047819,41.4109],[-90.461432,41.523533],[-90.181973,41.80707],[-90.162225,42.11488],[-90.356964,42.205445],[-90.640927,42.508302],[-89.250759,42.497994],[-87.800477,42.49192]]]},"properties":{"geo_id":"0400000US17","fips_state":"17","name":"Illinois","lsad":"","census_area":55518.93,"iso_3166_2":"IL","census":12830632,"pop_estimataes_base":12831587,"pop_2010":12840097,"pop_2011":12858725,"pop_2012":12873763,"pop_2013":12890552,"pop_2014":12880580,"rmapshaperid":6}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-84.820157,39.10548],[-84.785799,38.869496],[-85.172528,38.688082],[-85.456978,38.689135],[-85.433136,38.523914],[-85.653641,38.327108],[-85.829364,38.276769],[-85.951467,38.005608],[-86.172186,38.00992],[-86.309727,38.144393],[-86.51176,38.044448],[-86.604624,37.858272],[-86.794985,37.988982],[-87.033444,37.906593],[-87.111133,37.782512],[-87.380247,37.935596],[-87.940005,37.875044],[-88.02803,37.799224],[-88.013118,38.103527],[-87.656144,38.521668],[-87.495211,38.78306],[-87.512187,38.954417],[-87.658746,39.135997],[-87.531646,39.347888],[-87.526809,40.46217],[-87.524044,41.708335],[-87.278437,41.619736],[-86.824828,41.76024],[-84.818873,41.760059],[-84.806082,41.696089],[-84.803918,40.310094],[-84.820157,39.10548]]]},"properties":{"geo_id":"0400000US18","fips_state":"18","name":"Indiana","lsad":"","census_area":35826.109,"iso_3166_2":"IN","census":6483802,"pop_estimataes_base":6484192,"pop_2010":6490308,"pop_2011":6516560,"pop_2012":6537632,"pop_2013":6570713,"pop_2014":6596855,"rmapshaperid":7}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-94.042964,33.019219],[-92.222825,33.00908],[-91.166073,33.004106],[-91.165328,32.751301],[-91.095308,32.458741],[-90.905173,32.315497],[-91.034707,32.101053],[-91.248144,31.869848],[-91.338414,31.851261],[-91.422691,31.55439],[-91.636942,30.999416],[-89.728147,31.002431],[-89.842596,30.666038],[-89.524504,30.180753],[-89.857558,30.004439],[-89.692004,29.868722],[-89.494064,30.040972],[-89.315453,29.923208],[-89.44812,29.703316],[-89.621109,29.657101],[-89.693877,29.508559],[-89.508551,29.386168],[-89.200599,29.347672],[-89.000674,29.180091],[-89.062335,29.070234],[-89.334735,29.040335],[-89.482844,29.215053],[-89.726162,29.304026],[-89.849642,29.477996],[-90.032298,29.427005],[-90.104162,29.150407],[-90.223587,29.085075],[-90.332796,29.276956],[-90.565436,29.285111],[-90.844593,29.06728],[-90.961278,29.180817],[-91.278792,29.247776],[-91.265649,29.472362],[-91.517274,29.52974],[-91.621512,29.735429],[-91.85864,29.703121],[-91.889118,29.836023],[-92.107486,29.744429],[-92.111787,29.62177],[-92.309357,29.533026],[-92.653651,29.588065],[-93.226934,29.777519],[-93.741948,29.736343],[-93.837971,29.690619],[-93.890679,29.843159],[-93.712101,30.067346],[-93.757654,30.390423],[-93.727844,30.57407],[-93.530936,30.924534],[-93.531744,31.180817],[-93.834924,31.586211],[-93.840029,31.800596],[-94.04272,31.999265],[-94.042964,33.019219]]]},"properties":{"geo_id":"0400000US22","fips_state":"22","name":"Louisiana","lsad":"","census_area":43203.905,"iso_3166_2":"LA","census":4533372,"pop_estimataes_base":4533479,"pop_2010":4545581,"pop_2011":4575972,"pop_2012":4604744,"pop_2013":4629284,"pop_2014":4649676,"rmapshaperid":8}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-91.217706,43.50055],[-92.790317,43.499567],[-93.795793,43.49952],[-95.514774,43.499865],[-96.453049,43.500415],[-96.453067,45.298115],[-96.680454,45.410499],[-96.857751,45.605962],[-96.583085,45.820024],[-96.56328,45.935238],[-96.598233,46.312563],[-96.783009,46.630418],[-96.862312,47.422333],[-96.850955,47.598287],[-97.14751,48.170572],[-97.092606,48.682033],[-97.229039,49.000687],[-95.153711,48.998903],[-95.153314,49.384358],[-94.824291,49.308834],[-94.683069,48.883929],[-94.533057,48.701262],[-93.840754,48.628548],[-93.794454,48.516021],[-93.467504,48.545664],[-93.254854,48.642784],[-92.980484,48.624915],[-92.656027,48.436709],[-92.26228,48.354933],[-91.71185,48.114598],[-91.290215,48.073945],[-90.839176,48.239511],[-90.751608,48.090968],[-90.136191,48.112136],[-89.897414,47.987599],[-89.974296,47.830514],[-90.537105,47.703055],[-91.170037,47.366266],[-91.477351,47.125667],[-92.094089,46.787839],[-92.01529,46.706469],[-92.292192,46.663242],[-92.294033,46.074377],[-92.656125,45.924442],[-92.869193,45.717568],[-92.883749,45.575483],[-92.664102,45.393309],[-92.760615,45.278827],[-92.750645,44.937299],[-92.802402,44.745167],[-92.549685,44.576],[-91.972493,44.36676],[-91.875158,44.200575],[-91.432522,43.996827],[-91.262436,43.792166],[-91.217706,43.50055]]]},"properties":{"geo_id":"0400000US27","fips_state":"27","name":"Minnesota","lsad":"","census_area":79626.743,"iso_3166_2":"MN","census":5303925,"pop_estimataes_base":5303925,"pop_2010":5310418,"pop_2011":5348036,"pop_2012":5380615,"pop_2013":5422060,"pop_2014":5457173,"rmapshaperid":9}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-88.200064,34.995634],[-88.097888,34.892202],[-88.24839,33.744908],[-88.340432,32.991199],[-88.471106,31.850949],[-88.395023,30.369425],[-88.45381,30.329626],[-89.016334,30.383898],[-89.419348,30.25432],[-89.524504,30.180753],[-89.842596,30.666038],[-89.728147,31.002431],[-91.636942,30.999416],[-91.422691,31.55439],[-91.338414,31.851261],[-91.248144,31.869848],[-91.034707,32.101053],[-90.905173,32.315497],[-91.095308,32.458741],[-91.165328,32.751301],[-91.166073,33.004106],[-91.085984,33.221644],[-91.215671,33.529423],[-91.139869,33.777117],[-90.887413,34.032505],[-90.913212,34.210355],[-90.764143,34.363396],[-90.565809,34.4354],[-90.537345,34.78417],[-90.307384,34.846195],[-90.309297,34.995694],[-89.138997,34.99433],[-88.200064,34.995634]]]},"properties":{"geo_id":"0400000US28","fips_state":"28","name":"Mississippi","lsad":"","census_area":46923.274,"iso_3166_2":"MS","census":2967297,"pop_estimataes_base":2968103,"pop_2010":2970811,"pop_2011":2978464,"pop_2012":2986137,"pop_2013":2992206,"pop_2014":2994079,"rmapshaperid":10}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-111.048974,44.474072],[-111.323669,44.724474],[-111.489008,44.705553],[-111.601249,44.55421],[-111.806528,44.515459],[-112.258297,44.564334],[-112.38708,44.460476],[-112.71911,44.504344],[-113.003544,44.450814],[-113.134617,44.763149],[-113.353631,44.791395],[-113.498745,44.942314],[-113.449349,45.045745],[-113.738729,45.329741],[-113.813933,45.600559],[-113.93422,45.682232],[-114.309613,45.469432],[-114.561773,45.565109],[-114.514596,45.840785],[-114.39376,45.89402],[-114.48312,46.129147],[-114.337942,46.641205],[-114.592264,46.632861],[-114.936015,46.899761],[-115.320184,47.255717],[-115.52369,47.298919],[-115.729861,47.447287],[-115.729123,47.703102],[-116.048421,47.97682],[-116.049193,49.000912],[-113.692982,48.997632],[-112.193588,48.998229],[-110.216135,48.999239],[-108.994722,48.999237],[-107.179865,48.999559],[-105.355888,48.999357],[-104.048736,48.999877],[-104.043242,47.747106],[-104.045443,45.94531],[-104.057698,44.997431],[-105.928184,44.993647],[-106.888773,44.995885],[-108.249345,44.999458],[-110.705272,44.992324],[-111.044275,45.001345],[-111.048974,44.474072]]]},"properties":{"geo_id":"0400000US30","fips_state":"30","name":"Montana","lsad":"","census_area":145545.801,"iso_3166_2":"MT","census":989415,"pop_estimataes_base":989417,"pop_2010":990575,"pop_2011":997661,"pop_2012":1005163,"pop_2013":1014864,"pop_2014":1023579,"rmapshaperid":11}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-106.528543,31.783907],[-108.208394,31.783599],[-108.208573,31.333395],[-109.050044,31.332502],[-109.047926,32.426376],[-109.04687,33.372654],[-109.046182,34.522393],[-109.046481,35.546326],[-109.045223,36.999084],[-106.869796,36.992426],[-104.732031,36.993447],[-103.002199,37.000104],[-103.002434,36.500397],[-103.041669,36.478514],[-103.042497,35.211862],[-103.043617,34.003633],[-103.064625,32.999899],[-103.064423,32.000518],[-104.531756,32.000117],[-105.429281,32.000577],[-106.599096,32.000731],[-106.528543,31.783907]]]},"properties":{"geo_id":"0400000US35","fips_state":"35","name":"New Mexico","lsad":"","census_area":121298.148,"iso_3166_2":"NM","census":2059179,"pop_estimataes_base":2059192,"pop_2010":2064950,"pop_2011":2078407,"pop_2012":2084594,"pop_2013":2086895,"pop_2014":2085572,"rmapshaperid":12}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-104.045443,45.94531],[-104.043242,47.747106],[-104.048736,48.999877],[-102.216993,48.998553],[-100.920577,48.99956],[-98.999819,48.999769],[-97.229039,49.000687],[-97.092606,48.682033],[-97.14751,48.170572],[-96.850955,47.598287],[-96.862312,47.422333],[-96.783009,46.630418],[-96.598233,46.312563],[-96.56328,45.935238],[-98.18563,45.936185],[-99.490254,45.940362],[-101.557276,45.9441],[-102.550947,45.945015],[-104.045443,45.94531]]]},"properties":{"geo_id":"0400000US38","fips_state":"38","name":"North Dakota","lsad":"","census_area":69000.798,"iso_3166_2":"ND","census":672591,"pop_estimataes_base":672591,"pop_2010":674345,"pop_2011":685242,"pop_2012":701705,"pop_2013":723857,"pop_2014":739482,"rmapshaperid":13}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-103.002434,36.500397],[-103.002199,37.000104],[-102.04224,36.993083],[-100.945566,36.998152],[-99.456203,36.999471],[-98.354073,36.997961],[-97.030082,36.998929],[-96.00081,36.99886],[-94.61808,36.998135],[-94.617919,36.499414],[-94.431215,35.39429],[-94.485875,33.637867],[-94.8693,33.745871],[-95.067253,33.917351],[-95.287565,33.873617],[-95.599678,33.934247],[-95.82468,33.837726],[-96.14807,33.837799],[-96.36959,33.716809],[-96.67858,33.892786],[-96.88301,33.868019],[-97.092414,33.733214],[-97.226522,33.914642],[-97.372941,33.819454],[-97.65621,33.989488],[-97.834333,33.857671],[-97.977859,33.889929],[-98.16912,34.114171],[-98.364023,34.157109],[-98.858419,34.152732],[-99.19089,34.215251],[-99.211423,34.337897],[-99.58006,34.416653],[-99.69497,34.378333],[-100.000381,34.560509],[-100.000392,35.619115],[-100.000406,36.499702],[-101.085156,36.499244],[-103.002434,36.500397]]]},"properties":{"geo_id":"0400000US40","fips_state":"40","name":"Oklahoma","lsad":"","census_area":68594.921,"iso_3166_2":"OK","census":3751351,"pop_estimataes_base":3751616,"pop_2010":3759481,"pop_2011":3786527,"pop_2012":3817059,"pop_2013":3853118,"pop_2014":3878051,"rmapshaperid":14}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-79.476662,39.721078],[-80.519342,39.721403],[-80.518991,40.638801],[-80.519461,41.977513],[-79.761951,42.26986],[-79.761374,41.999067],[-77.83203,41.998524],[-76.343722,41.998346],[-75.359579,41.999445],[-75.114399,41.843583],[-75.04049,41.569688],[-74.694914,41.357423],[-75.135526,40.973807],[-75.052538,40.872051],[-75.196533,40.751631],[-75.190161,40.589321],[-74.740605,40.13521],[-74.974713,40.048711],[-75.184952,39.881615],[-75.415041,39.801786],[-75.5799,39.838522],[-75.788359,39.721811],[-77.047104,39.72],[-78.380599,39.722554],[-79.476662,39.721078]]]},"properties":{"geo_id":"0400000US42","fips_state":"42","name":"Pennsylvania","lsad":"","census_area":44742.703,"iso_3166_2":"PA","census":12702379,"pop_estimataes_base":12702884,"pop_2010":12711077,"pop_2011":12743995,"pop_2012":12770043,"pop_2013":12781296,"pop_2014":12787209,"rmapshaperid":15}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-81.677535,36.588117],[-81.725938,36.340364],[-81.908137,36.302013],[-82.02664,36.130222],[-82.375558,36.105609],[-82.462958,36.007309],[-82.754465,36.004304],[-82.995803,35.773128],[-83.100233,35.774745],[-83.498335,35.562981],[-83.756917,35.563604],[-84.00225,35.422548],[-84.02351,35.295783],[-84.29024,35.225572],[-84.321869,34.988408],[-85.605165,34.984678],[-86.862147,34.991956],[-88.200064,34.995634],[-89.138997,34.99433],[-90.309297,34.995694],[-90.064612,35.140621],[-90.179265,35.385194],[-89.884932,35.655107],[-89.686924,35.947716],[-89.733095,36.000608],[-89.594,36.12719],[-89.509558,36.375065],[-89.5391,36.498201],[-89.485106,36.497692],[-89.417293,36.499033],[-88.053205,36.497129],[-88.070532,36.678118],[-87.853204,36.633247],[-86.473497,36.651671],[-85.471338,36.61638],[-83.690714,36.582581],[-83.675413,36.600814],[-81.677535,36.588117]]]},"properties":{"geo_id":"0400000US47","fips_state":"47","name":"Tennessee","lsad":"","census_area":41234.896,"iso_3166_2":"TN","census":6346105,"pop_estimataes_base":6346275,"pop_2010":6356628,"pop_2011":6398389,"pop_2012":6455177,"pop_2013":6497269,"pop_2014":6549352,"rmapshaperid":16}},
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[-75.242296,38.027206],[-75.349338,37.873143],[-75.514921,37.799149],[-75.594044,37.569698],[-75.800755,37.197297],[-76.025753,37.257407],[-75.909586,37.622671],[-75.669711,37.950796],[-75.242296,38.027206]]],[[[-77.719029,39.321125],[-77.458884,39.219826],[-77.519929,39.120925],[-77.1199,38.934311],[-77.038598,38.791513],[-77.1302,38.635017],[-77.32544,38.44885],[-77.240072,38.331598],[-77.030683,38.311623],[-76.838795,38.163476],[-76.613939,38.148587],[-76.516547,38.026566],[-76.236725,37.889174],[-76.307482,37.81235],[-76.300144,37.561734],[-76.387112,37.385061],[-76.428869,36.969947],[-75.996252,36.922047],[-75.867044,36.550754],[-76.916048,36.543815],[-78.529722,36.540981],[-80.228263,36.543867],[-81.677535,36.588117],[-83.675413,36.600814],[-83.199698,36.737487],[-82.565375,37.196092],[-82.350948,37.267077],[-81.968297,37.537798],[-81.925643,37.357316],[-81.678603,37.202467],[-81.362156,37.337687],[-81.225104,37.234874],[-80.947896,37.295872],[-80.511391,37.481672],[-80.314806,37.500943],[-80.296138,37.691783],[-80.002507,37.992767],[-79.921026,38.179954],[-79.689544,38.442511],[-79.312276,38.411876],[-79.210026,38.494231],[-78.993997,38.850102],[-78.601655,38.964603],[-78.41074,39.171983],[-78.347087,39.466012],[-77.828157,39.132329],[-77.719029,39.321125]]]]},"properties":{"geo_id":"0400000US51","fips_state":"51","name":"Virginia","lsad":"","census_area":39490.086,"iso_3166_2":"VA","census":8001024,"pop_estimataes_base":8001023,"pop_2010":8025376,"pop_2011":8110188,"pop_2012":8193422,"pop_2013":8270345,"pop_2014":8326289,"rmapshaperid":17}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-75.415041,39.801786],[-75.509742,39.686113],[-75.587147,39.651012],[-75.589439,39.460812],[-75.439027,39.313384],[-75.396277,39.057884],[-75.190552,38.806861],[-75.082153,38.772157],[-75.048939,38.451263],[-75.693521,38.460128],[-75.788359,39.721811],[-75.5799,39.838522],[-75.415041,39.801786]]]},"properties":{"geo_id":"0400000US10","fips_state":"10","name":"Delaware","lsad":"","census_area":1948.543,"iso_3166_2":"DE","census":897934,"pop_estimataes_base":897936,"pop_2010":899731,"pop_2011":907829,"pop_2012":916881,"pop_2013":925240,"pop_2014":935614,"rmapshaperid":18}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-81.968297,37.537798],[-82.297011,37.687273],[-82.464987,37.976859],[-82.644739,38.165487],[-82.593673,38.421809],[-82.34064,38.440948],[-82.172066,38.625984],[-82.215759,38.797462],[-82.002261,39.027878],[-81.759995,38.925828],[-81.749853,39.186489],[-81.467744,39.403774],[-81.215617,39.388602],[-80.829764,39.711839],[-80.806018,39.91713],[-80.599895,40.317669],[-80.518991,40.638801],[-80.519342,39.721403],[-79.476662,39.721078],[-79.486873,39.205961],[-79.08445,39.471356],[-78.968996,39.441543],[-78.760196,39.582154],[-78.468639,39.516789],[-78.43025,39.62329],[-78.191107,39.690262],[-77.902649,39.587796],[-77.719029,39.321125],[-77.828157,39.132329],[-78.347087,39.466012],[-78.41074,39.171983],[-78.601655,38.964603],[-78.993997,38.850102],[-79.210026,38.494231],[-79.312276,38.411876],[-79.689544,38.442511],[-79.921026,38.179954],[-80.002507,37.992767],[-80.296138,37.691783],[-80.314806,37.500943],[-80.511391,37.481672],[-80.947896,37.295872],[-81.225104,37.234874],[-81.362156,37.337687],[-81.678603,37.202467],[-81.925643,37.357316],[-81.968297,37.537798]]]},"properties":{"geo_id":"0400000US54","fips_state":"54","name":"West Virginia","lsad":"","census_area":24038.21,"iso_3166_2":"WV","census":1852994,"pop_estimataes_base":1853033,"pop_2010":1854176,"pop_2011":1854982,"pop_2012":1856313,"pop_2013":1853595,"pop_2014":1850326,"rmapshaperid":19}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-87.800477,42.49192],[-89.250759,42.497994],[-90.640927,42.508302],[-90.720209,42.640758],[-91.053733,42.738238],[-91.178251,43.124982],[-91.057918,43.255366],[-91.217706,43.50055],[-91.262436,43.792166],[-91.432522,43.996827],[-91.875158,44.200575],[-91.972493,44.36676],[-92.549685,44.576],[-92.802402,44.745167],[-92.750645,44.937299],[-92.760615,45.278827],[-92.664102,45.393309],[-92.883749,45.575483],[-92.869193,45.717568],[-92.656125,45.924442],[-92.294033,46.074377],[-92.292192,46.663242],[-92.01529,46.706469],[-91.820027,46.690176],[-90.837716,46.957438],[-90.885021,46.756341],[-90.755289,46.646323],[-90.418136,46.566094],[-90.120489,46.336852],[-89.125136,46.144531],[-88.815629,46.02232],[-88.175532,45.944897],[-87.807144,45.708014],[-87.792769,45.499967],[-87.888052,45.354697],[-87.590208,45.095264],[-87.819525,44.951109],[-87.983494,44.720196],[-87.765774,44.642023],[-87.610063,44.838384],[-87.189407,44.968632],[-87.483696,44.511354],[-87.51966,44.17987],[-87.646583,44.104694],[-87.736178,43.880421],[-87.706204,43.679542],[-87.911787,43.250406],[-87.887703,43.000552],[-87.766675,42.784896],[-87.800477,42.49192]]]},"properties":{"geo_id":"0400000US55","fips_state":"55","name":"Wisconsin","lsad":"","census_area":54157.805,"iso_3166_2":"WI","census":5686986,"pop_estimataes_base":5687289,"pop_2010":5689268,"pop_2011":5708785,"pop_2012":5724888,"pop_2013":5742953,"pop_2014":5757564,"rmapshaperid":20}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-104.053127,43.000585],[-104.053026,41.885464],[-104.053249,41.001406],[-105.730421,40.996886],[-107.317794,41.002957],[-109.050076,41.000659],[-111.046723,40.997959],[-111.046689,42.001567],[-111.043959,42.96445],[-111.048974,44.474072],[-111.044275,45.001345],[-110.705272,44.992324],[-108.249345,44.999458],[-106.888773,44.995885],[-105.928184,44.993647],[-104.057698,44.997431],[-104.055133,43.747105],[-104.053127,43.000585]]]},"properties":{"geo_id":"0400000US56","fips_state":"56","name":"Wyoming","lsad":"","census_area":97093.141,"iso_3166_2":"WY","census":563626,"pop_estimataes_base":563767,"pop_2010":564358,"pop_2011":567631,"pop_2012":576893,"pop_2013":583223,"pop_2014":584153,"rmapshaperid":21}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-85.605165,34.984678],[-85.361844,33.773951],[-85.184131,32.870525],[-85.001324,32.512973],[-85.047865,32.142033],[-85.132931,31.88826],[-85.041305,31.540987],[-85.107516,31.186451],[-85.002368,31.000682],[-86.056213,30.993133],[-87.598928,30.997457],[-87.634938,30.865886],[-87.407118,30.671796],[-87.419177,30.410198],[-87.518324,30.280435],[-87.656888,30.249709],[-88.100874,30.50975],[-88.107274,30.377246],[-88.395023,30.369425],[-88.471106,31.850949],[-88.340432,32.991199],[-88.24839,33.744908],[-88.097888,34.892202],[-88.200064,34.995634],[-86.862147,34.991956],[-85.605165,34.984678]]]},"properties":{"geo_id":"0400000US01","fips_state":"01","name":"Alabama","lsad":"","census_area":50645.326,"iso_3166_2":"AL","census":4779736,"pop_estimataes_base":4780127,"pop_2010":4785822,"pop_2011":4801695,"pop_2012":4817484,"pop_2013":4833996,"pop_2014":4849377,"rmapshaperid":22}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-81.444124,30.709714],[-81.385505,30.273841],[-81.256711,29.784693],[-80.966176,29.14796],[-80.574868,28.585166],[-80.604214,28.257733],[-80.566432,28.09563],[-80.383695,27.740045],[-80.093909,27.018587],[-80.031362,26.796339],[-80.127987,25.772245],[-80.244528,25.717089],[-80.339421,25.499427],[-80.335269,25.338701],[-80.495341,25.199463],[-80.8464,25.17706],[-81.079859,25.118797],[-81.117265,25.354953],[-81.240677,25.613629],[-81.424295,25.867737],[-81.644553,25.897953],[-81.801663,26.088227],[-81.91171,26.427158],[-82.269499,26.784674],[-82.569248,27.298588],[-82.691004,27.444331],[-82.393383,27.837519],[-82.586519,27.816703],[-82.713629,27.698661],[-82.828561,27.822254],[-82.762643,28.219013],[-82.674787,28.441956],[-82.639898,28.876224],[-82.827073,29.158425],[-83.169576,29.290355],[-83.218075,29.420492],[-83.400252,29.517242],[-83.412768,29.668485],[-83.63798,29.886073],[-84.024274,30.103271],[-84.358923,30.058224],[-84.333746,29.923721],[-84.535873,29.910092],[-84.824197,29.758288],[-85.259719,29.681296],[-85.405052,29.938487],[-85.878138,30.215619],[-86.2987,30.363049],[-86.632953,30.396299],[-87.518324,30.280435],[-87.419177,30.410198],[-87.407118,30.671796],[-87.634938,30.865886],[-87.598928,30.997457],[-86.056213,30.993133],[-85.002368,31.000682],[-84.864693,30.711542],[-83.390062,30.639333],[-82.214385,30.566958],[-82.165192,30.358035],[-82.050069,30.362338],[-82.023213,30.781987],[-81.444124,30.709714]]]},"properties":{"geo_id":"0400000US12","fips_state":"12","name":"Florida","lsad":"","census_area":53624.759,"iso_3166_2":"FL","census":18801310,"pop_estimataes_base":18804623,"pop_2010":18852220,"pop_2011":19107900,"pop_2012":19355257,"pop_2013":19600311,"pop_2014":19893297,"rmapshaperid":23}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-111.048974,44.474072],[-111.043959,42.96445],[-111.046689,42.001567],[-112.163956,41.996708],[-114.041723,41.99372],[-115.038256,41.996025],[-117.026222,42.000252],[-117.026634,43.808104],[-116.902752,44.179467],[-117.170342,44.25889],[-117.214889,44.466901],[-117.044217,44.74514],[-116.931499,44.792281],[-116.673793,45.321511],[-116.463635,45.602785],[-116.535698,45.734231],[-116.789099,45.847749],[-116.915989,45.995413],[-117.047469,46.342884],[-117.041401,48.0855],[-117.032351,48.999188],[-116.049193,49.000912],[-116.048421,47.97682],[-115.729123,47.703102],[-115.729861,47.447287],[-115.52369,47.298919],[-115.320184,47.255717],[-114.936015,46.899761],[-114.592264,46.632861],[-114.337942,46.641205],[-114.48312,46.129147],[-114.39376,45.89402],[-114.514596,45.840785],[-114.561773,45.565109],[-114.309613,45.469432],[-113.93422,45.682232],[-113.813933,45.600559],[-113.738729,45.329741],[-113.449349,45.045745],[-113.498745,44.942314],[-113.353631,44.791395],[-113.134617,44.763149],[-113.003544,44.450814],[-112.71911,44.504344],[-112.38708,44.460476],[-112.258297,44.564334],[-111.806528,44.515459],[-111.601249,44.55421],[-111.489008,44.705553],[-111.323669,44.724474],[-111.048974,44.474072]]]},"properties":{"geo_id":"0400000US16","fips_state":"16","name":"Idaho","lsad":"","census_area":82643.117,"iso_3166_2":"ID","census":1567582,"pop_estimataes_base":1567652,"pop_2010":1570639,"pop_2011":1583780,"pop_2012":1595590,"pop_2013":1612843,"pop_2014":1634464,"rmapshaperid":24}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-102.04224,36.993083],[-102.045263,38.505395],[-102.051744,40.003078],[-100.468773,40.001724],[-98.934792,40.002205],[-97.049663,40.001323],[-95.30829,39.999998],[-94.895268,39.76321],[-95.102888,39.533347],[-94.752338,39.173203],[-94.607354,39.113444],[-94.612658,38.217649],[-94.61808,36.998135],[-96.00081,36.99886],[-97.030082,36.998929],[-98.354073,36.997961],[-99.456203,36.999471],[-100.945566,36.998152],[-102.04224,36.993083]]]},"properties":{"geo_id":"0400000US20","fips_state":"20","name":"Kansas","lsad":"","census_area":81758.717,"iso_3166_2":"KS","census":2853118,"pop_estimataes_base":2853132,"pop_2010":2858949,"pop_2011":2869965,"pop_2012":2885966,"pop_2013":2895801,"pop_2014":2904021,"rmapshaperid":25}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-77.1302,38.635017],[-77.038598,38.791513],[-77.1199,38.934311],[-77.519929,39.120925],[-77.458884,39.219826],[-77.719029,39.321125],[-77.902649,39.587796],[-78.191107,39.690262],[-78.43025,39.62329],[-78.468639,39.516789],[-78.760196,39.582154],[-78.968996,39.441543],[-79.08445,39.471356],[-79.486873,39.205961],[-79.476662,39.721078],[-78.380599,39.722554],[-77.047104,39.72],[-75.788359,39.721811],[-75.693521,38.460128],[-75.048939,38.451263],[-75.242296,38.027206],[-75.669711,37.950796],[-76.111296,38.286946],[-76.258189,38.318373],[-76.33636,38.492235],[-76.147158,38.63684],[-76.334619,38.772911],[-76.164004,38.99953],[-76.278527,39.145764],[-76.519442,38.863135],[-76.515706,38.528988],[-76.388348,38.387781],[-76.361237,38.059542],[-76.590637,38.214212],[-76.920932,38.291568],[-77.016371,38.445572],[-77.27422,38.48177],[-77.1302,38.635017]]]},"properties":{"geo_id":"0400000US24","fips_state":"24","name":"Maryland","lsad":"","census_area":9707.241,"iso_3166_2":"MD","census":5773552,"pop_estimataes_base":5773785,"pop_2010":5788101,"pop_2011":5843833,"pop_2012":5891819,"pop_2013":5938737,"pop_2014":5976407,"rmapshaperid":26}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-74.694914,41.357423],[-73.90268,40.997297],[-74.024543,40.709436],[-74.181083,40.646484],[-74.261889,40.464706],[-73.998505,40.410911],[-73.977442,40.299373],[-74.096906,39.76303],[-74.412692,39.360816],[-74.614481,39.244659],[-74.792723,38.991991],[-74.887167,39.158825],[-75.177506,39.242746],[-75.536431,39.460559],[-75.55587,39.605824],[-75.559446,39.629812],[-75.509742,39.686113],[-75.415041,39.801786],[-75.184952,39.881615],[-74.974713,40.048711],[-74.740605,40.13521],[-75.190161,40.589321],[-75.196533,40.751631],[-75.052538,40.872051],[-75.135526,40.973807],[-74.694914,41.357423]]]},"properties":{"geo_id":"0400000US34","fips_state":"34","name":"New Jersey","lsad":"","census_area":7354.22,"iso_3166_2":"NJ","census":8791894,"pop_estimataes_base":8791936,"pop_2010":8803580,"pop_2011":8842614,"pop_2012":8876000,"pop_2013":8911502,"pop_2014":8938175,"rmapshaperid":27}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-75.867044,36.550754],[-75.923511,36.367796],[-75.867385,36.151182],[-76.410878,36.078034],[-76.362966,35.942197],[-76.062071,35.993004],[-75.782498,35.935615],[-75.729802,35.625985],[-75.895045,35.573152],[-76.14291,35.32866],[-76.467776,35.261213],[-76.60042,35.067867],[-76.277698,34.940014],[-76.549343,34.645585],[-76.770044,34.696899],[-77.209161,34.605032],[-77.582323,34.400506],[-77.829209,34.162618],[-77.946568,33.912261],[-78.383964,33.901946],[-78.541087,33.851112],[-79.688088,34.804897],[-80.777712,34.819697],[-80.782042,34.935782],[-81.043407,35.14839],[-82.384029,35.210542],[-83.108535,35.000771],[-84.321869,34.988408],[-84.29024,35.225572],[-84.02351,35.295783],[-84.00225,35.422548],[-83.756917,35.563604],[-83.498335,35.562981],[-83.100233,35.774745],[-82.995803,35.773128],[-82.754465,36.004304],[-82.462958,36.007309],[-82.375558,36.105609],[-82.02664,36.130222],[-81.908137,36.302013],[-81.725938,36.340364],[-81.677535,36.588117],[-80.228263,36.543867],[-78.529722,36.540981],[-76.916048,36.543815],[-75.867044,36.550754]]]},"properties":{"geo_id":"0400000US37","fips_state":"37","name":"North Carolina","lsad":"","census_area":48617.905,"iso_3166_2":"NC","census":9535483,"pop_estimataes_base":9535691,"pop_2010":9559488,"pop_2011":9651502,"pop_2012":9748181,"pop_2013":9848917,"pop_2014":9943964,"rmapshaperid":28}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-78.541087,33.851112],[-78.714116,33.800138],[-78.938076,33.639826],[-79.147496,33.378243],[-79.18787,33.173712],[-79.483499,33.001265],[-79.99175,32.616389],[-80.332438,32.478104],[-80.466342,32.31917],[-80.658634,32.248638],[-80.885517,32.0346],[-81.117234,32.117605],[-81.199029,32.467286],[-81.389338,32.595436],[-81.51169,33.024506],[-81.852136,33.247544],[-82.046335,33.56383],[-82.247472,33.752591],[-82.564582,33.95581],[-82.717507,34.150504],[-82.882864,34.479003],[-83.006848,34.474376],[-83.338194,34.687924],[-83.32406,34.788691],[-83.108535,35.000771],[-82.384029,35.210542],[-81.043407,35.14839],[-80.782042,34.935782],[-80.777712,34.819697],[-79.688088,34.804897],[-78.541087,33.851112]]]},"properties":{"geo_id":"0400000US45","fips_state":"45","name":"South Carolina","lsad":"","census_area":30060.696,"iso_3166_2":"SC","census":4625364,"pop_estimataes_base":4625401,"pop_2010":4636290,"pop_2011":4673054,"pop_2012":4722621,"pop_2013":4771929,"pop_2014":4832482,"rmapshaperid":29}},
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[-122.800217,48.60169],[-122.874135,48.418196],[-123.163234,48.529544],[-122.918252,48.713505],[-122.800217,48.60169]]],[[[-117.032351,48.999188],[-117.041401,48.0855],[-117.047469,46.342884],[-116.915989,45.995413],[-118.987129,45.999855],[-119.12612,45.932859],[-119.487829,45.906307],[-120.001148,45.811902],[-120.210754,45.725951],[-120.634968,45.745847],[-121.195233,45.629513],[-121.312198,45.699925],[-121.811304,45.706761],[-122.248993,45.547745],[-122.76381,45.657138],[-122.813998,45.960984],[-123.115904,46.185268],[-123.280166,46.144843],[-123.547659,46.259109],[-123.909306,46.245491],[-124.064624,46.326899],[-123.894254,46.537028],[-124.089286,46.867716],[-123.991612,46.980215],[-124.176745,47.092999],[-124.319379,47.355559],[-124.430546,47.746249],[-124.625512,47.887963],[-124.704153,48.184422],[-124.597331,48.381882],[-123.981032,48.164761],[-123.248615,48.115745],[-123.1644,48.165894],[-122.392044,47.807718],[-122.231761,48.029876],[-122.365078,48.125822],[-122.408718,48.326413],[-122.581607,48.429244],[-122.425271,48.599522],[-122.535803,48.776128],[-122.785659,48.885066],[-122.75802,49.002357],[-121.751252,48.997399],[-119.702016,49.000269],[-118.196891,49.000094],[-117.032351,48.999188]]]]},"properties":{"geo_id":"0400000US53","fips_state":"53","name":"Washington","lsad":"","census_area":66455.521,"iso_3166_2":"WA","census":6724540,"pop_estimataes_base":6724543,"pop_2010":6741911,"pop_2011":6822112,"pop_2012":6896325,"pop_2013":6973742,"pop_2014":7061530,"rmapshaperid":30}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-72.458519,42.726853],[-73.264957,42.74594],[-73.242042,43.534925],[-73.421606,43.646577],[-73.350431,43.771438],[-73.43688,44.042578],[-73.324681,44.243614],[-73.306707,44.500334],[-73.390231,44.618353],[-73.343124,45.01084],[-72.342453,45.005354],[-71.502487,45.013367],[-71.623924,44.755135],[-71.536251,44.587939],[-71.67995,44.427908],[-72.002314,44.324871],[-72.183743,43.806644],[-72.395825,43.52056],[-72.443762,43.006245],[-72.556214,42.86695],[-72.458519,42.726853]]]},"properties":{"geo_id":"0400000US50","fips_state":"50","name":"Vermont","lsad":"","census_area":9216.657,"iso_3166_2":"VT","census":625741,"pop_estimataes_base":625745,"pop_2010":625792,"pop_2011":626450,"pop_2012":626138,"pop_2013":626855,"pop_2014":626562,"rmapshaperid":31}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-111.046689,42.001567],[-111.046723,40.997959],[-109.050076,41.000659],[-109.050873,40.058915],[-109.051516,39.124982],[-109.042062,38.15549],[-109.045223,36.999084],[-110.000677,36.997968],[-111.189888,37.000959],[-112.966471,37.000219],[-114.0506,37.000396],[-114.049893,38.677365],[-114.046555,40.116931],[-114.042145,40.999926],[-114.041723,41.99372],[-112.163956,41.996708],[-111.046689,42.001567]]]},"properties":{"geo_id":"0400000US49","fips_state":"49","name":"Utah","lsad":"","census_area":82169.62,"iso_3166_2":"UT","census":2763885,"pop_estimataes_base":2763885,"pop_2010":2774346,"pop_2011":2815324,"pop_2012":2855194,"pop_2013":2902787,"pop_2014":2942902,"rmapshaperid":32}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-90.640927,42.508302],[-90.356964,42.205445],[-90.162225,42.11488],[-90.181973,41.80707],[-90.461432,41.523533],[-91.047819,41.4109],[-91.114186,41.250029],[-90.946627,41.096632],[-90.952233,40.954047],[-91.122421,40.670675],[-91.359873,40.601805],[-91.419422,40.378264],[-91.729115,40.61364],[-93.260612,40.580797],[-94.632035,40.571186],[-95.765645,40.585208],[-95.883178,40.717579],[-95.821193,40.876682],[-95.852788,41.165398],[-96.089714,41.531778],[-96.064537,41.793002],[-96.129505,41.971673],[-96.272877,42.047238],[-96.443408,42.489495],[-96.632142,42.770863],[-96.436589,43.120842],[-96.557126,43.224192],[-96.453049,43.500415],[-95.514774,43.499865],[-93.795793,43.49952],[-92.790317,43.499567],[-91.217706,43.50055],[-91.057918,43.255366],[-91.178251,43.124982],[-91.053733,42.738238],[-90.720209,42.640758],[-90.640927,42.508302]]]},"properties":{"geo_id":"0400000US19","fips_state":"19","name":"Iowa","lsad":"","census_area":55857.13,"iso_3166_2":"IA","census":3046355,"pop_estimataes_base":3046869,"pop_2010":3050295,"pop_2011":3064904,"pop_2012":3075935,"pop_2013":3092341,"pop_2014":3107126,"rmapshaperid":33}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-81.968297,37.537798],[-82.350948,37.267077],[-82.565375,37.196092],[-83.199698,36.737487],[-83.675413,36.600814],[-83.690714,36.582581],[-85.471338,36.61638],[-86.473497,36.651671],[-87.853204,36.633247],[-88.070532,36.678118],[-88.053205,36.497129],[-89.417293,36.499033],[-89.227319,36.569375],[-89.132685,36.9822],[-89.086526,37.165602],[-88.916934,37.224291],[-88.458948,37.073796],[-88.476592,37.386875],[-88.083395,37.473683],[-88.160187,37.657592],[-88.02803,37.799224],[-87.940005,37.875044],[-87.380247,37.935596],[-87.111133,37.782512],[-87.033444,37.906593],[-86.794985,37.988982],[-86.604624,37.858272],[-86.51176,38.044448],[-86.309727,38.144393],[-86.172186,38.00992],[-85.951467,38.005608],[-85.829364,38.276769],[-85.653641,38.327108],[-85.433136,38.523914],[-85.456978,38.689135],[-85.172528,38.688082],[-84.785799,38.869496],[-84.820157,39.10548],[-84.432841,39.094261],[-84.205592,38.802588],[-83.85333,38.752572],[-83.649737,38.632753],[-83.512571,38.701716],[-83.2821,38.602987],[-82.894193,38.756576],[-82.839538,38.586159],[-82.593673,38.421809],[-82.644739,38.165487],[-82.464987,37.976859],[-82.297011,37.687273],[-81.968297,37.537798]]]},"properties":{"geo_id":"0400000US21","fips_state":"21","name":"Kentucky","lsad":"","census_area":39486.338,"iso_3166_2":"KY","census":4339367,"pop_estimataes_base":4339349,"pop_2010":4349838,"pop_2011":4370038,"pop_2012":4383465,"pop_2013":4399583,"pop_2014":4413457,"rmapshaperid":34}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-70.703936,43.059621],[-70.967229,43.343777],[-71.037518,44.755607],[-71.084334,45.305293],[-70.798483,45.42474],[-70.262655,45.887853],[-70.310609,46.064544],[-70.207415,46.331316],[-70.056433,46.41659],[-69.997086,46.69523],[-69.22442,47.459686],[-69.055465,47.432274],[-69.050334,47.256621],[-68.900985,47.178519],[-68.361559,47.355605],[-68.240168,47.354217],[-67.789461,47.062544],[-67.781095,45.943032],[-67.817892,45.693705],[-67.64581,45.613597],[-67.422153,45.379661],[-67.489333,45.281282],[-67.112414,45.112323],[-66.979708,44.80736],[-67.189427,44.645533],[-67.568159,44.531117],[-67.856684,44.523934],[-68.049334,44.33073],[-68.401268,44.252244],[-68.958889,44.314353],[-69.259838,43.921427],[-69.331411,43.974311],[-69.653337,43.79103],[-70.053594,43.828417],[-70.251812,43.683251],[-70.196911,43.565146],[-70.535244,43.336771],[-70.703936,43.059621]]]},"properties":{"geo_id":"0400000US23","fips_state":"23","name":"Maine","lsad":"","census_area":30842.923,"iso_3166_2":"ME","census":1328361,"pop_estimataes_base":1328361,"pop_2010":1327361,"pop_2011":1327930,"pop_2012":1328592,"pop_2013":1328702,"pop_2014":1330089,"rmapshaperid":35}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-73.487314,42.049638],[-73.508142,42.086257],[-73.264957,42.74594],[-72.458519,42.726853],[-71.294205,42.69699],[-71.149703,42.815489],[-70.817296,42.87229],[-70.654727,42.582234],[-70.871382,42.546404],[-70.98909,42.267449],[-70.770964,42.249197],[-70.471552,41.761563],[-70.259205,41.713954],[-69.935952,41.809422],[-69.928261,41.6917],[-70.360352,41.631069],[-70.658659,41.543385],[-70.718739,41.73574],[-70.931545,41.540169],[-71.12057,41.497448],[-71.19564,41.67509],[-71.224798,41.710498],[-71.327896,41.780501],[-71.381401,42.018798],[-71.799242,42.008065],[-73.487314,42.049638]]]},"properties":{"geo_id":"0400000US25","fips_state":"25","name":"Massachusetts","lsad":"","census_area":7800.058,"iso_3166_2":"MA","census":6547629,"pop_estimataes_base":6547817,"pop_2010":6564073,"pop_2011":6612270,"pop_2012":6655829,"pop_2013":6708874,"pop_2014":6745408,"rmapshaperid":36}},
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[-83.453832,41.732647],[-84.806082,41.696089],[-84.818873,41.760059],[-86.824828,41.76024],[-86.619442,41.893827],[-86.356218,42.254166],[-86.206834,42.719424],[-86.254646,43.083409],[-86.538497,43.617501],[-86.431043,43.815975],[-86.514702,44.058119],[-86.26871,44.345324],[-86.232482,44.70605],[-86.066745,44.905685],[-85.807403,44.949814],[-85.527216,44.748235],[-85.3958,44.931018],[-85.371593,45.270834],[-85.032813,45.361251],[-85.119737,45.569026],[-84.772765,45.789301],[-84.46168,45.652404],[-84.215268,45.634767],[-84.109238,45.505171],[-83.422389,45.290775],[-83.443718,44.952247],[-83.273393,44.713901],[-83.332533,44.340464],[-83.549096,44.227282],[-83.58409,44.056748],[-83.916815,43.89905],[-83.909479,43.672622],[-83.669795,43.59079],[-83.26153,43.973525],[-82.915976,44.070503],[-82.738992,43.989506],[-82.633641,43.831224],[-82.523086,43.225361],[-82.415937,43.005555],[-82.523337,42.607486],[-82.797318,42.654032],[-82.92397,42.352068],[-83.128022,42.238839],[-83.133511,42.088143],[-83.453832,41.732647]]],[[[-90.418136,46.566094],[-90.028392,46.67439],[-89.848652,46.795711],[-89.437047,46.839512],[-88.573997,47.245989],[-88.18182,47.457657],[-87.815371,47.38479],[-88.212361,47.209423],[-88.443901,46.972251],[-87.900339,46.909686],[-87.6333,46.812107],[-87.38929,46.524472],[-87.017136,46.53355],[-86.875151,46.43728],[-86.495054,46.524874],[-86.138295,46.672935],[-85.482096,46.680432],[-85.25686,46.75338],[-85.027513,46.697451],[-85.056133,46.52652],[-84.800101,46.446219],[-84.111225,46.504119],[-84.071741,46.092441],[-83.900535,45.998918],[-83.581315,46.089613],[-83.510623,45.929324],[-84.111174,45.978675],[-84.376431,45.931963],[-84.656567,46.052654],[-84.747033,45.835621],[-85.003597,46.00613],[-85.52157,46.091257],[-85.663966,45.967013],[-86.196618,45.963185],[-86.363808,45.790057],[-86.78208,45.860195],[-86.838746,45.722307],[-87.172241,45.661788],[-87.590208,45.095264],[-87.888052,45.354697],[-87.792769,45.499967],[-87.807144,45.708014],[-88.175532,45.944897],[-88.815629,46.02232],[-89.125136,46.144531],[-90.120489,46.336852],[-90.418136,46.566094]]]]},"properties":{"geo_id":"0400000US26","fips_state":"26","name":"Michigan","lsad":"","census_area":56538.901,"iso_3166_2":"MI","census":9883640,"pop_estimataes_base":9884133,"pop_2010":9876498,"pop_2011":9875736,"pop_2012":9884781,"pop_2013":9898193,"pop_2014":9909877,"rmapshaperid":37}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-89.733095,36.000608],[-90.368718,35.995812],[-90.06398,36.303038],[-90.152481,36.497952],[-91.404915,36.49712],[-93.426989,36.498585],[-94.617919,36.499414],[-94.61808,36.998135],[-94.612658,38.217649],[-94.607354,39.113444],[-94.752338,39.173203],[-95.102888,39.533347],[-94.895268,39.76321],[-95.30829,39.999998],[-95.622684,40.342323],[-95.765645,40.585208],[-94.632035,40.571186],[-93.260612,40.580797],[-91.729115,40.61364],[-91.419422,40.378264],[-91.512974,40.181062],[-91.367753,39.729029],[-91.042351,39.452062],[-90.726981,39.251173],[-90.663372,38.928042],[-90.472122,38.958838],[-90.113327,38.849306],[-90.17801,38.63375],[-90.370819,38.333554],[-90.243116,38.112669],[-89.844786,37.905572],[-89.515436,37.67137],[-89.43604,37.344441],[-89.517032,37.28192],[-89.378277,37.039605],[-89.132685,36.9822],[-89.227319,36.569375],[-89.417293,36.499033],[-89.485106,36.497692],[-89.5391,36.498201],[-89.509558,36.375065],[-89.594,36.12719],[-89.733095,36.000608]]]},"properties":{"geo_id":"0400000US29","fips_state":"29","name":"Missouri","lsad":"","census_area":68741.522,"iso_3166_2":"MO","census":5988927,"pop_estimataes_base":5988923,"pop_2010":5996085,"pop_2011":6010544,"pop_2012":6025281,"pop_2013":6044917,"pop_2014":6063589,"rmapshaperid":38}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-104.053127,43.000585],[-103.132955,43.000784],[-101.625424,42.996238],[-99.471353,42.997967],[-98.49855,42.99856],[-98.467356,42.947556],[-97.950147,42.769619],[-97.828496,42.868797],[-97.257089,42.853854],[-96.724033,42.665971],[-96.625958,42.513576],[-96.443408,42.489495],[-96.272877,42.047238],[-96.129505,41.971673],[-96.064537,41.793002],[-96.089714,41.531778],[-95.852788,41.165398],[-95.821193,40.876682],[-95.883178,40.717579],[-95.765645,40.585208],[-95.622684,40.342323],[-95.30829,39.999998],[-97.049663,40.001323],[-98.934792,40.002205],[-100.468773,40.001724],[-102.051744,40.003078],[-102.051614,41.002377],[-104.053249,41.001406],[-104.053026,41.885464],[-104.053127,43.000585]]]},"properties":{"geo_id":"0400000US31","fips_state":"31","name":"Nebraska","lsad":"","census_area":76824.171,"iso_3166_2":"NE","census":1826341,"pop_estimataes_base":1826341,"pop_2010":1829865,"pop_2011":1842232,"pop_2012":1855487,"pop_2013":1868969,"pop_2014":1881503,"rmapshaperid":39}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-114.0506,37.000396],[-114.046838,36.194069],[-114.15413,36.023862],[-114.381446,36.141665],[-114.755618,36.087166],[-114.677643,35.489742],[-114.572747,35.138725],[-114.633013,35.002085],[-116.097216,36.158346],[-117.000895,36.847694],[-118.428581,37.895613],[-120.001014,38.999574],[-119.997291,40.071803],[-119.999866,41.183974],[-119.999168,41.99454],[-118.777228,41.992671],[-117.026222,42.000252],[-115.038256,41.996025],[-114.041723,41.99372],[-114.042145,40.999926],[-114.046555,40.116931],[-114.049893,38.677365],[-114.0506,37.000396]]]},"properties":{"geo_id":"0400000US32","fips_state":"32","name":"Nevada","lsad":"","census_area":109781.18,"iso_3166_2":"NV","census":2700551,"pop_estimataes_base":2700692,"pop_2010":2703493,"pop_2011":2718586,"pop_2012":2755245,"pop_2013":2791494,"pop_2014":2839099,"rmapshaperid":40}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-70.703936,43.059621],[-70.817296,42.87229],[-71.149703,42.815489],[-71.294205,42.69699],[-72.458519,42.726853],[-72.556214,42.86695],[-72.443762,43.006245],[-72.395825,43.52056],[-72.183743,43.806644],[-72.002314,44.324871],[-71.67995,44.427908],[-71.536251,44.587939],[-71.623924,44.755135],[-71.502487,45.013367],[-71.401182,45.242544],[-71.084334,45.305293],[-71.037518,44.755607],[-70.967229,43.343777],[-70.703936,43.059621]]]},"properties":{"geo_id":"0400000US33","fips_state":"33","name":"New Hampshire","lsad":"","census_area":8952.651,"iso_3166_2":"NH","census":1316470,"pop_estimataes_base":1316466,"pop_2010":1316517,"pop_2011":1318109,"pop_2012":1321297,"pop_2013":1322616,"pop_2014":1326813,"rmapshaperid":41}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-73.264957,42.74594],[-73.508142,42.086257],[-73.487314,42.049638],[-73.550961,41.295422],[-73.727775,41.100696],[-73.657336,40.985171],[-73.229285,40.905121],[-73.140785,40.966178],[-72.585327,40.997587],[-72.356087,41.133635],[-72.095456,40.991349],[-72.39585,40.86666],[-73.20844,40.630884],[-73.934512,40.545175],[-74.024543,40.709436],[-73.90268,40.997297],[-74.694914,41.357423],[-75.04049,41.569688],[-75.114399,41.843583],[-75.359579,41.999445],[-76.343722,41.998346],[-77.83203,41.998524],[-79.761374,41.999067],[-79.761951,42.26986],[-79.148723,42.553672],[-78.853455,42.783958],[-79.019964,42.994756],[-79.070469,43.262454],[-78.488857,43.374763],[-77.976438,43.369159],[-77.577223,43.243263],[-76.952174,43.270692],[-76.69836,43.344436],[-76.410636,43.523159],[-76.203473,43.574978],[-76.229268,43.804135],[-76.127285,43.897889],[-76.360306,44.070907],[-76.312647,44.199044],[-75.912985,44.368084],[-75.765495,44.516285],[-75.216486,44.877478],[-74.826578,45.01585],[-74.146814,44.9915],[-73.343124,45.01084],[-73.390231,44.618353],[-73.306707,44.500334],[-73.324681,44.243614],[-73.43688,44.042578],[-73.350431,43.771438],[-73.421606,43.646577],[-73.242042,43.534925],[-73.264957,42.74594]]]},"properties":{"geo_id":"0400000US36","fips_state":"36","name":"New York","lsad":"","census_area":47126.399,"iso_3166_2":"NY","census":19378102,"pop_estimataes_base":19378112,"pop_2010":19400867,"pop_2011":19521745,"pop_2012":19607140,"pop_2013":19695680,"pop_2014":19746227,"rmapshaperid":42}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-82.593673,38.421809],[-82.839538,38.586159],[-82.894193,38.756576],[-83.2821,38.602987],[-83.512571,38.701716],[-83.649737,38.632753],[-83.85333,38.752572],[-84.205592,38.802588],[-84.432841,39.094261],[-84.820157,39.10548],[-84.803918,40.310094],[-84.806082,41.696089],[-83.453832,41.732647],[-82.934369,41.514353],[-82.721914,41.516677],[-82.481214,41.381342],[-82.011966,41.515639],[-81.744755,41.48715],[-81.442645,41.673255],[-81.01049,41.853962],[-80.519461,41.977513],[-80.518991,40.638801],[-80.599895,40.317669],[-80.806018,39.91713],[-80.829764,39.711839],[-81.215617,39.388602],[-81.467744,39.403774],[-81.749853,39.186489],[-81.759995,38.925828],[-82.002261,39.027878],[-82.215759,38.797462],[-82.172066,38.625984],[-82.34064,38.440948],[-82.593673,38.421809]]]},"properties":{"geo_id":"0400000US39","fips_state":"39","name":"Ohio","lsad":"","census_area":40860.694,"iso_3166_2":"OH","census":11536504,"pop_estimataes_base":11536725,"pop_2010":11540070,"pop_2011":11544757,"pop_2012":11550901,"pop_2013":11572005,"pop_2014":11594163,"rmapshaperid":43}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-116.915989,45.995413],[-116.789099,45.847749],[-116.535698,45.734231],[-116.463635,45.602785],[-116.673793,45.321511],[-116.931499,44.792281],[-117.044217,44.74514],[-117.214889,44.466901],[-117.170342,44.25889],[-116.902752,44.179467],[-117.026634,43.808104],[-117.026222,42.000252],[-118.777228,41.992671],[-119.999168,41.99454],[-121.035195,41.993323],[-122.378193,42.009518],[-124.211605,41.99846],[-124.356229,42.114952],[-124.435105,42.440163],[-124.389977,42.574758],[-124.552441,42.840568],[-124.233534,43.55713],[-124.168392,43.808903],[-123.975425,45.145476],[-123.939005,45.661923],[-123.96763,45.907807],[-123.854801,46.157342],[-123.547659,46.259109],[-123.280166,46.144843],[-123.115904,46.185268],[-122.813998,45.960984],[-122.76381,45.657138],[-122.248993,45.547745],[-121.811304,45.706761],[-121.312198,45.699925],[-121.195233,45.629513],[-120.634968,45.745847],[-120.210754,45.725951],[-120.001148,45.811902],[-119.487829,45.906307],[-119.12612,45.932859],[-118.987129,45.999855],[-116.915989,45.995413]]]},"properties":{"geo_id":"0400000US41","fips_state":"41","name":"Oregon","lsad":"","census_area":95988.013,"iso_3166_2":"OR","census":3831074,"pop_estimataes_base":3831073,"pop_2010":3837083,"pop_2011":3867644,"pop_2012":3898684,"pop_2013":3928068,"pop_2014":3970239,"rmapshaperid":44}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-71.85957,41.322399],[-71.797683,41.416709],[-71.799242,42.008065],[-71.381401,42.018798],[-71.327896,41.780501],[-71.224798,41.710498],[-71.409302,41.662643],[-71.483295,41.371722],[-71.85957,41.322399]]]},"properties":{"geo_id":"0400000US44","fips_state":"44","name":"Rhode Island","lsad":"","census_area":1033.814,"iso_3166_2":"RI","census":1052567,"pop_estimataes_base":1052931,"pop_2010":1053078,"pop_2011":1052020,"pop_2012":1052637,"pop_2013":1053354,"pop_2014":1055173,"rmapshaperid":45}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-104.057698,44.997431],[-104.045443,45.94531],[-102.550947,45.945015],[-101.557276,45.9441],[-99.490254,45.940362],[-98.18563,45.936185],[-96.56328,45.935238],[-96.583085,45.820024],[-96.857751,45.605962],[-96.680454,45.410499],[-96.453067,45.298115],[-96.453049,43.500415],[-96.557126,43.224192],[-96.436589,43.120842],[-96.632142,42.770863],[-96.443408,42.489495],[-96.625958,42.513576],[-96.724033,42.665971],[-97.257089,42.853854],[-97.828496,42.868797],[-97.950147,42.769619],[-98.467356,42.947556],[-98.49855,42.99856],[-99.471353,42.997967],[-101.625424,42.996238],[-103.132955,43.000784],[-104.053127,43.000585],[-104.055133,43.747105],[-104.057698,44.997431]]]},"properties":{"geo_id":"0400000US46","fips_state":"46","name":"South Dakota","lsad":"","census_area":75811,"iso_3166_2":"SD","census":814180,"pop_estimataes_base":814191,"pop_2010":816192,"pop_2011":824171,"pop_2012":834504,"pop_2013":845510,"pop_2014":853175,"rmapshaperid":46}},
{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-94.485875,33.637867],[-94.355945,33.54318],[-94.04345,33.552253],[-94.042964,33.019219],[-94.04272,31.999265],[-93.840029,31.800596],[-93.834924,31.586211],[-93.531744,31.180817],[-93.530936,30.924534],[-93.727844,30.57407],[-93.757654,30.390423],[-93.712101,30.067346],[-93.890679,29.843159],[-93.837971,29.690619],[-94.132577,29.646217],[-94.594853,29.467903],[-94.740699,29.525858],[-94.695317,29.723052],[-95.005398,29.659366],[-94.909465,29.496838],[-94.893994,29.30817],[-95.026219,29.148064],[-95.353451,28.898145],[-95.812504,28.664942],[-96.198374,28.58698],[-96.473694,28.57324],[-96.403973,28.44245],[-96.672677,28.335579],[-97.04876,28.022092],[-97.253955,27.696696],[-97.404996,27.329977],[-97.478533,26.999186],[-97.563266,26.842188],[-97.471663,26.758727],[-97.411612,26.447275],[-97.270898,26.086459],[-97.172633,25.962883],[-97.408357,25.856459],[-97.671568,26.033955],[-98.241664,26.074544],[-98.438822,26.212022],[-98.705676,26.27748],[-98.807348,26.369421],[-99.047575,26.406922],[-99.167996,26.557799],[-99.242444,26.788262],[-99.446524,27.023008],[-99.441549,27.24992],[-99.537771,27.316073],[-99.480219,27.485796],[-99.876174,27.806276],[-100.088143,28.147503],[-100.291391,28.275398],[-100.386963,28.514023],[-100.640092,28.915833],[-100.674656,29.099777],[-101.060151,29.458661],[-101.235275,29.524854],[-101.403926,29.757587],[-102.116076,29.792527],[-102.323389,29.875193],[-102.689738,29.722349],[-102.895886,29.284778],[-103.163865,28.972099],[-103.383508,29.024112],[-103.792005,29.262695],[-104.025488,29.314404],[-104.235847,29.496744],[-104.515512,29.641493],[-104.679877,29.920946],[-104.687296,30.179464],[-104.859521,30.390413],[-104.929778,30.59924],[-105.211234,30.799609],[-105.394627,30.85892],[-106.00693,31.392826],[-106.218538,31.47972],[-106.381039,31.73211],[-106.528543,31.783907],[-106.599096,32.000731],[-105.429281,32.000577],[-104.531756,32.000117],[-103.064423,32.000518],[-103.064625,32.999899],[-103.043617,34.003633],[-103.042497,35.211862],[-103.041669,36.478514],[-103.002434,36.500397],[-101.085156,36.499244],[-100.000406,36.499702],[-100.000392,35.619115],[-100.000381,34.560509],[-99.69497,34.378333],[-99.58006,34.416653],[-99.211423,34.337897],[-99.19089,34.215251],[-98.858419,34.152732],[-98.364023,34.157109],[-98.16912,34.114171],[-97.977859,33.889929],[-97.834333,33.857671],[-97.65621,33.989488],[-97.372941,33.819454],[-97.226522,33.914642],[-97.092414,33.733214],[-96.88301,33.868019],[-96.67858,33.892786],[-96.36959,33.716809],[-96.14807,33.837799],[-95.82468,33.837726],[-95.599678,33.934247],[-95.287565,33.873617],[-95.067253,33.917351],[-94.8693,33.745871],[-94.485875,33.637867]]]},"properties":{"geo_id":"0400000US48","fips_state":"48","name":"Texas","lsad":"","census_area":261231.711,"iso_3166_2":"TX","census":25145561,"pop_estimataes_base":25146104,"pop_2010":25245717,"pop_2011":25657477,"pop_2012":26094422,"pop_2013":26505637,"pop_2014":26956958,"rmapshaperid":47}},
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[-114.8467411,24.7514688],[-114.9409584,24.5691363],[-115.202884,24.6897891],[-114.9544268,24.8536641],[-114.8467411,24.7514688]]],[[[-107.6948655,25.8030057],[-107.5733955,25.8331239],[-107.3252459,25.5495196],[-107.4647935,25.4973122],[-107.5939467,25.6005132],[-107.6948655,25.8030057]]],[[[-115.6556911,26.2130858],[-115.7693377,26.0890992],[-116.0240178,26.2557758],[-115.8992332,26.3811722],[-115.6556911,26.2130858]]],[[[-106.8643014,25.4022497],[-107.0822726,25.2096916],[-107.2731194,25.4434824],[-107.0776678,25.4957439],[-106.8643014,25.4022497]]],[[[-107.0510388,25.1725469],[-106.9402005,25.2155224],[-106.732568,25.1207991],[-106.4110976,24.8794745],[-106.5158231,24.6092604],[-106.7889841,24.784775],[-106.7314257,24.868742],[-107.0005866,24.9853435],[-107.0510388,25.1725469]]],[[[-107.8201906,25.5796124],[-107.5680358,25.5011738],[-107.787673,25.349245],[-108.0448483,25.4887737],[-108.0701064,25.6479403],[-107.9431651,25.7167717],[-107.8201906,25.5796124]]],[[[-107.252007,24.9840435],[-107.5564318,25.158928],[-107.5190183,25.3981557],[-107.3392495,25.1774266],[-107.252007,24.9840435]]],[[[-114.8232824,21.8637961],[-114.6873011,21.8404212],[-114.8322448,21.594465],[-114.9201597,21.7752456],[-114.8232824,21.8637961]]],[[[-111.6403406,24.153292],[-111.6764166,23.8176354],[-111.8319577,23.6593073],[-112.0439419,23.6670448],[-112.1237347,23.8943843],[-111.8976778,24.1606695],[-111.6403406,24.153292]]],[[[-107.8927317,25.7976348],[-108.0189495,25.7278984],[-108.1317469,25.5949046],[-108.4266846,25.6615771],[-108.5995016,25.7833289],[-109.1947258,25.86463],[-109.599485,25.8555842],[-109.8274768,25.8080661],[-110.0243417,25.6899022],[-110.4375217,25.7509039],[-110.8681025,25.8794823],[-111.0631627,25.7465724],[-110.9212334,25.3726698],[-111.1841079,25.3197116],[-111.4719336,24.8701705],[-111.6441258,24.7896376],[-111.7427409,25.0584471],[-111.6948727,25.2767533],[-111.7511487,25.5029485],[-111.5669565,25.7027486],[-111.663603,25.7774612],[-111.8929271,25.4539446],[-111.9437835,25.0734695],[-112.1939136,24.7444992],[-112.1863853,24.6171437],[-111.9604855,24.5726903],[-112.0698466,24.4246335],[-112.0848648,24.2343293],[-112.3870405,23.856568],[-112.4931674,23.661696],[-112.8554824,23.2535691],[-112.889493,23.0824194],[-112.9994933,22.9812756],[-113.2577114,22.8750299],[-113.3459238,22.7253025],[-113.6411949,22.6378302],[-113.6875203,22.4904089],[-113.9447186,22.3822866],[-114.0609747,22.2142638],[-114.3206506,22.3183406],[-113.9403374,22.4900756],[-113.7989572,22.7454464],[-113.5857951,22.9151207],[-113.3977675,22.9210637],[-113.3805431,23.0832398],[-113.0811331,23.3875973],[-112.8604495,23.8075203],[-112.8760418,24.2119015],[-112.8078373,24.3985684],[-113.2408438,24.1111469],[-113.3422565,24.2545253],[-113.5693463,24.3110544],[-113.8553301,24.0911047],[-113.9666295,24.4512392],[-113.9170466,24.5175491],[-114.0705806,24.7810517],[-114.2663723,24.6454545],[-114.5018299,24.7082114],[-114.7797148,24.9134789],[-114.7015235,25.01443],[-114.9189084,25.2926881],[-114.8982295,25.6702982],[-114.7795013,25.864579],[-114.71191,26.1294741],[-114.6166467,26.2116512],[-114.3854565,26.1385038],[-114.2473565,26.3503637],[-114.019463,26.3827742],[-113.9588306,26.515573],[-114.024134,26.723673],[-114.1848779,26.9641124],[-114.450416,26.761723],[-114.5970712,26.8273773],[-114.8249743,26.746691],[-115.0660064,26.8046076],[-115.1591149,26.989045],[-115.0968913,27.1271155],[-115.4254368,27.2598158],[-115.0222335,27.61334],[-114.7554104,27.7523708],[-114.6369161,27.7461684],[-114.6271607,27.5182412],[-114.2675977,27.5309049],[-114.1491003,27.6892798],[-114.3011765,27.8510633],[-114.2724802,27.9680195],[-114.6479065,28.0146313],[-114.7169801,28.2228671],[-115.1773335,28.5698501],[-115.0936918,28.8086539],[-114.7668933,28.8460722],[-114.5845466,29.0642024],[-114.5753229,29.2424212],[-114.4119906,29.5031536],[-114.2266336,29.5588376],[-114.0715529,29.7705013],[-113.7851733,29.8451971],[-113.6601518,30.0544573],[-113.3825041,30.0356238],[-113.2259441,29.8888404],[-113.0927986,29.9871439],[-112.7908299,29.8257323],[-112.5356432,29.922517],[-112.16084,29.8770964],[-111.8588906,29.9427328],[-111.6513827,29.9237934],[-111.5637161,30.0295502],[-111.3698514,30.0548007],[-111.0348712,29.9865913],[-110.404141,28.383631],[-109.732916,26.7273724],[-109.4556922,26.0569686],[-109.2186609,26.0939139],[-109.1850134,26.1842116],[-108.5306246,25.9240653],[-108.3459951,25.9654464],[-108.3057979,26.2246226],[-108.1870501,26.3605825],[-107.970164,26.2034613],[-107.4652437,26.0293285],[-106.8305304,25.5824191],[-106.6834711,25.5007383],[-106.2017995,25.5062608],[-105.9785394,25.1987313],[-106.00102,24.9040786],[-106.2133256,25.0223483],[-106.5544427,25.0432941],[-106.8576943,25.4393844],[-107.0431296,25.5310025],[-107.2074284,25.5172186],[-107.3467617,25.7514518],[-107.5597575,25.8444976],[-107.8927317,25.7976348]]]]},"properties":{"geo_id":"0400000US02","fips_state":"02","name":"Alaska","lsad":"","census_area":570640.95,"iso_3166_2":"AK","census":710231,"pop_estimataes_base":710249,"pop_2010":713856,"pop_2011":722572,"pop_2012":731081,"pop_2013":737259,"pop_2014":736732,"rmapshaperid":48}},
{"type":"Feature","geometry":{"type":"MultiPolygon","coordinates":[[[[-102.2717161,25.4167587],[-102.0480622,25.2849457],[-101.7093979,25.1626344],[-101.488557,24.9879865],[-101.3467618,24.7721403],[-101.1526699,24.6526588],[-101.2885942,24.473614],[-101.5956024,24.3994658],[-101.7841219,24.2755095],[-101.9120516,24.0562054],[-102.149052,24.1851879],[-102.2125446,24.4922359],[-102.4680818,24.9007686],[-102.2837272,25.2035934],[-102.2717161,25.4167587]]],[[[-106.3707961,27.5916137],[-106.2139358,27.4762144],[-106.3238709,27.2346791],[-106.6629134,27.3615355],[-106.6665001,27.5267513],[-106.3707961,27.5916137]]],[[[-103.2675671,26.2447126],[-103.1034616,26.1061515],[-102.8598677,26.1351171],[-102.603137,25.9871327],[-102.6283793,25.8445334],[-102.9462272,25.7790278],[-103.0718789,25.990237],[-103.2507802,26.0371755],[-103.2675671,26.2447126]]],[[[-104.7852212,26.5912503],[-105.0111469,26.7855447],[-104.7807343,27.0048826],[-104.6045375,26.7398588],[-104.5482254,26.5352002],[-104.7852212,26.5912503]]]]},"properties":{"geo_id":"0400000US15","fips_state":"15","name":"Hawaii","lsad":"","census_area":6422.628,"iso_3166_2":"HI","census":1360301,"pop_estimataes_base":1360301,"pop_2010":1363950,"pop_2011":1378251,"pop_2012":1392766,"pop_2013":1408987,"pop_2014":1419561,"rmapshaperid":49}}
]};
var us_hex = {"type": "FeatureCollection", "features": [{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-72.625738,55.313204],[-69.902864,54.408434],[-69.902864,52.537442],[-72.625738,51.57081],[-75.348611,52.537442],[-75.348611,54.408434],[-72.625738,55.313204]]]},"properties":{"cartodb_id":1219,"created_at":"2015-05-13T22:26:15Z","updated_at":"2015-10-05T16:00:16Z","label":"Maine","bees":60.5,"iso3166_2":"ME","google_name":"Maine (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-72.625738,49.57439],[-69.902864,48.544312],[-69.902864,46.419873],[-72.625738,45.325375],[-75.348611,46.419873],[-75.348611,48.544312],[-72.625738,49.57439]]]},"properties":{"cartodb_id":1217,"created_at":"2015-05-13T22:24:35Z","updated_at":"2015-10-05T16:00:16Z","label":"R.I.","bees":47.8,"iso3166_2":"RI","google_name":"Rhode Island (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-80.794358,52.537442],[-78.071485,51.57081],[-78.071485,49.57439],[-80.794358,48.544312],[-83.517232,49.57439],[-83.517232,51.57081],[-80.794358,52.537442]]]},"properties":{"cartodb_id":1218,"created_at":"2015-05-13T22:25:00Z","updated_at":"2015-10-05T16:00:16Z","label":"Vt.","bees":33.9,"iso3166_2":"VT","google_name":"Vermont (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-110.745967,35.798214],[-108.023093,34.512972],[-108.023093,31.882459],[-110.745967,30.53798],[-113.46884,31.882459],[-113.46884,34.512972],[-110.745967,35.798214]]]},"properties":{"cartodb_id":231,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Okla.","bees":63.4,"iso3166_2":"OK","google_name":"Oklahoma (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-91.685852,39.530104],[-88.962979,38.307039],[-88.962979,35.798214],[-91.685852,34.512972],[-94.408726,35.798214],[-94.408726,38.307039],[-91.685852,39.530104]]]},"properties":{"cartodb_id":244,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"N.C.","bees":41.5,"iso3166_2":"NC","google_name":"North Carolina (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-88.962979,43.071698],[-86.240105,41.912567],[-86.240105,39.530104],[-88.962979,38.307039],[-91.685852,39.530104],[-91.685852,41.912567],[-88.962979,43.071698]]]},"properties":{"cartodb_id":259,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Va.","bees":45.6,"iso3166_2":"VA","google_name":"Virginia (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-94.408726,43.071698],[-91.685852,41.912567],[-91.685852,39.530104],[-94.408726,38.307039],[-97.131599,39.530104],[-97.131599,41.912567],[-94.408726,43.071698]]]},"properties":{"cartodb_id":260,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"W.Va.","bees":59.5,"iso3166_2":"WV","google_name":"West Virginia (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-124.360334,39.530104],[-121.637461,38.307039],[-121.637461,35.798214],[-124.360334,34.512972],[-127.083208,35.798214],[-127.083208,38.307039],[-124.360334,39.530104]]]},"properties":{"cartodb_id":250,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Calif.","bees":40.1,"iso3166_2":"CA","google_name":"California (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-108.023093,39.530104],[-105.30022,38.307039],[-105.30022,35.798214],[-108.023093,34.512972],[-110.745967,35.798214],[-110.745967,38.307039],[-108.023093,39.530104]]]},"properties":{"cartodb_id":247,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Kan.","bees":40.8,"iso3166_2":"KS","google_name":"Kansas (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-99.854473,43.071698],[-97.131599,41.912567],[-97.131599,39.530104],[-99.854473,38.307039],[-102.577346,39.530104],[-102.577346,41.912567],[-99.854473,43.071698]]]},"properties":{"cartodb_id":261,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ky.","bees":47.7,"iso3166_2":"KY","google_name":"Kentucky (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-83.517232,43.071698],[-80.794358,41.912567],[-80.794358,39.530104],[-83.517232,38.307039],[-86.240105,39.530104],[-86.240105,41.912567],[-83.517232,43.071698]]]},"properties":{"cartodb_id":258,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Md.","bees":60.9,"iso3166_2":"MD","google_name":"Maryland (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-105.30022,43.071698],[-102.577346,41.912567],[-102.577346,39.530104],[-105.30022,38.307039],[-108.023093,39.530104],[-108.023093,41.912567],[-105.30022,43.071698]]]},"properties":{"cartodb_id":262,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Mo.","bees":34.9,"iso3166_2":"MO","google_name":"Missouri (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-110.745967,43.071698],[-108.023093,41.912567],[-108.023093,39.530104],[-110.745967,38.307039],[-113.46884,39.530104],[-113.46884,41.912567],[-110.745967,43.071698]]]},"properties":{"cartodb_id":263,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Neb.","bees":37.3,"iso3166_2":"NE","google_name":"Nebraska (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-113.46884,39.530104],[-110.745967,38.307039],[-110.745967,35.798214],[-113.46884,34.512972],[-116.191714,35.798214],[-116.191714,38.307039],[-113.46884,39.530104]]]},"properties":{"cartodb_id":248,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"N.M.","bees":46.1,"iso3166_2":"NM","google_name":"New Mexico (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-86.240105,39.530104],[-83.517232,38.307039],[-83.517232,35.798214],[-86.240105,34.512972],[-88.962979,35.798214],[-88.962979,38.307039],[-86.240105,39.530104]]]},"properties":{"cartodb_id":243,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"S.C.","bees":26.6,"iso3166_2":"SC","google_name":"South Carolina (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-97.131599,39.530104],[-94.408726,38.307039],[-94.408726,35.798214],[-97.131599,34.512972],[-99.854473,35.798214],[-99.854473,38.307039],[-97.131599,39.530104]]]},"properties":{"cartodb_id":245,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Tenn.","bees":36.4,"iso3166_2":"TN","google_name":"Tennessee (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-108.023093,46.419873],[-105.30022,45.325375],[-105.30022,43.071698],[-108.023093,41.912567],[-110.745967,43.071698],[-110.745967,45.325375],[-108.023093,46.419873]]]},"properties":{"cartodb_id":279,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Iowa","bees":61.4,"iso3166_2":"IA","google_name":"Iowa (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-121.637461,43.071698],[-118.914587,41.912567],[-118.914587,39.530104],[-121.637461,38.307039],[-124.360334,39.530104],[-124.360334,41.912567],[-121.637461,43.071698]]]},"properties":{"cartodb_id":265,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Nev.","bees":26.7,"iso3166_2":"NV","google_name":"Nevada (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-80.794358,46.419873],[-78.071485,45.325375],[-78.071485,43.071698],[-80.794358,41.912567],[-83.517232,43.071698],[-83.517232,45.325375],[-80.794358,46.419873]]]},"properties":{"cartodb_id":274,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"N.J.","bees":47.6,"iso3166_2":"NJ","google_name":"New Jersey (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-113.46884,46.419873],[-110.745967,45.325375],[-110.745967,43.071698],[-113.46884,41.912567],[-116.191714,43.071698],[-116.191714,45.325375],[-113.46884,46.419873]]]},"properties":{"cartodb_id":280,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"S.D.","bees":36.1,"iso3166_2":"SD","google_name":"South Dakota (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-91.685852,46.419873],[-88.962979,45.325375],[-88.962979,43.071698],[-91.685852,41.912567],[-94.408726,43.071698],[-94.408726,45.325375],[-91.685852,46.419873]]]},"properties":{"cartodb_id":276,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ohio","bees":49.8,"iso3166_2":"OH","google_name":"Ohio (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-118.914587,46.419873],[-116.191714,45.325375],[-116.191714,43.071698],[-118.914587,41.912567],[-121.637461,43.071698],[-121.637461,45.325375],[-118.914587,46.419873]]]},"properties":{"cartodb_id":281,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Wyo.","bees":32.5,"iso3166_2":"WY","google_name":"Wyoming (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-80.794358,39.530104],[-78.071485,38.307039],[-78.071485,35.798214],[-80.794358,34.512972],[-83.517232,35.798214],[-83.517232,38.307039],[-80.794358,39.530104]]]},"properties":{"cartodb_id":242,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"D.C.","bees":null,"iso3166_2":"DC","google_name":"District of Columbia (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-78.071485,43.071698],[-75.348611,41.912567],[-75.348611,39.530104],[-78.071485,38.307039],[-80.794358,39.530104],[-80.794358,41.912567],[-78.071485,43.071698]]]},"properties":{"cartodb_id":257,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Del.","bees":61,"iso3166_2":"DE","google_name":"Delaware (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-91.685852,31.882459],[-88.962979,30.53798],[-88.962979,27.792925],[-91.685852,26.393432],[-94.408726,27.792925],[-94.408726,30.53798],[-91.685852,31.882459]]]},"properties":{"cartodb_id":212,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Fla.","bees":54.8,"iso3166_2":"FL","google_name":"Florida (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-75.348611,52.537442],[-72.625738,51.57081],[-72.625738,49.57439],[-75.348611,48.544312],[-78.071485,49.57439],[-78.071485,51.57081],[-75.348611,52.537442]]]},"properties":{"cartodb_id":305,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"N.H.","bees":39.4,"iso3166_2":"NH","google_name":"New Hampshire (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-135.251828,31.882459],[-132.528955,30.53798],[-132.528955,27.792925],[-135.251828,26.393432],[-137.974702,27.792925],[-137.974702,30.53798],[-135.251828,31.882459]]]},"properties":{"cartodb_id":220,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"H.I.","bees":13.9,"iso3166_2":"HI","google_name":"Hawaii (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-108.023093,31.882459],[-105.30022,30.53798],[-105.30022,27.792925],[-108.023093,26.393432],[-110.745967,27.792925],[-110.745967,30.53798],[-108.023093,31.882459]]]},"properties":{"cartodb_id":215,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Texas","bees":46.3,"iso3166_2":"TX","google_name":"Texas (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-94.408726,35.798214],[-91.685852,34.512972],[-91.685852,31.882459],[-94.408726,30.53798],[-97.131599,31.882459],[-97.131599,34.512972],[-94.408726,35.798214]]]},"properties":{"cartodb_id":228,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ala.","bees":48.1,"iso3166_2":"AL","google_name":"Alabama (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-116.191714,35.798214],[-113.46884,34.512972],[-113.46884,31.882459],[-116.191714,30.53798],[-118.914587,31.882459],[-118.914587,34.512972],[-116.191714,35.798214]]]},"properties":{"cartodb_id":232,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ariz.","bees":42.9,"iso3166_2":"AZ","google_name":"Arizona (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-88.962979,35.798214],[-86.240105,34.512972],[-86.240105,31.882459],[-88.962979,30.53798],[-91.685852,31.882459],[-91.685852,34.512972],[-88.962979,35.798214]]]},"properties":{"cartodb_id":227,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ga.","bees":34.9,"iso3166_2":"GA","google_name":"Georgia (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-105.30022,35.798214],[-102.577346,34.512972],[-102.577346,31.882459],[-105.30022,30.53798],[-108.023093,31.882459],[-108.023093,34.512972],[-105.30022,35.798214]]]},"properties":{"cartodb_id":230,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"La.","bees":44.3,"iso3166_2":"LA","google_name":"Louisiana (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-99.854473,35.798214],[-97.131599,34.512972],[-97.131599,31.882459],[-99.854473,30.53798],[-102.577346,31.882459],[-102.577346,34.512972],[-99.854473,35.798214]]]},"properties":{"cartodb_id":229,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Miss.","bees":38.7,"iso3166_2":"MS","google_name":"Mississippi (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-118.914587,39.530104],[-116.191714,38.307039],[-116.191714,35.798214],[-118.914587,34.512972],[-121.637461,35.798214],[-121.637461,38.307039],[-118.914587,39.530104]]]},"properties":{"cartodb_id":249,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Utah","bees":33.5,"iso3166_2":"UT","google_name":"Utah (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-116.191714,43.071698],[-113.46884,41.912567],[-113.46884,39.530104],[-116.191714,38.307039],[-118.914587,39.530104],[-118.914587,41.912567],[-116.191714,43.071698]]]},"properties":{"cartodb_id":264,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Colo.","bees":38,"iso3166_2":"CO","google_name":"Colorado (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-102.577346,39.530104],[-99.854473,38.307039],[-99.854473,35.798214],[-102.577346,34.512972],[-105.30022,35.798214],[-105.30022,38.307039],[-102.577346,39.530104]]]},"properties":{"cartodb_id":246,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ark.","bees":48.3,"iso3166_2":"AR","google_name":"Arkansas (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-124.360334,46.419873],[-121.637461,45.325375],[-121.637461,43.071698],[-124.360334,41.912567],[-127.083208,43.071698],[-127.083208,45.325375],[-124.360334,46.419873]]]},"properties":{"cartodb_id":282,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Idaho","bees":33.3,"iso3166_2":"ID","google_name":"Idaho (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-127.083208,43.071698],[-124.360334,41.912567],[-124.360334,39.530104],[-127.083208,38.307039],[-129.806081,39.530104],[-129.806081,41.912567],[-127.083208,43.071698]]]},"properties":{"cartodb_id":266,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ore.","bees":25.2,"iso3166_2":"OR","google_name":"Oregon (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-102.577346,46.419873],[-99.854473,45.325375],[-99.854473,43.071698],[-102.577346,41.912567],[-105.30022,43.071698],[-105.30022,45.325375],[-102.577346,46.419873]]]},"properties":{"cartodb_id":278,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ill.","bees":62.4,"iso3166_2":"IL","google_name":"Illinois (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-86.240105,46.419873],[-83.517232,45.325375],[-83.517232,43.071698],[-86.240105,41.912567],[-88.962979,43.071698],[-88.962979,45.325375],[-86.240105,46.419873]]]},"properties":{"cartodb_id":275,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Pa.","bees":60.6,"iso3166_2":"PA","google_name":"Pennsylvania (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-97.131599,46.419873],[-94.408726,45.325375],[-94.408726,43.071698],[-97.131599,41.912567],[-99.854473,43.071698],[-99.854473,45.325375],[-97.131599,46.419873]]]},"properties":{"cartodb_id":277,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Ind.","bees":49.1,"iso3166_2":"IN","google_name":"Indiana (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-83.517232,49.57439],[-80.794358,48.544312],[-80.794358,46.419873],[-83.517232,45.325375],[-86.240105,46.419873],[-86.240105,48.544312],[-83.517232,49.57439]]]},"properties":{"cartodb_id":290,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"N.Y.","bees":54.1,"iso3166_2":"NY","google_name":"New York (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-127.083208,49.57439],[-124.360334,48.544312],[-124.360334,46.419873],[-127.083208,45.325375],[-129.806081,46.419873],[-129.806081,48.544312],[-127.083208,49.57439]]]},"properties":{"cartodb_id":298,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Wash.","bees":39.3,"iso3166_2":"WA","google_name":"Washington (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-105.30022,49.57439],[-102.577346,48.544312],[-102.577346,46.419873],[-105.30022,45.325375],[-108.023093,46.419873],[-108.023093,48.544312],[-105.30022,49.57439]]]},"properties":{"cartodb_id":294,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Wis.","bees":60.2,"iso3166_2":"WI","google_name":"Wisconsin (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-78.071485,49.57439],[-75.348611,48.544312],[-75.348611,46.419873],[-78.071485,45.325375],[-80.794358,46.419873],[-80.794358,48.544312],[-78.071485,49.57439]]]},"properties":{"cartodb_id":289,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Mass.","bees":46.4,"iso3166_2":"MA","google_name":"Massachusetts (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-94.408726,49.57439],[-91.685852,48.544312],[-91.685852,46.419873],[-94.408726,45.325375],[-97.131599,46.419873],[-97.131599,48.544312],[-94.408726,49.57439]]]},"properties":{"cartodb_id":292,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Mich.","bees":27.7,"iso3166_2":"MI","google_name":"Michigan (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-110.745967,49.57439],[-108.023093,48.544312],[-108.023093,46.419873],[-110.745967,45.325375],[-113.46884,46.419873],[-113.46884,48.544312],[-110.745967,49.57439]]]},"properties":{"cartodb_id":295,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Minn.","bees":51.2,"iso3166_2":"MN","google_name":"Minnesota (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-121.637461,49.57439],[-118.914587,48.544312],[-118.914587,46.419873],[-121.637461,45.325375],[-124.360334,46.419873],[-124.360334,48.544312],[-121.637461,49.57439]]]},"properties":{"cartodb_id":297,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Mont.","bees":41.1,"iso3166_2":"MT","google_name":"Montana (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-116.191714,49.57439],[-113.46884,48.544312],[-113.46884,46.419873],[-116.191714,45.325375],[-118.914587,46.419873],[-118.914587,48.544312],[-116.191714,49.57439]]]},"properties":{"cartodb_id":296,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"N.D.","bees":40.4,"iso3166_2":"ND","google_name":"North Dakota (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-132.528955,55.313204],[-129.806081,54.408434],[-129.806081,52.537442],[-132.528955,51.57081],[-135.251828,52.537442],[-135.251828,54.408434],[-132.528955,55.313204]]]},"properties":{"cartodb_id":331,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"A.K.","bees":null,"iso3166_2":"AK","google_name":"Alaska (United States)"}},{"type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-75.348611,46.419873],[-72.625738,45.325375],[-72.625738,43.071698],[-75.348611,41.912567],[-78.071485,43.071698],[-78.071485,45.325375],[-75.348611,46.419873]]]},"properties":{"cartodb_id":273,"created_at":"2015-05-13T22:02:22Z","updated_at":"2015-10-05T16:00:16Z","label":"Conn.","bees":57.5,"iso3166_2":"CT","google_name":"Connecticut (United States)"}}]};
var projection = d3.geoAlbersUsa();
projection.fitSize([450,400], us_geo);
var path = d3.geoPath().projection(projection);
var path_hex = d3.geoPath()
.projection(d3.geoMercator().fitSize([450,400], us_hex));
var svg = d3.select('#map');
var states = svg.append('g')
.attr('class','states')
.selectAll('path')
.data(us_geo.features)
.enter()
.append('path')
.attr('d', path)
.style('stroke', 'black')
.style('fill', 'none')
.style('pointer-events', 'all');
var hexstates = svg.append('g')
.attr('class', 'hex')
.style('transform', 'translate(450px,0)')
.selectAll('path')
.data(us_hex.features)
.enter()
.append('path')
.attr('d', path_hex)
.style('stroke', 'black')
.style('fill', 'none')
.style('pointer-events', 'all');
states.on('click', function(d) {
var path_strings = flubber.splitPathString(path(d));
var hex_path = hexstates.nodes()
.filter(function(hd) {
return d.properties.iso_3166_2 === d3.select(hd).datum().properties.iso3166_2
})[0]
.getAttribute('d');
if(path_strings.length == 1) {
var interpolator = flubber.interpolate(
d3.select(this).attr('d'),
hex_path
);
} else {
var interpolator = flubber.combine(
path_strings,
hex_path,
{single: true}
);
}
var cloned = d3.select(
d3.select('g.states')
.node()
.appendChild(this.cloneNode(true))
);
cloned
.transition()
.duration(2000)
.attr('transform', 'translate(450,0)')
.style('stroke', 'red')
.style('stroke-width', '3px')
.attrTween('d', function(){ return interpolator; })
.transition()
.style('opacity',0.001)
.remove();
})
hexstates.on('click', function(d) {
var state_path = states.nodes()
.filter(function(hd) {
return d.properties.iso3166_2 === d3.select(hd).datum().properties.iso_3166_2;
})[0]
.getAttribute('d');
var path_strings = flubber.splitPathString(state_path);
if(path_strings.length == 1) {
var interpolator = flubber.interpolate(
d3.select(this).attr('d'),
state_path
);
} else {
var interpolator = flubber.separate(
d3.select(this).attr('d'),
path_strings,
{single: true}
);
}
var cloned = d3.select(
d3.select('g.hex')
.node()
.appendChild(this.cloneNode(true))
);
cloned
.transition()
.duration(2000)
.attr('transform', 'translate(-450,0)')
.style('stroke', 'red')
.style('stroke-width', '3px')
.attrTween('d', function(){ return interpolator; })
.transition()
.style('opacity',0.001)
.remove();
})
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment