Skip to content

Instantly share code, notes, and snippets.

View douglasgoodwin's full-sized avatar

Doug Goodwin douglasgoodwin

View GitHub Profile
@douglasgoodwin
douglasgoodwin / termitelab.md
Last active April 10, 2019 20:21
a tiny flask server that will give you randomized compass directions for the Termite Lab.

LAB: Let's simulate termites!

ingredients

  1. a regular grid
  2. a sack of beans
  3. bottle caps or portion cups, one per termite
  4. one die per termite (or use the simulator)

instructions

  • Draw or make a large regular grid of 2"x2" cells
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Greetings

"polite":"Mighty fine day we’re having."
"bored":"Good day."
"annoyed":"Why aren’t you smiling, aren’t you enjoying the day?"
"contemptuous":"Good day, ain’t it?"
"disgusted":"*spits*"

"polite":"Nice day, isn’t it?"
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.
n=3
c=7
def setup():
background(0)
size(600,600)
def draw():
global a,n
a = n * 137.5
@douglasgoodwin
douglasgoodwin / list_stops.ipynb
Created January 10, 2018 21:05
Get a list of stops from a GTFS stops.txt file
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@douglasgoodwin
douglasgoodwin / read_stops.ipynb
Last active January 10, 2018 21:07
Get Metro's Silver Line stop addresses from the Open Trip Planner using MapBox' reverse geocoder
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
# Python Flowfield example
# Doug Goodwin
# Example derived from Daniel Shiffman's "Nature of Code"
# http:#natureofcode.com
# Flow Field Following
class FlowField(object):
def __init__(self,r):
# A flow field is a two dimensional array of PVectors
@douglasgoodwin
douglasgoodwin / digital empirical.ipynb
Created January 7, 2018 23:11
A little fun with Mendel
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.