Community Articles
- Popular
- Recent
- Comments
-
Hello. Since yesterday I have a delayed API on my BF Explorer trading software. I had no bots running when this happened and now I am also unable to trade as all stakes in the markets keep flashing all over the ladders on random odds, being absolutely impossible to figure out what was the last price ...
9.5.2020 16:19:41 -
I tried BFexplorer, having used 3-4 different software applications beforehand. The 2 days utilising the software, I managed to get a feel for the product and like the modern display on the black background. Bets placed were very responsive with no lagging experienced from other products. A few ...
25.3.2015 17:55:00 -
Version 3.22.0821 Cumulative updates to the Bfexplorer Preview version Version 3.10.0721 Cumulative updates to the Bfexplorer Preview version (.net 8.0) Version 3.9.0425 Cumulative updates to the Bfexplorer Preview version Version 3.1.1021 - preview Betfair menu ...
22.8.2024 14:37:12
-
Overfitting: The art of avoiding overfitting and the importance of comparing training and test results to detect it. ROI Calculation: Different methods of calculating ROI, including the impact of flat stakes versus stakes based on odds. Feature Selection: Emphasize the importance of ...
21.11.2024 8:41:42 -
All about Luck and Success betting
The Role of Luck Unpredictability: Betting inherently involves a degree of unpredictability. No matter how much analysis you do, there are always elements beyond your control, such as unexpected injuries or weather changes. Short-Term Variance: In the short term, luck can significantly influence ...
10.9.2024 13:27:05 -
Some insights into different betting strategies, including trading in and out versus betting based on fundamental probabilities. Trading In and Out: This strategy involves placing bets and then trading out of them to lock in profits or minimize losses. It’s similar to stock trading, where ...
10.9.2024 13:24:03
- by : Betfair Bot
- by : adska
- by : adska
- by : adska
- by : adska
- by : Betfair Bot
peteresgate@outlook.com
That's great thanks Can the market interval be changed via code?
peteresgate@outlook.com
Would you mind linking the article? I can't find it.
Thanks
peteresgate@outlook.com
Thanks. Actually this explains everything :)
With the offered prices, it has probability - could you please tell me what this is?
peteresgate@outlook.com
Yes but this prints all the bets, with no way to get just the matched lay or matched back bets. To get the unmatched with your code is good, but the matched doesn't work this way. Could you please show a code sample?
peteresgate@outlook.com
The unmatched data works great thanks Stefan. I really appreciate the code thanks.
But I still have a problem getting the matched data. When the orders are matched, I am trying to get the combined Odds (as float) and combined Stake (as float) for Matched Lays, and Matched Backs as shown in the Market Bets window (it combines all the Matched Lays and all the Matched Backs). All I get with the code I posted recently is the head which is the first item shown in ther market bets window, but I can't sort the map to get the requested matched/unmatched to the head. Could you please post the code snippet for this?
peteresgate@outlook.com
So do you mean something like this?:
let betSize(bet : Bet) =
bet.Size
let getBetSize() =
if selection.Bets |> Seq.exists (fun bet -> bet.OrderStatus <> BetOrderStatus.Matched && bet.BetType = BetType.Lay)
then
let price = selection.Bets |> Seq.map betSize |> Seq.head
This is the correct way? Is there not a way to do something like selection.Bets.Size or selection.Bets.Price or selection.Bets.BetType etc?
peteresgate@outlook.com
Maybe GetPriceSize is not the code I'm looking for? When a bet is matched or partially matched, it has the Stake that is matched and the odds it is matched at. So the code I am looking for that you have questioned is to find the stake amount that is matched. Thanks
peteresgate@outlook.com
Thanks for the info Stefan. I am trying to use the info for a selection like this:
let UnmatchedLayBets () =
if _selection.Bets |> Seq.exists (fun bet -> bet.OrderStatus <> BetOrderStatus.Matched && bet.BetType = BetType.Lay)
then
let price = _selection.GetPrice(BetType.Lay)
let Stake = _selection.GetPriceSize(BetType.Lay)
if price > 10.0
then
outputMessage (sprintf "Unmatched Price > 10: %.2f " price )
But the error exists because the result is a float option. I have tried to find how to cast the float option to float so that I can use the result in calculations but have not found how to do it yet. How would I return the stake and price as a float so that I can use it? I'm sure this is an easy question for you but I have been pulling my hair out over this.
peteresgate@outlook.com
Edit,
When I say at +/- 2 levels, I mean the matched volume at a price (which I will use the price at +/- 2 levels because I know those prices
peteresgate@outlook.com
This is the code I am using to try and find Matched Volume at levels:
https://github.com/PeterEsgate/BfexplorerTestBots/blob/master/MarketDepthMatched
and I use it by:
let test = getMarketDepthMatched(BetType.Lay) (MYSELECTION) 1
outputMessage (sprintf "matched data %.2f" test)
But this causes Bfexplorer to "hang" and I have to cancel the bot
For my bot, the last 2 things I need is to find the matched volumes at +/- 2 levels and the Time from scheduled start, but I am having difficulty with these 2 things.
peteresgate@outlook.com
I have tried both the MyF#bot and MyC#Bot for showSelectionSP, and I tried the HorseRacingSPBotTrigger and moved showHorseData to show before inPlay the Near and Far SP, but I have never achieved to show the Near/Far Projected SP or the actual SP when inPlay (the horse metadata works). I was wondering if there has been a change in the method to receive the SP prices?
peteresgate@outlook.com
I got it to work using another of your codes that I found from weight of money :)
peteresgate@outlook.com
Hi Stefan,
Yes thanks it will get the odds at specified levels now thanks.
But with the volume it is different.
https://github.com/PeterEsgate/BfexplorerTestBots/blob/master/Market%20Depth%20Volume
On Line 35 and 27, why I can't I just substitute the "priceData.Price" with "priceData.ToBack" ?
With the PriceGridData.GetOfferedPriceData(), there is no method (that I could find) to go to different levels like with priceGridData.GetPriceData(index)
peteresgate@outlook.com
Please see the code here:
https://github.com/PeterEsgate/BfexplorerTestBots/blob/master/Market%20Depth%20Levels
I run it like this:
let mutable odds = defaultArg (botTriggerParameters.GetParameter<float>("Odds")) 1.0
odds <- getMarketDepthPrice(BetType.Back) (myLaySelection) 1
outputMessage (sprintf "Lay Odds at Level 0 %.2f" odds)
odds <- getMarketDepthPrice(BetType.Back) (myLaySelection) 2
outputMessage (sprintf "Lay Odds at Level 1 %.2f" odds)
but the result of odds is always 0.0
I am trying to find the available odds at different market depth levels
Could you please tell me what is wrong with the code?
peteresgate@outlook.com
That is a great explanation thanks :). I have noticed 1 thing with my bot and I see it doesn't seem to do what I think it should (I'm blaming my code) so I just wanted to ask that after it performs an executeOnSelection, mySelection1 and I change status <- goToMyNextTrigger and I have another executeOnSelection mySelection2 (when new conditions are true), it can do multiple executions with different selections right? It may be because my action happens near the end of the race but I only ever see 1 bet.
peteresgate@outlook.com
I didn't explain properly sorry. What I mean is I can see it create the bot and it has bot.Start to place the trades. Then the next part I don't understand. You run Update, which from what I can see only changes the parameters, so how did the bot place trades again and use the new parameters? I can't see how it executed new trades based on what is in the Update()
peteresgate@outlook.com
I've been looking at the scalping bot and the way it creates the bots, I like it a lot. Do you have another example of creating a bot with parameters like the scalping bot, but with a method call to execute on mySelection from within member_execute? For example 1 method call I would have parameters and betType lay for mySelection and another method call would have different parameters for a different mySelection betType back etc. From your examples I am learning a lot, but I couldn't find one like this.
peteresgate@outlook.com
Actually, I think I can work it out thanks, but could you please show me how to get trigger to "get" past strategy results. Thanks
peteresgate@outlook.com
Is there a way to
match getMySelection() with
| Some mySortedSelection -> (where mySortedSelection is a list?)
instead of having a lot of
match getMySelection() with
| Some mySelection1 ->
match getMySelection() with
| Some mySelection2 ->
match getMySelection() with
| Some mySelection3 ->........................etc
peteresgate@outlook.com
Please see Your Code for Part 2 (with some additions and comments) There is 1 thing that I cannot see in the code (line 187 - 192), and that is when a horse has improved in position, then I don't want it in mySelection. I only want to lay it if it is in the same position or has worsened in position, (and not in top 3 which is coded on line 194). Is it somewhere that I cannot see?
https://github.com/PeterEsgate/BfexplorerTestBots/blob/master/HorseRacingBotTrigger2-3.fsx