Bike sharing in 100 cities

[This article was first published on Revolutions, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

Many cities around the world have bike sharing programs: pick up a bike at a docking station, ride it across town and drop it off at another session, and just pay for the time you use. (Even Albacete, the Spanish college down hosting last month's UseR conference, had one.) Most of these systems provide open data feeds of bike availability, and the data is available for all cities via the CityBikes API. Ramnath Vaidyanathan used this API to create an on-line application showing the real-time status of bike availability in over 100 cities. Here's London, for example:

London bikes

Red dots indicate bikeshare stations with zero available bikes; green dots show stations with the most availability. (I took the snapshot above around midnight London time: it looks like all the city-center bikes have been taken to the outlying stations by commuters, and the overnight redistribution hasn't yet taken place.)

Ramnath used an R language script to download the data from the JSON API (using the httr package), and created the maps using the rCharts packages (which provides an interface to Leaflet maps). The interactive application, with city selection, pan and zoom, and pop-up detail for each station, was created using RStudio's Shiny package for R. It's easy to imagine other applications for this data, for example using statistical forecasting to optimize the overnight redistribution, or to determine the most popular bike routes in a city.

Click the map above to play around with the application yourself, or follow the link below for more details from Ramnath on how the application was created.

Ramnath Vaidyanathan: Visualizing Bike Sharing Networks

To leave a comment for the author, please follow the link and comment on their blog: Revolutions.

R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)