Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bus Bunching #14

Open
DominikGroegler opened this issue Feb 1, 2017 · 12 comments
Open

Bus Bunching #14

DominikGroegler opened this issue Feb 1, 2017 · 12 comments

Comments

@DominikGroegler
Copy link

Bus bunching can be a consequence of traffic congestions, inoperable prioritisation of public transport vehicles or construction work on lines with small headway. Because headway is small, the delay of vehicles will influence each other: The delay of one vehicle will likely cause a delay of the following vehicles. This mechanism leads to an ongoing accumulation of delays.
Where, when in the course of a day and why does bus bunching occur?
Can bus bunching be predicted?

@HeidiSeibold
Copy link

This is an extremely complex question. There is a spacial component but also a time component.

Maybe it would be easiest to start with one bus line and one bus stop. Is there one line and one stop that is particularly interesting?

@DominikGroegler
Copy link
Author

Bus bunching occurs primarily during peak hours, 07:00 – 09:00 and 16:00 -19:00. A good point to start are these two bus lines:
Line 31: Hardplatz --> Farbhof and HB --> Hegibachplatz
Line 80: Bahnhof Altstetten --> Oerlikon Nord
In November 2016 there were a lot of occations of bus bunching, so it would be good to start analysing in that time period.

@HeidiSeibold
Copy link

Any stop that is particularly interesting?

@DominikGroegler
Copy link
Author

As a starting point one stop along the mentioned stops is as good as any other. However, bus bunching is a phenomenon that affects the complete line and not a particular stop. The aim for us (VBZ) is to find a way to control the traffic flow of a complete line, to make service more regular. Therefore, we should not focus on one particular stop, rather we have to look at all the stops e.g. from HB --> Hegibachplatz.

@krlmlr
Copy link

krlmlr commented Feb 18, 2017

I remember an article quoting that lines 32/61/62 are most susceptible to bus bunching.

What data are we going to use to understand why bus bunching occurs?

@HeidiSeibold
Copy link

@3lainess
Copy link

Are there data on construction projects, or traffic accidents? If we had these data, we might be able to examine possible relationships. It may be that bus bunching has other causes as well, but this could be helpful.

@HeidiSeibold
Copy link

@HeidiSeibold HeidiSeibold added model and removed model labels Feb 20, 2017
@3lainess
Copy link

Ok. Well that's cool. That could be a start. Could identify construction sites along the route of a particular bus, and then see if construction contributes to bunching. (Gross simplification, i know). Use a hold out sample to test the model. I guess I'd start with just one bus route to simplify things.

(I apologize for any lack of skill in githubbing - i'm just learning it). 🙄

@3lainess
Copy link

I downloaded the data. It's 49 large building projects, most over several months/years. There's a shapefile, it creates a layer to superimpose over a zurich street map.

@HeidiSeibold
Copy link

A starting point:

library("ggplot2")

source("https://raw.githubusercontent.com/OpenDataDayZurich2016/download_vbz_data/master/clean_delay_data.R")
source("https://raw.githubusercontent.com/OpenDataDayZurich2016/download_vbz_data/master/download_delay_data.R")

## load timeslots data.frame
timeslots <- read.csv(file = "data/delay_data/timeslots_files.csv", 
                      colClasses = c("factor", "POSIXct", "POSIXct", 
                                     "character", "character"))

## Download all available files !!! takes very long !!!
## If possible, take from USB stick
# source("download_delay_data.R")
# lapply(timeslots$from, download_delay_data, timeslots = timeslots)


## load data of given times
mydat <- import_clean_delaydata(from = as.POSIXlt("2016-01-03 00:00:00 CEST"),
                                to = as.POSIXlt("2016-01-15 24:00:00 CEST"),
                                which_info = "datetime_soll_an_von",
                                timeslots = timeslots)

## bus bunching line 80 at Glaubtenstrasse
bus80glau0 <- subset(mydat, linie == 80 & halt_kurz_von1 == "GLAU" & seq_von == 24)

## sort by ist_ab_von
bus80glau <- bus80glau0[order(bus80glau0$datetime_ist_ab_von), ]
bunched <- diff(bus80glau$datetime_ist_ab_von, differences = 1) < as.difftime(60, units = "secs")

@3lainess
Copy link

Thanks! So for example, you can genereate a list of stops, and compute deviation from scheduled time to see where bunching occurs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants