TopoJSON State Selection

Sometimes you do not want to display the US and all its counties. Sometimes you just want one or some states. This page will allow you to select the state(s) you want to display the counties and generate a TopoJSON file representing the selection.

Guide

  1. Data for processing is preloaded from a local copy of Mike Bostocks map. Feel free to clear and load your own. NOTE: It should be formatted as Mike's below. In other words, just use Mike's JSON map.
  2. "Load Data" will clear and reload the local copy of the data.
  3. ctrl + shift + i to open console for information during processing in Chrome
  4. Every time "Process Data" is clicked the "Completed JSON" file is rebuilt with the states selection above in the "e;Completed JSON" window below.
  5. Clicking "Process Data" without any checkboes selected will produce an empty map.
  6. Source data from Mike Bostock https://bl.ocks.org/mbostock/raw/4090846/us.json
  7. More on this JSON file format can be cound here at github: https://github.com/topojson/topojson-specification/blob/master/README.md#11-examples
  8. https://github.com/topojson/us-atlas
  9. Select all the content from the "Completed JSON" window and paste in notepad, or click "Copy to clipboard" to select all and copy, then open notepad and paste.

Data

  1. FIPS codes for States A - C are 01 - 09 leading FIPS and only have 4 digits since they are cataloged with the leading 0 having been omitted, so for instance 01 Alabama will have FIPS codes 1### as opposed to 01###. However they are represented as 01 when we do the county count in the Developers Tool Console for digit count consistency of a two digit representation.
  2. FIPS codes are called "id" in the data.

Input:

Completed JSON: