Script to visualize average race

The sport of kings.
Post Reply
dm1900
Posts: 71
Joined: Sun Jan 15, 2017 10:02 pm

Hi,

I was wondering if anyone had a complete set of "average" times for different distances/race types? I cannot find this anywhere, neither on Racing Post either :( Trawling through every track will take a billion years!

Thanks

EDIT: Script complete, please unzip the contents of the attachment into a directory and run the script as below. Thank you to firlandsfarm for the data.
Requirements: Python 2.x

Run the following command at your command prompt/terminal:

Code: Select all

racingtimer.py <distance> <racetype>
e.g.:

Code: Select all

racingtimer.py 5f turf
All the supported distance/racetypes are in the csv.

For example:
Image
You do not have the required permissions to view the files attached to this post.
Last edited by dm1900 on Thu Apr 27, 2017 3:33 pm, edited 2 times in total.
User avatar
firlandsfarm
Posts: 3335
Joined: Sat May 03, 2014 8:20 am

I can do that for you doovd ... later today or tomorrow if that's OK
User avatar
Frogmella
Posts: 245
Joined: Mon May 30, 2011 2:44 pm

Its between 12 and 15 seconds a furlong, varies by the weather(going)/type of race/quality of runners.

Another difficulty is that the average time of a race doesn't help you if you're trying to set rules to trigger, say 30 seconds out, because you need the the race BETTING duration and that can effectively be ended early by a run-away winner or faller. e.g. The other day a 3 mile race ( that should have taken about 6 minutes) effectively ended after about 30 seconds when one of the only two runners fell on its arse, betting over.
User avatar
firlandsfarm
Posts: 3335
Joined: Sat May 03, 2014 8:20 am

doovd, the first problem you have is not all race distances are equal! For example, take a 1 mile race ... at Wolerhampton it's run over 1 mile 100 yards but at Southwell it's exactly 1 mile, Nottingham could be 1 mile 54 yards or 1 mile 67 yards. Going the other way at Brighton it's likely to be 7f 214 yards and at Carlisle it could be 7f 200 yards. The greatest range is Chester at 7f 122 yards and the distance at Wolverhampton. So the distance of a 1 mile race could vary by a furlong! There are many other factors that could be considered but distance is probably the most obvious.

I am attaching a spreadsheet with 2 worksheets for downloading pages as follows (my data covers 20 years):

Summary: data is sorted by RaceType and distance rounded to the nearest furlong not actual distance (so 1 mile will cover all races from 7f 110yds to 1 mile 109yds). Also shows number of races the average time is based on.

Details: data is sorted by RaceType, then Course, then Actual Distance and then the date of the first race over the distance. The date of the last race is also shown so that you can see if a Course has changed the race distance over the years. Again the number of races the average time is based on is also shown.

I'll try and answer any questions but I'm not on this forum everyday so an answer may be delayed by a day or two.
AverageRaceTimes.xls
PS: I didn't notice the replies from Dallas and Frogmella when I made my post. Would just like to say I agree with them. Race class and going will also affect the time ... I suppose with a little experience you could have some adjustment factors like add X seconds if 'this' or delete Y seconds if 'that'
You do not have the required permissions to view the files attached to this post.
User avatar
ShaunWhite
Posts: 10526
Joined: Sat Sep 03, 2016 3:42 am

Thanks for sharing that firlansfarm, lots of work in that and very interesting.
StellaBot
Posts: 842
Joined: Thu Jan 26, 2017 11:52 am

Hi,
Regarding race distances and times.
I agree with a lot of above re distances,going,class etc.
However one major flaw if going back too far as I found out myself.
I have a spreadsheet(open office) with over 6000 race distances ,times and goings at uk and irish tracks.I omitted all weather in purpose.
However word of warning. Distances at uk tracks have been changed (which may include movement of winning post and and rail perimeter measured now.This in effect would skew calculations.
The original method of measuring distance Im sure was mid point of inner and outer rail around circumference. Therefore in wide courses compared to narrow courses and long distances there was big differences in advertised distance, so no standardisation
However the BHA has nearly all of the details at uk tracks.
Ths includes rail movements if any at each meeting and the estimated resulting change in distance.
http://www.britishhorseracing.com/press ... om-1-june/

http://www.britishhorseracing.com/press ... -13-april/

example result and rail movement from yesterday Ludlow
http://www.britishhorseracing.com/race- ... /2017/1126

Also Newmarket has Rowley and July courses.
Cheltenham has Old , New and Cross country
dm1900
Posts: 71
Joined: Sun Jan 15, 2017 10:02 pm

firlandsfarm wrote:
Tue Apr 25, 2017 5:16 pm
doovd, the first problem...
Dude thank you so much this is perfect. I just wanted to make a simple timer that can graphically show me roughly how much of the race is left and roughly where the horses would be on the track. I don't always watch the live stream but I'd like to know roughly if i am nearing the end of the race or whatever, so these times are absolutely perfect. I'm building a simple python script so you just type (for example):

Code: Select all

timer.py 1m4f Turf 
in your command prompt/terminal and it shows you a visualization of the average race of this distance.

Will post the script once I'm done, thanks all for the responses.
User avatar
firlandsfarm
Posts: 3335
Joined: Sat May 03, 2014 8:20 am

Stellabot, my spreadsheet shows all distances as declared for all courses and the first race and last race at that distance (last 20 years) so takes account of moved starts/winning posts and different courses (unless the distances over the different courses were exactly the same) but it cannot though take account of any change in how they measure the distance! :)
StellaBot
Posts: 842
Joined: Thu Jan 26, 2017 11:52 am

I appreciate Firlands farm what you are saying. I had a spreadsheet manually constructed similar to yours with info from racing post site when free. However All distances have been found debatable (see link below), especially the longer races.
Hence all UK tracks remeasured after below and rail postion included which would alter average times etc
https://www.roa.co.uk/en/news/index.cfm ... -distances

http://www.bbc.co.uk/sport/horse-racing/30040930

However for rough race time, should be nearish.
My updated times in my spreadsheet has almost every going at every distance to exact yards at each uk course and irish courses (without confirmed rail moves etc)
Last edited by StellaBot on Wed Apr 26, 2017 1:58 pm, edited 2 times in total.
dm1900
Posts: 71
Joined: Sun Jan 15, 2017 10:02 pm

Thanks all for your help,. I have posted the script in the original post.
StellaBot
Posts: 842
Joined: Thu Jan 26, 2017 11:52 am

I have heard races have been timed by a stop watch and some racing post times are well out.
So guesswork there occassionaly.
User avatar
ShaunWhite
Posts: 10526
Joined: Sat Sep 03, 2016 3:42 am

"Alexa, simulate the 3:15"
You do not have the required permissions to view the files attached to this post.
User avatar
jimibt
Posts: 4197
Joined: Mon Nov 30, 2015 6:42 pm

doovd wrote:
Tue Apr 25, 2017 1:03 pm
Hi,

I was wondering if anyone had a complete set of "average" times for different distances/race types? I cannot find this anywhere, neither on Racing Post either :( Trawling through every track will take a billion years!

Thanks

EDIT: Script complete, please unzip the contents of the attachment into a directory and run the script as below.
Requirements: Python 2.x

Run the following command at your command prompt/terminal:

Code: Select all

racingtimer.py <distance> <racetype>
e.g.:

Code: Select all

racingtimer.py 5f turf
All the supported distance/racetypes are in the csv.

For example:
Image
cheers for this... this will be useful as is and as a resource using the times.csv file in other applications. thank you so much

btw - this would be a nice addition to Guardian. I know some OTHER software (cough) use a similar progress bar on the race, which is very helpful as a guide if not using pictures.
User avatar
jimibt
Posts: 4197
Joined: Mon Nov 30, 2015 6:42 pm

David,

I implemented a .net version of this and all works fine. However, I'm sure you noticed, here are a ton of duplicates per RaceType/Distance in the csv file. I actually just took the 1st instance found of each and popped it into a dictionary object. There is a small variance however between some of the duplicates, so not sure if an AVG of the dupes would be desirable or not.
Post Reply

Return to “Trading Horse racing”