Yap Ching Loong Ian
2 Apr 2017
startHrOfInterest <- 8.5 # Use 8:30 AM as an example
## Read bike station data
load("bike.RData")
# Loads
# 1. flowCountList: a list of dataframes, each containing the statistics for each bike station ID for each period
# 2. bikeStationDf: Dataframe containing lat/lon, name and ID of the bike stations
plotStationDf <- flowCountList[[as.character(startHrOfInterest)]] %>%
dplyr::mutate(lat = bikeStationDf$station.latitude,
lon = bikeStationDf$station.longitude,
name = bikeStationDf$station.name)
arrange(plotStationDf, desc(turnover)) %>%
head(4)
station.id hour inCount outCount netOutflow turnover lat lon
1 519 8.5 33 53 20 86 40.75187 -73.97771
2 426 8.5 61 22 -39 83 40.71755 -74.01322
3 359 8.5 41 22 -19 63 40.75510 -73.97499
4 3263 8.5 21 40 19 61 40.72924 -73.99087
name
1 Pershing Square North
2 West St & Chambers St
3 E 47 St & Park Ave
4 Cooper Square & E 7 St