All Projects → Chicago → osd-building-footprints

Chicago / osd-building-footprints

Licence: MIT license
Open source release of building footprints in Chicago.

Programming Languages

r
7636 projects
ruby
36898 projects - #4 most used programming language
python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to osd-building-footprints

dev.cityofchicago.org
Developer resources provided by the City of Chicago and sister agencies and get technical updates from the developer blog.
Stars: ✭ 22 (-63.93%)
Mutual labels:  government, chicago
Open Data Etl Utility Kit
Use Pentaho's open source data integration tool (Kettle) to create Extract-Transform-Load (ETL) processes to update a Socrata open data portal. Documentation is available at http://open-data-etl-utility-kit.readthedocs.io/en/stable
Stars: ✭ 93 (+52.46%)
Mutual labels:  government, open-data
Decidim
The participatory democracy framework. A generator and multiple gems made with Ruby on Rails
Stars: ✭ 894 (+1365.57%)
Mutual labels:  government, open-data
311
New web portal for BOS:311
Stars: ✭ 15 (-75.41%)
Mutual labels:  government, open-data
Rsocrata
Provides easier interaction with Socrata open data portals http://dev.socrata.com. Users can provide a 'Socrata' data set resource URL, or a 'Socrata' Open Data API (SoDA) web query, or a 'Socrata' "human-friendly" URL, returns an R data frame. Converts dates to 'POSIX' format. Manages throttling by 'Socrata'.
Stars: ✭ 182 (+198.36%)
Mutual labels:  government, open-data
Atd Data And Performance
Open data and performance hub for the City of Austin Transportation Department
Stars: ✭ 17 (-72.13%)
Mutual labels:  government, open-data
Openpolice Platform
An open source web publishing platform for police forces.
Stars: ✭ 15 (-75.41%)
Mutual labels:  government, open-data
Osd Street Center Line
Open source release of street center lines in Chicago.
Stars: ✭ 108 (+77.05%)
Mutual labels:  government, open-data
Data.gov
Data.gov source code and issue tracker
Stars: ✭ 1,856 (+2942.62%)
Mutual labels:  government, open-data
Osd Bike Routes
Open source release of bike routes in Chicago.
Stars: ✭ 140 (+129.51%)
Mutual labels:  government, open-data
CityScoreToolkit
Open-source version of Boston's CityScore performance dashboard
Stars: ✭ 42 (-31.15%)
Mutual labels:  government, open-data
clear-water
Forecasting elevated levels of E. coli at Chicago beaches to provide proper warning to beach-goers.
Stars: ✭ 54 (-11.48%)
Mutual labels:  government, chicago
Forms
Tracking our progress moving all city paper and pdf forms online.
Stars: ✭ 14 (-77.05%)
Mutual labels:  government, open-data
IATI.cloud
The open-source IATI datastore for IATI data with RESTful web API providing XML, JSON, CSV output. It extracts and parses IATI XML files referenced in the IATI Registry and powered by Apache Solr.
Stars: ✭ 35 (-42.62%)
Mutual labels:  open-data
congresso em chamas
Congresso em chamas é uma aplicação web que entrega ferramentas para o acompanhamento do trabalho dos deputados federais atualmente em mandato.
Stars: ✭ 20 (-67.21%)
Mutual labels:  open-data
CASS
Competency and Skills System
Stars: ✭ 42 (-31.15%)
Mutual labels:  open-data
linkedresearch.org
🌐 linkedresearch.org
Stars: ✭ 32 (-47.54%)
Mutual labels:  open-data
modern-software-delivery-maturity-index
A resource to help teams evaluate and improve their software delivery.
Stars: ✭ 15 (-75.41%)
Mutual labels:  government
restatapi
An R package to search and retrieve data from Eurostat database using SDMX
Stars: ✭ 14 (-77.05%)
Mutual labels:  open-data
opendata
Finland national open data portal (avoindata.fi) source code.
Stars: ✭ 27 (-55.74%)
Mutual labels:  open-data

README

CAUTION! This repository is very large

The City of Chicago is releasing selected datasets from the data portal under the MIT License (see below). This repository contains:

  1. Data in a GeoJSON format.
  2. Examples of importing data into R, Python, and Ruby.
  3. Instructions to transform data from the data portal to data in the repository.

Working with GeoJSON Data

The data was released as a GeoJSON file. Below are some simple instructions which will show you how to load GeoJSON in R, Python, and Ruby.

R

Find an example script here. This example will import the data in R and create a couple of maps.

Instructions:

  1. Set the working directory to the location of the downloaded repository.

    setwd("path\\to\\osd-building-footprints")
  2. Install the "rgdal" library to let R read and translate the data from GeoJSON to a Shapefile. We will use "ggplot2" library to transform the spatial data frame to a regular data frame--and to make a map.

    install.packages(c("rgdal","ggplot2"))
  3. Load the libraries:

    library(rgdal)
    library(ggplot2)
  4. Import data to a spatial dataframe. City data is typically created using the transverse Mercator projection.

    ogrInfo("data\\Buildings.json", layer="OGRGeoJSON")
    buildings.shapefile <- readOGR(dsn="data\\Buildings.json", layer="OGRGeoJSON", p4s="+proj=tmerc +ellps=WGS84")
  5. Lets convert the spatial dataframe to a typical dataframe.

    buildings.table <- fortify(buildings.shapefile)
  6. Review the new dataframe.

    head(buildings.table)
  7. Plot the data.

    ggplot(buildings.table, aes(x=long, y=lat, group=group)) + geom_polygon()

Here is the output you should expect from the plot() command: plot(buildings.shapefile)

Here is the output you should expect from the ggplot() command: ggplot(buildings.df, aes(x=long, y=lat, group=group))+geom_path()

Python

Find an example script here.

  1. Load the necessary json and pprint libraries.

    import json
  2. Open GeoJSON data file.

    buildings_json = open('PATH/TO/osd-building-footprints/data/Buildings.json', 'r')
  3. Check first few lines of data (repeat this command several times)

    buildings.readline()
  4. Load GeoJSON file.

    buildings = json.load(buildings_json)
  5. Close the open GeoJSON file.

    json.close(buildings_json)

Ruby

An example ruby script is provided to show loading GeoJSON and running spatial analysis using the RGeo suite. A simple Gemfile is provided to make getting the dependencies and using them easy.

    $ cd PATH/TO/osd-building-footprints/examples/ruby
    $ bundle
    $ ruby example.rb

This example script filters the Buildings.json to street segments within a 500ft buffer of 50 W Washington.

Differences between data portal and this repository

Though the data in this repository is also available on Chicago's data portal, the data in this repository is different in several ways. First, the data within this repository is released under the MIT License. Second, this data has been edited to remove internal codes which do not provide useful information. Third, after changes were made to the dataset, the original shapefile was converted to GeoJSON using GDAL's ogr2ogr

The translation from portal to repository involves several steps. First, the original DBF file is transformed using OpenRefine to elminate unhelpful columns and clean data. The "Transformatons" folder contains the corresponding JSON, which contains the detailed list of changes made to the original table.

The resulting shapefile is then translated to GeoJSON using the ogr2ogr from the GDAL application. The transformation is completed in the command prompt:

ogr2ogr -f "GeoJSON" Buildings_ogr.json /path/to/portal/data/Buildings.shp

Unfortunately, ogr2ogr outputs in machine, but not human-readable files. At this time, we have not translated this to a more human readable form due to the large file size.

The folder "Transformations" contains the necessary code to transform data on the portal to the release in this repository.

License

This data is released under the MIT License. See LICENSE.txt.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].