Football - knowing the CURRENT SCORE

Post Reply
sibur
Posts: 64
Joined: Tue Jan 11, 2022 11:07 pm

Trading Football is often thwarted because you don't know the actual current score within Guardian. Unfortunately the Betfair API doesn't provide this information - and for the life of me I don't know why, considering they know it and display it in their UI. Therefore we are left to guestimate it by using various trickery monitoring odds changes and incrementing counters. I've seen a few solutions in this forum but they are a bit flaky, I have observed, because they rely on odds moving and sometimes odds don't move in the same way. The problem is compounded with the introduction of VAR because a lot of goals get credited and then later, chalked off. Trying to contend with this is a problem. These solutions do work but not all the time and I am loathed to stake real money on them because they do get it wrong - quite a lot.

I am a professional software developer and have used the Betfair API for many years and always had a notion on how to tackle this using the API and never got round to it. Last year I started using BetAngel for my betting/trading.

On a side note I would like to say that BA and Guardian is an awesome piece of technology. The time it takes me to develop a strategy using the API was long and arduous - it might take several days to try something out, only to discover it was a non-starter and I was back to square one. With Guardian I can knock something up in a matter of minutes - try it out and determine if it's got legs. I think what Peter Webb has created (with his team) is a miracle.

So, I have finally got round to looking at determining the current live score. Please find the BAF file below. It requires the Correct Score Market to be selected. It works by getting the lay odds of each selection and then finding out which selections arte no longer active. These selections tend to show lay odds as empty or high numbers 990 and beyond.

Every match starts at 0-0. If the lay odds show any value (up to 990), then I can be sure its still 0-0. If the home side score first, the score goes to 1-0. The lay odds for 0-0 then show as empty, as well as 0-1 - because 0-1 is an impossible result. If the score then goes to 1-1, the odds for 0-0,1-0,0-1 are empty. This approach can be used to decide the score until we reach Any Other Home Win/Away Win/Draw. When this happens all the other scores will be empty and we just need some comparing of odds between the Any Other selections.

There are some gotchas and this isn't foolproof. Sometimes when goals go in the odds on Correct Score selections can go a little wonky - particularly low volume matches. So its possible to see incorrect scores for a short time - if this happens you'll see they typically rectify themselves. I have seen some matches go immediately to HW because the 0-0 shows as empty but that is infrequent and not in high profile matches. The rules run every 30 secs - so be prepared to wait a minute - you can change this if you like.

This is the 3rd version. The first attempt was to prove it would work. The second worked but it was an extremely big BAF using a lot of conditions that slowed everything down. The third attempt does it in a slightly different, but more efficient way, counting the home goals and away goals then combining them for the score.

The scoreline is in an event stored value called CurrentScore
The correct score code (1-19) is an event stored value called Score

I hope this helps. Happy trading!

Let me know if you discover any issues!
Current Score v4.1 By Sibur.baf
Screenshot_20230907-132159.png
You do not have the required permissions to view the files attached to this post.
Last edited by sibur on Thu Sep 07, 2023 1:23 pm, edited 2 times in total.
User avatar
Dallas
Posts: 22729
Joined: Sun Aug 09, 2015 10:57 pm
Location: Working From Home

Image

Thanks for sharing this I'm looking forward to giving it a go, It's something I've often considered doing but the laboriousness of setting it up often meant it kept getting pushed down the to do list.

If it works well and with your permission I might include it with the existing examples that display the score on the one-click screen and watchlist etc
sibur
Posts: 64
Joined: Tue Jan 11, 2022 11:07 pm

Please do Dallas. I just updated the post as I had forgotten to say what stored value to use and you can of course build this into your Guardian layout
goldfinch77
Posts: 201
Joined: Wed Aug 05, 2020 11:45 am

Just a note

This BAF won;t open with BA version 1.60.0

Which I believe is the curren version

Goldfinch
sibur
Posts: 64
Joined: Tue Jan 11, 2022 11:07 pm

It was created in 1.61 which is later. Shouldn't use new features but not sure if 1.61 BAF is backwardly compatible? @Dallas ?
User avatar
Euler
Posts: 24816
Joined: Wed Nov 10, 2010 1:39 pm
Location: Bet Angel HQ

sibur wrote:
Thu Sep 07, 2023 1:26 pm
It was created in 1.61 which is later. Shouldn't use new features but not sure if 1.61 BAF is backwardly compatible? @Dallas ?
For consistency, automation created in later versions is only compatible with that version onwards. Else it gets horrifically complicated.
sibur
Posts: 64
Joined: Tue Jan 11, 2022 11:07 pm

Ok, I will have a look at creating a 1.6 version but I have been using 1.61 for a couple of weeks and it seems to be ok. Realise it's a Beta tho.
User avatar
Dallas
Posts: 22729
Joined: Sun Aug 09, 2015 10:57 pm
Location: Working From Home

sibur wrote:
Thu Sep 07, 2023 1:35 pm
Ok, I will have a look at creating a 1.6 version but I have been using 1.61 for a couple of weeks and it seems to be ok. Realise it's a Beta tho.
V1.61 will officially be released and added to the Bet Angel website as the latest version very soon so I wouldn't bother editing to be compatible with V1.60

Once a new beta is released on the forum all the examples I post thereafter use that version (even if the example doesn't use any of the new options/features), if people want to use it they will update their version :)
User avatar
ApolloV
Posts: 8
Joined: Mon Dec 06, 2021 5:00 am

Just tried this out and it's looking good so far. Great work.
User avatar
Geordie
Posts: 174
Joined: Fri Sep 12, 2014 10:54 am
Location: North East

Awesome, look forward to testing this out.

Many thanks and very kind of you, Sibur :D
stoo[id
Posts: 4
Joined: Sun Sep 26, 2021 2:06 pm

Many thanks.
WelshMage
Posts: 51
Joined: Fri Sep 23, 2022 3:47 pm

This sounds really useful.

Can I just check that there is nothing else to do other than download the BAF file which I have done but not tried it yet. So do I just add a Correct Score market to Guardian and then just apply the rule to this selection?

Does it then display the columns as shown in the snapshot you have included. Or do we need to adapt custom columns? If it is the latter, is this straightforward to do?

Mike
sibur
Posts: 64
Joined: Tue Jan 11, 2022 11:07 pm

Hi Mark. You pretty much got it. The score is saved in the stored value "CurrentScore" it is stored against the event meaning you can refer to it on other automation files you are using at the time. You will have to include it in your list yourself, so the screenshot I posted I had saved a column with CS as the column header and CurrentScore (event) as the value and included that column iny list. Hope it helps.
Be good to hear if others find it useful?
WelshMage
Posts: 51
Joined: Fri Sep 23, 2022 3:47 pm

This works amazingly well. It took me a while to realise that I needed to change the custom column to pick up CurrentScore from the Event, not the Market, before it suddenly started to display the scores.

So thanks for this. It is so useful. I trade, dutching the correct scores, quite a lot and it is great for that because I don't have to keep checking FlashScore to check what the current score is if I am trading several games at the same time. The info is updated in real time all in one place on Guardian.
User avatar
Geordie
Posts: 174
Joined: Fri Sep 12, 2014 10:54 am
Location: North East

sibur wrote:
Sun Oct 29, 2023 9:17 am
Be good to hear if others find it useful?
Hi, Sibur.

I've been using this for a while and I couldn't do without it now :D

Makes life so much easier, a million thanks.
Post Reply

Return to “Bet Angel Automation - Football”