|
|
# Visualization of Bike Sharing Data
|
|
|
The goal of the small project is visualize given data sets of bike sharing in London. You will learn
|
|
|
|
|
|
* how to prepare the data for a spatio-temporal visualization
|
|
|
* how to select a visualization framework based on given requirements
|
|
|
* how to apply standard visualization techniques
|
|
|
|
|
|
## The data
|
|
|
Transport for London (TfL) has published many data sets on public transport in London as Open Data here:
|
|
|
https://tfl.gov.uk/info-for/open-data-users/our-open-data?intcmp=3671#on-this-page-5
|
|
|
|
|
|
It includes data sets of the Bike Rental system (Santander Cycle) in London: https://tfl.gov.uk/modes/cycling/santander-cycles. In this small project, the Cycle Hire Trip data will be visualized.
|
|
|
|
|
|
The Cycle Hire Trip data includes:
|
|
|
* A unique Journey ID (Data Type Integer)
|
|
|
* Duration of the trip in seconds (Data Type Integer)
|
|
|
* A unique Bike ID (Data Type Integer)
|
|
|
* End date and time (Data Type Date / Time)
|
|
|
* End docking station ID (Data Type Integer)
|
|
|
* End docking station (Data Type String)
|
|
|
* Start date and time (Data Type Date / Time)
|
|
|
* Start docking station ID (Data Type Integer)
|
|
|
* Start docking station (Data Type String)
|
|
|
|
|
|
Example:
|
|
|
line in CSV file: 50754225,240,11834,10/01/2016 00:04,383,"Frith Street, Soho",10/01/2016 00:00,18,"Drury Lane, Covent Garden"
|
|
|
|
|
|
* A unique Journey ID: 50754225
|
|
|
* Duration of the trip in seconds: 240
|
|
|
* A unique Bike ID: 11834
|
|
|
* End date and time: 10/01/2016 00:04
|
|
|
* End docking station ID: 383
|
|
|
* End docking station: "Frith Street, Soho"
|
|
|
* Start date and time: 10/01/2016 00:00
|
|
|
* Start docking station ID: 18
|
|
|
* Start docking station: "Drury Lane, Covent Garden"
|
|
|
|
|
|
Data for all Santander Cycle Hire journeys by week since September 2015 can be found at cycling.data.tfl.gov.uk. In this example, the data from the file `01aJourneyDataExtract10Jan16-23Jan16.csv` will be used.
|
|
|
|
|
|
The location of the docking stations can be retrieved from a REST API. The API can be tested here: https://api.tfl.gov.uk/swagger/ui/index.html?url=/swagger/docs/v1#!/BikePoint/BikePoint_Search
|
|
|
|
|
|
Example: the following request URL searches for the docking station "Frith Street, Soho":
|
|
|
|
|
|
```javascript
|
|
|
https://api.tfl.gov.uk/BikePoint/Search?query=frith%20street%2C%20Soho
|
|
|
|
|
|
```
|
|
|
The Response contains the coordinates of the docking station using JSON.
|
|
|
|
|
|
```javascript
|
|
|
[
|
|
|
{
|
|
|
"$type": "Tfl.Api.Presentation.Entities.Place, Tfl.Api.Presentation.Entities",
|
|
|
"id": "BikePoints_383",
|
|
|
"url": "/Place/BikePoints_383",
|
|
|
"commonName": "Frith Street, Soho",
|
|
|
"placeType": "BikePoint",
|
|
|
"additionalProperties": [],
|
|
|
"children": [],
|
|
|
"childrenUrls": [],
|
|
|
"lat": 51.513103,
|
|
|
"lon": -0.131213
|
|
|
}
|
|
|
]
|
|
|
|
|
|
```
|
|
|
|
|
|
Additional information icluding number of bikes, and number of docks can be queried by the docking station ID. As the ID is given in the trip data set, no need to search for the docking station, it can be queried by ID:
|
|
|
|
|
|
```javascript
|
|
|
https://api.tfl.gov.uk/Place/BikePoints_383
|
|
|
```
|
|
|
|
|
|
## Visualization Requirements
|
|
|
The data set can be used to support several use cases:
|
|
|
|
|
|
From customers point of view:
|
|
|
* search for a docking station to rent a bike
|
|
|
* search for a docking station to deliver a bike
|
|
|
|
|
|
From data analysts / traffic planners point fo view:
|
|
|
* visually analyse the traffic flow of a day / week
|
|
|
* track empty docking stations
|
|
|
* visually analyse frequently used docking stations / journeys
|
|
|
|
|
|
An example of a map to search for docking stations can be found at https://tfl.gov.uk/modes/cycling/santander-cycles. The implementation uses GoogleMaps API. The map visualizes each docking station as a bike symbol surrounded with a red circle.
|
|
|
|
|
|
![DockingStation-1](/uploads/d9319e8bcc7fdb024fd87af1813dc502/DockingStation-1.png)
|
|
|
|
|
|
If the user searches for a specific station by name, the map is zoomed to that station, and the circle shows the number of bikes available at the docking station. If the user clicks on the symbol, the free and empty docks are displayed in an "array" style (simplified bar chart, value 0 or 1 per dock).
|
|
|
|
|
|
![DockingStation-2](/uploads/fabd1e9e50110b02d4204ed9f013f89f/DockingStation-2.png)
|
|
|
|
|
|
In this project, we will focus on the journey data visualization to get a better insight of the use of the bike sharing system. As a visualization platform, the 3D globe Cesium will be used. Cesium has a very good support on time dependend data visualization which helps a lot. And inaddition, it allows to explore the possibilies of combining the routing data and a 3D city model later on.
|
|
|
|
|
|
[Part 2: Cesium Fundamentals](./cesium-fundamentals)
|
|
|
|
|
|
## References and Inspiration
|
|
|
|
|
|
* https://uclab.fh-potsdam.de/cf/
|
|
|
* Wood, J., Slingsby, A. & Dykes, J. (2011). Visualizing the dynamics of London's bicycle hire
|
|
|
scheme. Cartographica, 46(4), pp. 239-251, online available at: http://openaccess.city.ac.uk/538/1/wood_visualizing_2011.pdf
|
|
|
* http://www.economist.com/blogs/graphicdetail/2012/09/visualising-bicycle-trips
|
|
|
* http://oobrien.com/2010/08/london-cycle-hire-visualisation/ |