Skip to content

Instantly share code, notes, and snippets.

View hepplerj's full-sized avatar
💭
building the history web

Jason Heppler hepplerj

💭
building the history web
View GitHub Profile
@hepplerj
hepplerj / ocr-check.py
Created May 13, 2016 16:12
OCR cleanup check
#!/usr/bin/env python
import collections, pprint, re, sys
with open(sys.argv[1],'r') as file_in:
chars = re.sub('[\s\w!!"#$%&()*+,-./:;<=>?@^_`{|}~\[\]\'\\\]','', file_in.read())
counts = collections.Counter(chars)
pprint.pprint(counts.most_common())
@hepplerj
hepplerj / .gistup
Last active April 28, 2016 17:14
Greenland coast
gistup
@hepplerj
hepplerj / data.json
Last active November 16, 2015 21:17
Punchcard Visualization
[
{
"tasks": [
[
12,
6
],
[
13,
10
@hepplerj
hepplerj / Sublime.json
Created October 17, 2015 00:05
Sublime Text preferences
{
"auto_complete_triggers":
[
{
"characters": ".@",
"selector": "source.coffee, source.litcoffee, source.coffee.md"
}
],
"bibtex_file_path": "/Users/jheppler/Dropbox/acad/bib/master.bib",
"bold_folder_labels": true,
@hepplerj
hepplerj / rhine.json
Created October 6, 2015 20:55
Custom Neatline base map
{
"Mapbox (Custom)": [
{
"title": "Mapbox Rhine custom",
"id": "Mapbox.mgtaylor.e25e78e6",
"type": "XYZ",
"properties": {
"urls": [
@hepplerj
hepplerj / 2013MASTER.csv
Last active April 20, 2019 01:45
Mass Shootings in the U.S.
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 5.
reported,date,shooter,killed,wounded,location,article1,article2,article3,article4,article5,article6,article7,article8,article9
,1/1/2013,Carlito Montoya,4,0,"Sacramento, CA",http://sanfrancisco.cbslocal.com/2013/01/12/3-young-men-teenage-boy-murdered-on-oakland-streets-in-6-hours-no-arrests/,http://hinterlandgazette.com/2013/01/oakland-gun-violence-ken-harbin-larry-lovette-eddiebo-rodriguez-4-killed-6hour-span.html,http://www.huffingtonpost.com/2013/01/12/oakland-shootings_n_2464783.html,,,,,,
,1/1/2013,Unknown,1,3,"Hawthorne, CA",http://losangeles.cbslocal.com/2013/01/01/man-killed-3-wounded-at-nye-party-in-hawthorne/,http://latimesblogs.latimes.com/lanow/2013/01/hawthorne-new-year-party-three-killed.html,,,,,,,
,1/1/2013,Julian Sims,0,4,"McKeesport, PA",http://pittsburgh.cbslocal.com/2013/01/01/4-people-shot-in-mckeesport/,http://www.wtae.com/news/local/allegheny/U-S-Marshals-task-force-arrests-New-Year-s-party-shooting-suspect/-/10927008/17977588/-/1ydqtj/-/index.html,,,,,,,
,1/1/2013,"Desmen Noble, Da
@hepplerj
hepplerj / index.html
Created September 12, 2015 23:29
Mapbox GL
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<title>Mapbox GL</title>
<meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no' />
<script src='https://api.tiles.mapbox.com/mapbox-gl-js/v0.7.0/mapbox-gl.js'></script>
<link href='https://api.tiles.mapbox.com/mapbox-gl-js/v0.7.0/mapbox-gl.css' rel='stylesheet' />
<style>
body { margin:0; padding:0; }
@hepplerj
hepplerj / carter.csv
Last active September 19, 2015 22:03
Sample data
Year Total Great Britain Ireland Scandinavia Other Northwestern Europe Germany Poland Other Central Europe Former Soviet Union and Baltic States Other Eastern Europe Greece Italy Portugal Spain Other Southern Europe Japan China
1820 7691 2410 3614 23 452 968 5 0 14 1 0 30 35 139 0 1
1821 5936 3210 1518 24 521 383 1 0 7 0 0 63 18 191 0 0
1822 4418 1221 2267 28 522 148 3 0 10 4 0 35 28 152 0 0
1823 4016 1100 1908 7 528 183 3 0 7 2 0 33 24 220 1 0
1824 4965 1264 2345 20 671 230 4 0 7 2 5 45 13 359 0 0
1825 8543 2095 4888 18 719 450 1 0 10 0 0 75 13 273 1 1
1826 9751 2319 5408 26 968 511 0 0 4 2 4 57 16 436 0 0
1827 16719 4186 9766 28 1829 432 1 0 19 1 0 35 7 414 1 0
1828 24729 5352 12488 60 4700 1851 1 0 7 6 7 34 14 209 0 0
@hepplerj
hepplerj / index.html
Created August 27, 2015 19:11
D3 starter
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>DHRG</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.6/d3.min.js" charset="utf-8"></script>
</head>
@hepplerj
hepplerj / index.html
Last active August 29, 2015 14:21
Chinese Text
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Chinese Input</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="style.css">
<link href="./bower_components/bootstrap/dist/css/bootstrap.css" rel="stylesheet">
<link rel="stylesheet" href="style.css">