Example code for chapter five, Clojure for Data Science.
Data sourced from the IRS on 2012 US Zip code AGI statistics for all zip codes (12zpallagi.csv). The Statistics of Income (SOI) division bases its ZIP code data on administrative records of individual income tax returns (Forms 1040) from the Internal Revenue Service (IRS) Individual Master File (IMF) system. More information is available here.
The data can be downloaded directly from here.
Run the following command-line script to download the data to the project's data directory:
# Downloads and unzips the data files into this project's data directory.
script/download-data.sh
- Download 12zpallagi.csv into this project's data directory using the link above
- Rename the file 12zpallagi.csv to soi.csv
Examples can be run with:
# Replace 5.1 with the example you want to run:
lein run -e 5.1
or open an interactive REPL with:
lein repl
Copyright © 2015 Henry Garner
Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.