Skip to content

Instantly share code, notes, and snippets.

View pjsier's full-sized avatar

Pat Sier pjsier

View GitHub Profile
@pjsier
pjsier / mcomm_search.py
Last active August 29, 2015 14:11
Quick script to check if names on list are Michigan undergraduates using MCommmunity open API. Used to check against voter registration data
import urllib2
import csv, json
def respondAndParse(name_list):
stu_list = []
for named in name_list:
for name in named:
query_string = name.replace(" ", "%20")
URLrecord = "https://mcommunity.umich.edu/mcPeopleService/people/search/" + query_string
@pjsier
pjsier / mapzen_typeahead.html
Last active October 31, 2017 23:09
Using typeahead.js with Mapzen Search autocomplete and displaying selected locations in Leaflet
<!DOCTYPE html>
<html>
<head>
<title>Mapzen Autocomplete Gist</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" />
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.css" />
<script src="https://code.jquery.com/jquery-1.12.0.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/typeahead.js/0.11.1/typeahead.bundle.min.js"></script>
<script src="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.js"></script>
@pjsier
pjsier / client-templating.html
Last active July 3, 2016 23:53
Example of using Handlebars and search parameter for an entirely client-side templating layout
<!DOCTYPE html>
<html>
<head>
<title>Client-Side Templating Example</title>
<script type="text/javascript" src="https://code.jquery.com/jquery-1.12.4.min.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/handlebars.js/4.0.5/handlebars.min.js"></script>
</head>
<body>
<div id="content"></div>
<script id="detail-template" type="text/x-handlebars-template">
@pjsier
pjsier / .block
Last active June 30, 2017 20:35
Chicago Ward Shape Transitions
license: mit
height: 800
border: no
@pjsier
pjsier / .block
Last active June 30, 2017 20:54
Chicago SSL, ISR Hexbin
license: mit
height: 700
border: no
@pjsier
pjsier / .block
Last active June 30, 2017 20:34
SSL Treemap
license: mit
height: 800
border: no
@pjsier
pjsier / .block
Last active May 23, 2020 23:12
Simple Responsive Gauge
license: mit
@pjsier
pjsier / .block
Last active July 11, 2023 18:59
Real-Time Line Chart
license: mit
@pjsier
pjsier / .block
Last active July 28, 2017 11:56
Square Area Chart
license: mit
@pjsier
pjsier / .block
Created July 28, 2017 23:40
Slopegraph
license: mit