Skip to content

Instantly share code, notes, and snippets.

View vigorousnorth's full-sized avatar

Christian MilNeil vigorousnorth

  • StreetsblogMASS
  • Portland, Maine and Boston, Mass.
  • X @c_milneil
View GitHub Profile
state geocode suicide_all suicide_gun suicide_other homicide_all homicide_gun homicide_other gun_undetermined_intent avg_population brady_score
Alabama 01 3698 2561 1137 2213 1760 453 48 4845480.2 -18
Alaska 02 900 569 331 234 144 90 30 736727.8 -30
Arizona 03 6110 3463 2647 1889 1256 633 63 6734099.8 -39
Arkansas 04 2648 1625 1023 1132 816 316 31 2968265 -24
California 05 20593 7856 12737 9774 6770 3004 61 38714257.2 76
Colorado 06 5403 2715 2688 1007 621 386 43 5361786.8 22
Connecticut 07 1858 542 1316 564 373 191 3590088.4 73
Delaware 08 614 285 329 299 219 80 935290.8 41
District of Columbia 09 201 46 155 532 386 146 658212.6
@vigorousnorth
vigorousnorth / index.html
Last active January 13, 2019 01:37
Labelled graticules
<!DOCTYPE html>
<meta charset="utf-8">
<!-- A refinement of http://bl.ocks.org/mbostock/3664049 with labeled graticules -->
<style>
.graticule {
fill: none;
stroke: #000;
We can't make this file beautiful and searchable because it's too large.
indicator,geoCode,geoName
AG_LND_FRSTCHG,96,Brunei Darussalam
AG_LND_FRSTCHG,92,British Virgin Islands
AG_LND_FRSTCHG,90,Solomon Islands
AG_LND_FRSTCHG,9,Oceania
AG_LND_FRSTCHG,894,Zambia
AG_LND_FRSTCHG,887,Yemen
AG_LND_FRSTCHG,882,Samoa
AG_LND_FRSTCHG,876,Wallis and Futuna Islands
AG_LND_FRSTCHG,862,Venezuela (Bolivarian Republic of)
[{"geoAreaCode":"4","geoAreaName":"Afghanistan","reportedTopics":["DC_TOF_SCHIPSL"]},{"geoAreaCode":"248","geoAreaName":"Åland Islands"},{"geoAreaCode":"8","geoAreaName":"Albania","reportedTopics":["SE_SEP_MATACH","SE_LGP_ACHIMA","SE_GPI_MATACH","SE_GPI_REAACH","SE_MAT_PROF","SE_REA_PROF","SE_SEP_REAACH","DC_TOF_SCHIPSL","SE_PRE_GPIPARTN","SE_PRE_PARTN","SE_NAP_ACHIMA","SE_NAP_ACHIRE","SE_URP_MATACH","SE_LGP_ACHIRE","SE_URP_REAACH"]},{"geoAreaCode":"12","geoAreaName":"Algeria","reportedTopics":["SE_DEV_ONTRK","SE_GPI_TRATEA","SE_SEP_MATACH","SE_LGP_ACHIMA","SE_GPI_MATACH","SE_GPI_REAACH","SE_MAT_PROF","SE_REA_PROF","SE_SEP_REAACH","DC_TOF_SCHIPSL","SE_TRA_GRDL","SE_PRE_GPIPARTN","SE_PRE_PARTN","SE_NAP_ACHIMA","SE_NAP_ACHIRE","SE_URP_MATACH","SE_LGP_ACHIRE","SE_URP_REAACH"]},{"geoAreaCode":"16","geoAreaName":"American Samoa"},{"geoAreaCode":"20","geoAreaName":"Andorra","reportedTopics":["SE_ACC_COMP","SE_GPI_TRATEA","SE_INF_DSBL","SE_TRA_GRDL","SE_ACC_ELEC","SE_ACC_HNWA","SE_ACC_INTN","SE_ACC_DWAT","SE_ACC_SAN
[{"geoAreaCode":"4","geoAreaName":"Afghanistan","reportedTopics":["DC_TOF_SCHIPSL"]},{"geoAreaCode":"248","geoAreaName":"Åland Islands"},{"geoAreaCode":"8","geoAreaName":"Albania","reportedTopics":["SE_SEP_MATACH","SE_LGP_ACHIMA","SE_GPI_MATACH","SE_GPI_REAACH","SE_MAT_PROF","SE_REA_PROF","SE_SEP_REAACH","DC_TOF_SCHIPSL","SE_PRE_GPIPARTN","SE_PRE_PARTN","SE_NAP_ACHIMA","SE_NAP_ACHIRE","SE_URP_MATACH","SE_LGP_ACHIRE","SE_URP_REAACH"]},{"geoAreaCode":"12","geoAreaName":"Algeria","reportedTopics":["SE_DEV_ONTRK","SE_GPI_TRATEA","SE_SEP_MATACH","SE_LGP_ACHIMA","SE_GPI_MATACH","SE_GPI_REAACH","SE_MAT_PROF","SE_REA_PROF","SE_SEP_REAACH","DC_TOF_SCHIPSL","SE_TRA_GRDL","SE_PRE_GPIPARTN","SE_PRE_PARTN","SE_NAP_ACHIMA","SE_NAP_ACHIRE","SE_URP_MATACH","SE_LGP_ACHIRE","SE_URP_REAACH"]},{"geoAreaCode":"16","geoAreaName":"American Samoa"},{"geoAreaCode":"20","geoAreaName":"Andorra","reportedTopics":["SE_ACC_COMP","SE_GPI_TRATEA","SE_INF_DSBL","SE_TRA_GRDL","SE_ACC_ELEC","SE_ACC_HNWA","SE_ACC_INTN","SE_ACC_DWAT","SE_ACC_SAN
Country 2017
Afghanistan 1888.86
Albania 12471.74
Algeria 15149.60
Angola 6813.21
Antigua and Barbuda 26198.35
Argentina 20676.52
Armenia 9098.38
Australia 49882.30
Austria 49247.22
side year miles gas
left 1956 3683.6965 2.3829
right 1957 3722.7648 2.4026
bottom 1958 3776.8595 2.2539
top 1959 3912.0962 2.3079
right 1960 3942.1488 2.2658
bottom 1961 3984.2224 2.2526
right 1962 4089.4064 2.2158
bottom 1963 4230.6536 2.1237
bottom 1964 4383.9219 2.1039
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@vigorousnorth
vigorousnorth / arcs.js
Last active March 22, 2019 02:49
Arc map with scaled arrowheads
var svg,
width = 900,
height = 700;
var projection = d3.geo.equirectangular()
.rotate([-10,0]).scale(height/5).translate([width / 2, height / 2]).clipExtent([[0,0.1*height],[width,height*0.85]]);
var path = d3.geo.path()
.projection(projection);
@vigorousnorth
vigorousnorth / index.html
Last active May 28, 2019 12:15
Pie chart with rotated wedge labels
<!DOCTYPE html>
<meta charset="utf-8">
<script src="http://d3js.org/d3.v3.min.js"></script>
<script>
var piecolors = d3.scale.category20c();
var w = 600,
h = 460,