• Stars
    star
    134
  • Rank 270,967 (Top 6 %)
  • Language
    Shell
  • Created over 8 years ago
  • Updated over 5 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

San Francisco housing construction history and associated data

Housing Inventory

This repository contains historical SF housing data and R scripts to graph that data. The data here was used to generate the graphs and analysis in the blog post "Employment, construction, and the cost of San Francisco apartments", and was recently used in a paper by Stanford researchers, "The Effects of Rent Control Expansion on Tenants, Landlords, and Inequality: Evidence from San Francisco.".

Data

Data for each year lives in the file named after the year. Later years may be listed as "craigslist-X".

You can get the rent out by running ./extract-craigslist craigslist-2016 for example. Note the data is not perfect. Here are some samples in the 2016 Craigslist data, for example.

799000 Apr 29 Exceptional Pacific Heights TIC $799000 / 2br - (Pacific Heights) pic
800 Apr 29 Awesome 5 Bedroom Available $800 / 5br - 3895ft2 - (2483 N Smiderle, San Bernardino, CA) pic
99 Apr 29 Jr. 1 BD. Washer & Dryer in unit! $99 deposit $3425 / 1br - 550ft2 - (nob hill) pic map

(It's not clear if these prices have been stripped before generating the averages in the housing-inventory file).

You can combine a bunch of data sources by running the "combine" script, ./combine. This generates the combined file in this repository.

The charts in the blog post are generated by running the model script in this repository, on the combined data.

calc-medians computes the medians for each year in the file. It prints the median, 95th, and 5th percentile for each year in the dataset. These values are present in the medians file in this repository.

Craigslist

To get the Craigslist data, open the SF rentals page, select all and copy/paste the page's contents into a text file. Keep copying every page into the same text file until done. Save this file as craigslist-YYYY-MM.

All Craigslist files should be combined into one per year, via eg:

cat craigslist-2019-* > craigslist-2019

After pulling in new data, recalculate the medians:

./calc-medians > medians

More Repositories

1

if-then-else

!!Con West 2019 talk
349
star
2

datamaps

Indexes points and lines and generates map tiles to display them
C
335
star
3

geotools

Tools for working with geographic data
C
87
star
4

tile-stitch

Stitch together and crop map tiles for a specified bounding box
C
87
star
5

ascii

History of ASCII and its predecessors
PostScript
31
star
6

twitter-oauth

Tiny program to make the Authorization header for the Twitter streaming API
C
19
star
7

json-pull

Streaming pull parser for JSON in C
C
14
star
8

twitter-json

The mess I am using to parse Twitter JSON
Java
13
star
9

geotaggers

The Geotaggers' World Atlas
CartoCSS
12
star
10

osm-tiger-update

A tool for updating OpenStreetMap with changes that have been made to the US Census TIGER maps since 2006.
C
10
star
11

osm-animate

Animation of OSM mapping activity
C
8
star
12

junix

Unix as if JSON mattered
C
7
star
13

ed

Ed is the standard text editor
C
7
star
14

gpx-layer

Tools to turn GPX files into a GPS map tracing layer
Perl
7
star
15

la-traffic-counts

Extracting Los Angeles's traffic counts from published PDF files
HTML
6
star
16

apple2-converters

Programs I wrote many years ago to convert Apple II binary file formats to things that are usable on current systems
C
4
star
17

cat

Implementations of cat(1) in different languages
JavaScript
4
star
18

colorwheel

Make a key for the datamaps color wheel
JavaScript
4
star
19

ridership-model

Predicting BART ridership from LEHD origin-destination pairs
Perl
4
star
20

snap-carriageways

Try to snap GPS logs to directional carriageways without the help of a base map
C
4
star
21

v6man

Unix Sixth Edition manual
Roff
3
star
22

unixio

Asynchronous buffered I/O for Node in the Unix style
JavaScript
3
star
23

srtm-elevation

Making an image out of the SRTM digital elevation model
C
3
star
24

high-injury

Chopping roads up into blocks in the manner of SFMTA's high injury streets analysis
Python
3
star
25

lzss

Standard and readable implementations of LZSS compression
C
3
star
26

daily-traffic-counts

Daily pedestrian/bike/vehicle counts and correlations with other data sets
Perl
3
star
27

gpx-import

Fork of http://git.openstreetmap.org/gpx-import.git/
C
3
star
28

tlid-ways

Mapping from TIGER TLIDs to OpenStreetMap ways
3
star
29

trafficways

HTML code that I used on trafficways.org
JavaScript
3
star
30

learning-to-program

How I learned to program
C
3
star
31

trump-tweets

Archive of Trump's old tweets
HTML
2
star
32

ttyedit

Code from 1999 Usenix paper "New Tricks for an Old Terminal Driver"
C
2
star
33

cart

Cart cartogram tool from http://www-personal.umich.edu/~mejn/cart/
C
2
star
34

mkpw

Generate line noise passwords
C
2
star
35

vector-subtract

C
2
star
36

macbinary

Extract the data forks from old Macintosh MacBinary II (.bin) files
C
2
star
37

srtm-gridded-vector

Make vector tiles of SRTM elevation data
C++
2
star
38

posix-multibyte-tests

Things that might go wrong with multibyte characters in Unix shell tools
Shell
2
star
39

tippecanoe-protomaps

protomaps fork of tippecanoe - build big vector tilesets of thematic data
C++
2
star
40

vancouver-traffic-counts

Extracting Vancouver's traffic counts from the published HTML files
HTML
2
star
41

fantasy-transit

Making fantasy transit maps
C++
2
star
42

map-overlay

The society for putting maps on top of other maps
JavaScript
2
star
43

osm-snap

Flatten ways from OpenStreetMap XML to datamaps format
C
1
star
44

tide

Perl
1
star
45

bresenham-snap-rounding

C++
1
star
46

jstr

If <string.h> did JSON
C
1
star
47

chromium-compact-language-detector

Fork of an old revision of https://code.google.com/p/chromium-compact-language-detector/
C++
1
star
48

triangle-cartogram

Trying to flatten triangular meshes
C++
1
star
49

coreutils

Fork of https://git.savannah.gnu.org/git/coreutils.git. New work is in the "multibyte-squash" branch
C
1
star
50

midi-key-guesser

Guess the key of a piece of music from its MIDI file
C++
1
star
51

indent

Patch to GNU indent
C
1
star
52

ebola

Recent edits
Perl
1
star
53

gnu-coding-standards

Revisions of the GNU Coding Standards from the 1990s
1
star
54

see-something

The code that I used to make the "See something or say something" maps
C
1
star
55

hilbert

Draw a Hilbert curve
C
1
star
56

wispy

Wispy Maps
C
1
star
57

bart-station-profile-study

Trips to BART station by mode extracted from the 2008 Station Profile Study
Perl
1
star
58

twitter-usenet

Turning tweets into Usenet articles
JavaScript
1
star
59

multidimensional-scaling

Terrible, terrible code for multidimensional scaling. Please don't try to use this mess.
JavaScript
1
star
60

pedestrian-volume-model

Perl
1
star
61

sf-traffic-counts

Traffic counts from San Francisco Municipal Transportation Agency
Perl
1
star
62

dlib-face

Command-line tools for dlib's face recognition library
C++
1
star
63

la-subway-ridership

Los Angeles subway ridership by station
Perl
1
star
64

read-speed

How fast can you read data from different types of media?
C
1
star
65

check-one-way

Check GPS traces against OSM ways to find the ones with wrong one-way tagging
Perl
1
star
66

tiger-test

US Census TIGER as GeoJSON
1
star
67

nyc-traffic-counts

Traffic counts from New York City
Perl
1
star