I'm trying to deduce the service codes of historic services from a limited set of information from a dataset I'm working on. The data I've got include:
- Date
- Operator
- Station stop
- Departure time from stop (scheduled)
- 4 digit headcode/train ID
For example:
- Saturday 8th July 2023
- Avanti
- Stafford
- 13:24
- 9A53
Is there an open datafeed/ Rail Data Marketplace dataset which would allow me to deduce the service code from this information?
I can use https://live.rail-record.co.uk/run-history/?headcode=9A53&a= to show me recent services with that headcode, which should allow me to isolate the Origin and Destination when cutting by Operator as well. The issues with this are:
a) I'm writing some code to try and automate this, as there's a lot of these and it will be updated a few times a year, so searching one-by-one isn't really feasible
b) It doesn't actually have the service code (although it's probably deducible from the OD pair, so maybe just an extra step)
c) I'd have to assume these headcodes are fairly static (i.e. the 9A53 which Avanti ran this week is the same service as the one which ran a year or so ago). Not sure how strong this assumption is. If they're mostly stable then that's fine.
Thanks in advance.
- Date
- Operator
- Station stop
- Departure time from stop (scheduled)
- 4 digit headcode/train ID
For example:
- Saturday 8th July 2023
- Avanti
- Stafford
- 13:24
- 9A53
Is there an open datafeed/ Rail Data Marketplace dataset which would allow me to deduce the service code from this information?
I can use https://live.rail-record.co.uk/run-history/?headcode=9A53&a= to show me recent services with that headcode, which should allow me to isolate the Origin and Destination when cutting by Operator as well. The issues with this are:
a) I'm writing some code to try and automate this, as there's a lot of these and it will be updated a few times a year, so searching one-by-one isn't really feasible
b) It doesn't actually have the service code (although it's probably deducible from the OD pair, so maybe just an extra step)
c) I'd have to assume these headcodes are fairly static (i.e. the 9A53 which Avanti ran this week is the same service as the one which ran a year or so ago). Not sure how strong this assumption is. If they're mostly stable then that's fine.
Thanks in advance.