Category: Information

Finding a new way to measure cities’ bike friendliness in the United States

A really smart person could come up with a way to measure day-to-day bike friendliness based on how well cities adhere to standards that keep roads clear of obstructions that further frustrate the commute, like construction projects that squeeze bikes and cars together. 

I work at home. There are some days when I only leave my house to get milk from the Mexican grocery store at the end of my block (which makes awesome burritos). That means I ride my bike half as much as people who commute to work. on their bikes. Today I had a bunch of errands to run: drop off stuff, buy stuff, take pictures of stuff for my blog, Grid Chicago.

It was a very frustrating experience. I don’t need to go into details about how I was harassed by people who the state so graciously awarded a license to drive. But it happened. And it happens a hundred times a day to people cycle commuting in Chicago. I got to thinking about “bike friendly” cities. Is there a way to incorporate driver attitudes in there? I tweeted:

[tweet_embed id=264575958374305792]

Later I had the idea to use some very simple but objective measurements to create a new bike friendliness metric. It would help ensure that “Silver” (a ranking the League of American Bicyclists [LAB] uses) in one city means the same as “Silver”. It can expand from here but basically it works like this:

  • The share of people going to work who go by bike is a proxy for how “friendly” a city is to biking.
  • If a city has a lot of people biking to work, it must be friendly.
  • If a city has a few people biking to work, it must be non-friendly.
  • Cities are compared to each other to determine friendly and non-friendly.
  • The metric uses standard deviation to score cities.

Stop me if this has already been done.

I created a spreadsheet that lists the top 10 populous cities in the United States. I then added 10 more cities: Austin, Boston, Davis, Madison, Minneapolis, Portland, San Francisco, Seattle, and Washington, D.C. In the next column I listed their bike commute share from the American Community Survey 2006-2010 5-year estimates. I calculated the standard deviation and mean of these shares and then in another column used Apple Numbers’s STANDARDIZE function:

The STANDARDIZE function returns a normalized value from a distribution characterized by a given mean and standard deviation.

I think that’s what I want. And the output is close to what I expected. I then found the LAB ranking for each city and found the variance of each ranking to see how far apart each city within one ranking was from another city in the same ranking. The results were interesting: the higher the ranking, the more variance there was.

Hurricane Sandy prompted a lot of New Yorkers to bike. It made headlines, even. Photo by Doug Gordon. 

I wanted to add another metric of bike friendliness, and that’s density. To me, a higher density of people would mean a higher density of places to go (shop, eat, learn, enjoy) and friends and family would be closer, too. Or the possibility of meeting new people nearby would be higher. Yeah, I’m making a lot of assumptions here. So I applied the STANDARDIZE function there as well. I added this number to the previous STANDARDIZE result and that became the city’s score.

So, in this new, weird ranking system, the most bicycle friendly cities are…drum roll please…

  1. Davis, California (Platinum)
  2. New York City (Silver) *
  3. San Francisco (Gold) *
  4. Boulder (Platinum)
  5. Boston (Silver)
  6. Philadelphia (Silver)
  7. Tie: Chicago*, Washington, D.C. (Silver)
  8. Tie: Portland* (Platinum), Minneapolis* (Gold)

Remember, I said above that any author of a list should spend at least a day cycling in each city. I’ve starred the cities where I’ve done that – I’ve cycled in 5 cities for at least a day.

I only calculated 20 cities. Ideally I’d calculate it for the top 50 most populous cities AND for every city that’s been ranked by LAB.

LAB cities list (PDF). My spreadsheet (XLS).

Tell it, Sue Baker! Car crashes are not accidents

“It was an accident!”, said the driver. Photo by Katherine Hodges. 

Because of Hurricane Sandy, the New York Times paywall is down so I’m reading every article I can, starting with “Safety Lessons from the Morgue“:

As she explains it, “To say that a car crash is an accident is to say it’s a matter of chance, a surprise, but car crashes happen all the time, and the injuries that people sustain in those crashes are usually predictable and preventable.”

Another car crash-related excerpt from the article about Sue Baker, injury prevention researcher extraordinaire:

In one of her recent projects, Baker looked at another aspect of highway deaths. The study, which Baker prepared with David Swedler, a doctoral candidate, examined more than 14,000 fatal crashes involving teenage drivers. They found that male drivers were almost twice as likely as female drivers to have had high levels of alcohol in their blood and were also more likely to have been speeding and driving recklessly. Significantly, 38 percent of 15-year-old drivers, both male and female, were found to have been speeding, but by age 19, female speeders dropped to 22 percent, while male speeders remained steady at 38 percent.

Those differences, Baker says, suggest that boys and girls should not automatically receive the same driver training — and that boys should perhaps receive their license at an older age than girls. “Males might scream foul,” Baker acknowledges, “but let them.”

Yes, let them. It’s too easy to get a driver’s license in this country.  I love her style:

In 1979, at a Department of Transportation public hearing about the dangers faced by truck drivers, Baker angrily explained, “Isn’t it time we did some crash testing with trucks and dummies, rather than with drivers themselves?” Later, according to Baker, the trucking industry hired a researcher to try to discredit her driver-safety studies. Unable to uncover problems with her work, he eventually gave up and called to tell her about his assignment. [emphasis added]

Not everything is perfect with injury prevention studies, though.

In the mid-1970s, [Sam] Peltzman did research on highway fatalities that suggested that mandatory safety features like seat belts and padded dashboards actually encouraged people to drive less cautiously.

Tom Vanderbilt talked about that in “Traffic“, which is basically my favorite transportation book, even mentioning Mr. Peltzman. Flip to page 181 to read it. Vanderbilt lists all of the different labels for that behavior:

  • the Peltzman effect
  • risk homeostasis
  • risk compensation
  • offset hypothesis

He summarizes: “What they are saying, to crudely lump all of them together, is that we change our behavior in response to perceived risk, without even being aware that we are doing so”. But Sue has a response:

Baker acknowledges that there may be some individuals in cars with anti-lock brakes, for example, who may not apply the brakes as soon as they did with the old brakes. But she insists there is no evidence that better brakes or air bags have encouraged recklessness — that they have in fact saved many thousands of lives. “What concerns me,” she says, “is that these spurious arguments are used by companies to bolster their opposition to beneficial safety regulation.

I think it’s safe to say now that she’s a personal hero of mine. But way, there’s just one more thing!

As she talked about what still needed to be done, her voice was tinged with anger: “Buildings need to be designed so it’s not so easy to fall down stairs. All new homes should have sprinklers. Traffic lights should be timed for pedestrians, not to move as many cars as possible through an intersection.

Yep. Exactly what we don’t do. We make ’em wait. And wait. Without even telling people the traffic signal’s even acknowledged their presence.

More

Links between pedestrian safety and crime

Chicago Pedestrian Plan

Safety item 20: Analyze the relationship between pedestrian safety and crime (download the plan)

The 2011 Chicago Pedestrian Crash Analysis identified a strong correlation between community areas with high numbers of pedestrian crashes and community areas with high crime rates. Correlation does not indicate causation and further study is necessary to understand this relationship and the potential broader benefits of pedestrian safety improvements. [From page 62 in the 2012 Chicago Pedestrian Plan.]

ACTIONS

Short Term

  • Identify and obtain funding for this study.
  • Identify a location for safety improvements and obtain data for the “before” conditions.

Mid Term

  • Design and implement pedestrian safety improvements.
  • Develop a pedestrian safety enforcement plan for the area for the duration of the project.
  • Analyze the effects on pedestrian safety and crime.

MILESTONES

  1. Initiate this study by 2013 and complete by 2015.

ADDITIONAL RESOURCES

National Highway Traffic Safety Administration. Data-Driven Approaches to Crime and Traffic Safety (DDACTS). 2011. [I don’t fully see the connection, but this reference was linked to a page on NYC Department of Transportation’s website.]

Pedestrian Crash Analysis

The summary report didn’t contain the word “crime”. The technical report contained 2 mentions, with an additional chart. They are quoted in the ordered list below. Download the summary report.

  1. In an examination of various factors including crime, income, race, language spoken, and Walk Score®, the strongest correlation found was between pedestrian crashes and crime
  2. Finally, crime statistics were compared to pedestrian crashes to determine if a correlation could be identified, using data from the Chicago Police Department (CPD) annual reports for 2005 through 2009. The annual reports include incidences of crime by Chicago Community Area (CCA). The statistics for the years 2005 through 2009 were averaged and compared to the aver- age number of fatal and serious injury pedestrian crashes over the same time period in each CCA. Of these factors, crime was the only variable that correlated to pedestrian crashes. Figure 1 shows the correlation between crime and pedestrian crashes was very high. However, there may be many variables responsible for this correlation.
  3. Figure 1: Crime vs. Fatal and Serious Injury Pedestrian Crashes by Chicago Community Area

Figure 1.

I have a few criticisms of this analysis: it lacks raw data; the data tables included in the technical report are of limited length, listing only the “top” items of any metric; the summary report lists many silly factoids; the maps are low resolution and of a limited scale – their design could be modified to improve their usefulness in communicating the crash frequencies of the marked locations. The analysis is reliable.

The technical report includes the state’s guide on how police officers are trained to fill out a crash report form. It also includes relevant crash reporting laws in Illinois. Download the technical report.

Special post for S.M.

How I created a map of Illinois Amtrak routes in TileMill in less than 30 minutes

This interactive map was created for a Grid Chicago article to show the cities and Amtrak routes mentioned. Click and drag it around or hover your mouse on the red train station markers. 

Want to create a map like that and publish it on your own website? It’s easy. I’ll show you how to do it in less than 30 minutes. First, download the following files:

All shapefiles are from the United States Department of Transportation, Bureau of Transportation Statistics’s National Transportation Atlas 2012 edition except for Illinois places, which comes from the Census Bureau’s TIGER project.

At the end of this tutorial, you’ll have a good introduction on how to find geographic data, build a map with TileMill, style the map, and publish it for the public. Your map will not look like mine as this tutorial doesn’t describe how to add labels or use the hover/info feature.

Tutorial to make Amtrak Illinois map

  1. Unzip the four ZIP files you downloaded and move their contents into a folder, like /Documents/GIS/Amtrak Illinois/shapefiles. This is your project folder.
  2. Install TileMill and open it.
  3. Set up a project. In the Projects pane, click “New Project”. In the filename field, title it “amtrak_illinois”. Ensure that the checkbox next to “Default data” is checked – this shows a world map and helps you get your bearings (but it’s not absolutely necessary).
  4. Get familiar with TileMill’s layout. Your new project will open with the map on the left side and your Carto style code on the right side. There are four buttons aligning the left edge of your map. From top to bottom they are: Templates, Font list, Carto guide, and Layers.
  5. Add a layer. We’re going to add the four shapefile layers you downloaded. Click the “Layers” button and then click “Add layer”. In the ID field, type in “amtrak_routes”. For Datasource, browse to your project folder and find “amtrak.shp” – this file has the Amtrak route lines. Then click “Done”. Click “Save & Style”.
  6. Style that layer. When you click “Save & Style” after adding a layer, your attention will be called to the Carto style code on the right side of TileMill. A section of code with the “amtrak_routes” #selector will have been inserted with some default colors and styles. If you know CSS, you will be familiar with how to change the Amtrak routes line styles. Change the “line-color” to “#000”. After “line-color”, add a new line and insert “line-opacity: 0.5;”. This will add some transparency to the line. Press the “Save” button above the code.
  7. Add remaining layers. Repeat Step 5 and add 3 more layers: “amtrk_sta.shp” (ID field: “amtrak_stations”), “state.shp” (ID field: “states”), and “tl_2012_17_place.shp” (ID field: “illinois_cities”).
  8. Hide bus stations. The Amtrak stations layer shows bus and ferry stations as part of Amtrak’s Thruway connections. You probably don’t want to show these. In your Carto style code, rename the #selector from “#amtrak_stations” to “#amtrak_stations[STNTYPE=’RAIL’]”. That makes the following style code only apply to stations with the “rail” type. Since there’s no style definition for things that aren’t of that type, they won’t appear.

Screenshot of my map.

Prepare your map for uploading

TileMill has many exporting options. You can save it as MBTiles and publish the map for free using MapBox (TileMill’s parent), or you can export it as image files (but it won’t be interactive), or you can display the map using the Leaflet JavaScript map library (which I use for the Chicago Bike Map app). This tutorial will explain how to export MBTiles and upload to MapBox, the server I’m using to display the map at the top of this page.

  1. Change project settings. To upload to MapBox, you’ll have to export your project as MBTiles, a proprietary format. Click the “Export” button above your Carto style code and click “MBTiles”. You’ll be asked to provide a name, description, attribution, and version. Input appropriate text for all but version.
  2. Adjust the zoom levels. Adjust the number of zoom levels you want (the more you have the longer it takes to export and upload your project, and you might exceed MapBox’s free 50 MB account limit). My map has zoom levels 8-11.
  3. Adjust the bounds. You’ll then want to draw your bounds: how much of the map’s geographic extents you want to export. Zoom to a level where you can see the entire state of Illinois in your map. Hold down the Shift key and drag a box around the state, plus a buffer (so viewers don’t fall of your map when they pan to the edges).
  4. Export your map. Click Export and watch the progress! On a four-year-old MacBook it took less than one minute to export the project.
  5. Bring the export to your project folder. When export finishes, click the “Save” button and browse to your project folder. Click the file browser’s save button.
  6. Upload to MapBox. Login to MapBox’s website and click “Upload Layer”. Browse to your project folder, select the .mbtiles folder, and click “Upload file”. Upon a successful upload, your map will display.
  7. Embed it in your website. Click the “Share” button in the upper left corner of your map and copy the embed code. Paste this into the HTML source code of a webpage (or in a WordPress post) and save that (I’m not going to provide instructions on how to do that).

Now you know how to find geographic data, build a custom map using the TileMill application, begin to understand how to style it, and embed your map for the public on a website or blog.

N.B. I was originally going to use QGIS to build a map and then publish a static image before I realized that TileMill + MapBox (the website) can build a map but publish an interactive feature instead of a static image. I’m happy I went that route. However, I did use QGIS to verify the data and even create a new shapefile of just a few of the key train stations on the Lincoln Service (the centerpiece of my Grid Chicago article).

The new term for #robotcar journalism is COWARDD

#robotcar: A journalistic writing style that anthropomorphizes automobiles or hides the fact that a human was operating an automobile involved in a crash.

The new term:
COWARDD, or (C)hoosing (O)bscuring (W)ords (A)bsolves (R)esponsibility of (D)eadly (D)riving.

Thank you to Gary Kavanagh for devising it.

For examples of #robotcar, see these articles on Grid Chicago.