Bit of a repeat project but I focused on a short and simple route in Toronto called 125 Drewry.
I fetched the shape data from the official GTFS and plotted the 2 primary shapes (east and westbound below). You can basically ignore the axis labels - they are in meters east and north of a MTM meridian I think 17T. Also I shifted the one of them up by a bit to isolate them visually.
I took the realtime GPS feed from the TTC and fetched all gps updates for this route for a single day as plotted below. (includes dead mileage on the left)
This step is a bit of a leap but it visualizes the GPS coordinates translated from physical coordinates (in meters) to progress along the GTFS shapes length over time. Vertically stratified by individual vehicle to eliminate visual overlap.
And then I overlap to be able to visually compare with the GTFS schedule.
I fed all this data into a neural network to produce predictions of future performance to produce more accurate nextbus arrival times.
So I've been archiving ttc bus/streetcar GPS data since 2015 because I knew there's tremendous potential but I'm still really struggling to make good use of it. Well actually I was collecting and using before 2015 as well but I wasn't storing it - I only have archive data to 2015. I used it back in 2011 as part of myttc.ca. In 2014 I used it for this queen street comparison and also in 2015 I used it for this more detailed storm performance comparison. Later in 2015 I used it as part of our first place win at Traffic Jam - you know, no big deal. Then in 2020 I was taking the streetcar across the city so I decided to compare that gps with the TTCs reported data.
So after finding that the vertical projection I created previously was a bit hard to read - especially regarding the opposing direction lines overlapping like an X, I decided to try and project the data on a circle. Also the vertical graph doesn't work when the bus route follows a different returning path, in this case it works a++. Branching routes of course are still not supported. I have a live version in webgl here, if you can't view it (it might take a few seconds to load the data) then here is a screenshot of what it should look like. You can speed up time and increase the amount of time displayed - I call this constricting and dilating because it reminds me of a persons eyeball when they do drugs. Not that I have any knowledge of such things. (I don't but I've seen hollywood movies)
If you can believe it, webgl is a fair bit of work and difficult to quickly iterate on - so you know, I did that think where instead of just doing a bit more work, I rewrote it all from scratch in D3. I'm an idiot but hey I did it for you. Also this version has the actual route in the middle to better indicate what you're looking at. Oh, also I fed the GPS data into a neutral network to predict the future performance of the vehicle, that's displayed as a dotted line.