Categories
Data

OSMnx and Street Network Elevation Data

Check out the journal article about OSMnx.

OSMnx can now download street network elevation data for anywhere in the world. In one line of code it downloads the elevation in meters of each network node, and in one more line of code it can calculate every street (i.e., edge) grade. Here is the complete street network of San Francisco, California, with nodes colored according to their elevation:

OSMnx street network elevation data for San Francisco, California to calculate street grade and steepness

Categories
Planning

Urban Form Figure-Ground Diagrams

Check out the journal article about OSMnx.

I previously demonstrated how to create figure-groundĀ square-mile visualizations of urban street networks with OSMnx to consistently compare city patterns, design paradigms, and connectivity. OSMnx downloads, analyzes, and visualizes street networks from OpenStreetMap but it can also getĀ building footprints. If we mash-up these building footprints with the street networks, we get a fascinating comparative window into urban form:

Figure-ground map of building footprints and street network in New York, San Francisco, Monrovia, and Port au Prince from OpenStreetMap data, created in Python with OSMnx

Categories
Planning

Square-Mile Street Network Visualization

Check out the journal article about OSMnx. All figures in this article come from this journal article, which you can read/cite for more.

The heart of Allan Jacobs’ classic book on street-level urban form and design, Great Streets, features dozens of hand-drawn figure-ground diagrams in the style of Nolli maps. Each depicts one square mile of a city’s street network. Drawing these cities at the same scale provides a revealing spatial objectivity in visually comparing their street networks and urban forms.

We can recreate these visualizations automatically with Python and the OSMnx package, which I developed as part of my dissertation. With OSMnx we can download a street network from OpenStreetMap for anywhere in the world in just one line of code. Here are the square-mile diagrams of Portland, San Francisco, Irvine, and Rome created and plotted automatically by OSMnx:

OSMnx: Figure-ground diagrams of one square mile of Portland, San Francisco, Irvine, and Rome shows the street network, urban form, and urban design in these cities

Categories
Data

Animating the Lorenz Attractor with Python

Edward Lorenz, the father of chaos theory, once described chaos as ā€œwhen the present determines the future, but the approximate present does not approximately determine the future.ā€

Lorenz first discovered chaos by accident while developing a simple mathematical model of atmospheric convection, using three ordinary differential equations. He found that nearly indistinguishable initial conditions could produce completely divergent outcomes, rendering weather prediction impossible beyond a time horizon of about a fortnight.

Lorenz system attractor animated GIF created with Python matplotlib scipy numpy PIL

Categories
Planning

OSMnx: Python for Street Networks

OSMnx: New York City urban street network visualized and analyzed with Python and OpenStreetMap dataIf you use OSMnx in your work, please cite the journal article.

OSMnx is a Python package to retrieve, model, analyze, and visualize street networks from OpenStreetMap. Users can download and model walkable, drivable, or bikeable urban networks with a single line of Python code, and then easily analyze and visualize them. You can just as easily download and work with amenities/points of interest, building footprints, elevation data, street bearings/orientations, and network routing. If you use OSMnx in your work, please download/cite the paper here.

In a single line of code, OSMnx lets you download, model, and visualize the street network for, say, Modena Italy:

import osmnx as ox
ox.plot_graph(ox.graph_from_place('Modena, Italy'))

OSMnx: Modena Italy networkx street network in Python from OpenStreetMap

Categories
Planning

Urban Design and Complexity

Corbusier Paris planI am presenting at the 2015 Conference on Complex Systems tomorrow in Tempe, Arizona. My paper is on methods for assessing the complexity of urban design. If you’re attending the conference, come on by!

Here’s the paper.

Here’s the abstract:

Categories
Data

Animated 3-D Plots in Python

Download/cite the paper here!

In a previous post, I discussed chaos, fractals, and strange attractors. I also showed how to visualize them with static 3-D plots. Here, I’ll demonstrate how to create theseĀ animated visualizations using Python and matplotlib. All of my source code is available in this GitHub repo. ByĀ the end, we’ll produce animated data visualizations like this, in pure Python:

Animated 3-D Poincare plot of the logistic map's chaotic regime - this is time series data embedded in three dimensional state space

Categories
Data

Visualizing Chaos and Randomness

3-D Poincare plot of the logistic map's chaotic regime - this is time series data embedded in three dimensional state space

Download/cite the paper here!

In a previous post, I discussed chaos theory, fractals, and strange attractors – and their implications for knowledge and prediction of systems. I also briefly touched on how phase diagrams (orĀ PoincarĆ©Ā plots)Ā canĀ help us visualize system attractors and differentiate chaotic behavior from true randomness.

In this post (adapted from this paper), I provide more detail on constructing and interpreting phase diagrams. These methods are particularly useful for discovering deterministic chaos in otherwise random-appearing time series data, as they visualize strange attractors. I’m using Python forĀ all of these visualizations and the source code is available in thisĀ GitHub repo.

Categories
Data

Chaos Theory and the Logistic Map

Logistic map bifurcation diagram showing the period-doubling path to chaosUsing Python to visualize chaos, fractals, and self-similarity to better understand the limits of knowledge and prediction. Download/cite the articleĀ hereĀ and try pynamical yourself.

Chaos theory is a branch of mathematics that deals with nonlinear dynamical systems. A system is just a set of interacting components that form a larger whole. Nonlinear means that due to feedback or multiplicative effects between the components, theĀ wholeĀ becomes something greater than just adding up the individual parts. Lastly, dynamical means the system changes over time based on its current state. In the following piece (adapted from this article),Ā I break down some of this jargon, visualize interesting characteristics of chaos, and discuss its implications for knowledge and prediction.

Chaotic systems areĀ a simple sub-type of nonlinear dynamical systems. TheyĀ may contain very few interacting parts and these may follow very simple rules, but these systems all have a veryĀ sensitive dependence on their initialĀ conditions. DespiteĀ their deterministic simplicity, over time these systems can produce totally unpredictable and wildly divergent (aka, chaotic) behavior.Ā Edward Lorenz,Ā the father ofĀ chaos theory,Ā described chaos as “when the present determines the future, but the approximate present does not approximately determine the future.”

Categories
Planning

LEED-ND and Neighborhood Livability

I recently co-authored a journal article titled LEED-ND and Livability Revisited,Ā which won the Kaye Bock award.Ā LEED-ND is a system for evaluating neighborhood design that was developed by CNU, USGBC, and NRDC.Ā Many of its criteria, particularly site location and neighborhood pattern, accordingly reflect New Urbanist and Smart Growth principles and are inspired by traditional neighborhood design.