Skip to content

Instantly share code, notes, and snippets.

View samuelestabrook's full-sized avatar

Sam samuelestabrook

View GitHub Profile
@samuelestabrook
samuelestabrook / d3-v4-js-map-zoom-pan-with-buttons.markdown
Created April 14, 2019 14:44
D3.v4.js map zoom & pan with buttons
@samuelestabrook
samuelestabrook / licensed_businesses_co.geojson
Created April 3, 2019 06:08
Go Code Colorado geocode (90% complete)
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@samuelestabrook
samuelestabrook / no_crash_spatial_join.py
Last active August 29, 2015 14:26
Open source stable spatial join for big data
# open source spatial join script
# fiona and shapely scripting adapted from ThomasG77's comment from:
# http://gis.stackexchange.com/questions/119374/intersect-shapefiles-using-shapely
#
# import libraries
import fiona, rtree, os, shapefile
from shapely.geometry import shape, mapping
from os.path import isfile
@samuelestabrook
samuelestabrook / Qt_fix_QGIS.md
Last active August 29, 2015 14:24
Fix Qt for Homebrew QGIS install

Fix Qt for Homebrew QGIS install

Go to terminal and roll back the Qt installation through GitHub

$ brew uninstall qt
$ brew install https://raw.githubusercontent.com/Homebrew/homebrew/8dd3478131b232553f4c0cab197f8443a0a559a6/Library/Formula/qt.rb
@samuelestabrook
samuelestabrook / 0_reuse_code.js
Last active August 29, 2015 14:24
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@samuelestabrook
samuelestabrook / Polylines.md
Last active August 29, 2015 14:24
How to create polylines to symbolize a shared boundary

How to create polylines to symbolize a shared boundary

  • Download and install Mapshaper
$ npm install -g mapshaper
  • Using a topologically-sound polygon dataset as the input, run and -innerlines tag on the mapshaper command:
@samuelestabrook
samuelestabrook / postgis_aggregate_queries.md
Last active August 29, 2015 14:23
PostGIS HAP Aggregate Queries

PostGIS HAP Aggregate Queries

Per Robert's request, here are some queries that take many rows of data, aggregate them based on the location (unique counts) or sector (unique sectors), then join the aggregates to the geometries at different levels.

ADMIN 3 QUERY: PROJECT COUNTS

WITH hap_counts AS (
	SELECT 
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@samuelestabrook
samuelestabrook / simplified.topojson
Last active August 29, 2015 14:11
Simplified TopoJson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.