Maria Laying Strategy with BFExplorer
Posted in Betfair bot for this week, algorithm and strategy by formbet
I would like to post a suggestion for Bot Of The Week and was wondering if this is at all possible. Here is what I would like to do -:
1) I have designed a laying strategy using a number of statistical factors which in testing has a 94% strike-rate so far
2) The stakes on the lays depend very much on a) the odds of each selection and b) the size of the bank with different stakes depending on the odds and size of the bank. The maximum lay price is 10/1 (11.0 decimal)
3) I would like to be able to input a list of all the qualifying lays and then for BFExplorer to run through, check the odds ranges of each selection to lay and automatically lay all the selections in one hit depending on the odds and bank size of that day. The bank and bet size is not adjusted after each bet but only on a daily basis so there is no need to adjust after each race.
Here are the full details of the Maria Staking plan below, can you let me know if this can be considered for a bot and if you have any other questions then please let me know. For the month of December I will also be more than happy to share the lay bets with the BfExplorer forum -:
MARIA STAKING PLAN
Like all staking plans which are essentially mathematical formulas, The Maria staking plan can be broken down into rules.
1) - There are 3 distinct odds ranges to be aware of. The following is based on a starting bank of £3000
- Prices below 3.5: lay to 1% of bank - backer's stake £30 (liability is always under £75 in this price range)
- Prices from 3.6 to 7.4: lay to 0.6% of bank - backer's stake £18 (liability is always between £46.80 - £115.20 in this price range)
- Prices from 7.5 to 11: lay to 0.4% of bank - backer's stake £12 (liability is always between £78 - £132 in this price range)
- Anything above 11 or 10/1 is left alone.
2) - If making profits, the stakes are increased on a daily basis in proportion to the betting bank on a daily basis. For instance, if after day 1 the betting bank is at £3300 then 1% would now be £33 rather than £30.
3) - If after a days betting the cumulative betting bank has decreased the stakes are left alone unless 35% of the highest level of the bank is lost, when the stakes are re-calculated based on the new "65%-sized bank"
For example if your using £3000 as your starting betting bank, you would keep the same stakes used until your betting bank went below £1,950 when those backer's stakes would become £19.50, £11.70 and £7.80 until the bank gets back up to £3,000 again (or - even down to £1267.50 - a further 35% loss).
The 35% drop is always worked out from the highest point of the bank.
Thanks a lot
Dave
Sunday, November 21, 2010
if this will be done by Stefan a you will offer this via BFE, I want to try this subscription (http://formbet.co.uk/)
Sunday, November 21, 2010
Betfair bot script: Bfexplorer.Scripting.MariaLayingStrategyBot
Use this betfair bot script with the tool: Execute my strategy on selections. The bot has no parameters, MyBot MyBotClassName is: Bfexplorer.Scripting.MariaLayingStrategyBot
public class MariaLayingStrategyBot : Bot { // Const private const double LayOddsRange1 = 3.5; private const double LayOddsRange2 = 7.4; private const double MaxAllowedLayOdds = 11; private const double StakeMultiplier1 = 0.01; private const double StakeMultiplier2 = 0.006; private const double StakeMultiplier3 = 0.004; // Static private static double myAvailableBalance; public MariaLayingStrategyBot(IBetfairService betfairService, MonitoredMarket monitoredMarket, Runner runner) : base(betfairService, monitoredMarket, runner) { if (myAvailableBalance == 0) { myAvailableBalance = betfairService.GetAvailableBalance(); } RunnerProperty.AtInPlayKeepBet = true; } public override void DoYourJob() { base.DoYourJob(); switch (tradingState) { case TradingState.WaitingForTrade: if (!PlaceMyLayBet()) { AddMessage("Lay odds above allowed odds: " + MaxAllowedLayOdds.ToString()); Stop(); } break; case TradingState.LayingBetDone: ShowTotalMatched(); break; default: break; } } private BetPrice GetMatchedBetPrice() { return betStakeCalculation.LayBetPrice; } private double GetOdds() { double odds = runner.BestPriceToLay != null ? runner.BestPriceToLay.Price : 0; if (odds != 0 && odds > MaxAllowedLayOdds) { odds = 0; } return odds; } private double GetStake(double odds) { double stakeMultiplier = StakeMultiplier3; if (odds <= LayOddsRange1) { stakeMultiplier = StakeMultiplier1; } else if (odds <= LayOddsRange2) { stakeMultiplier = StakeMultiplier2; } return Math.Round( (myAvailableBalance * stakeMultiplier) / (odds - 1), 2); } private bool PlaceMyLayBet() { double odds = GetOdds(); bool status = odds != 0; if (status) { PlaceBet(BetType.Lay, odds, GetStake(odds)); } return status; } private void ShowTotalMatched() { BetPrice betPrice = GetMatchedBetPrice(); AddMessage(betPrice.IsNull ? "No bet matched." : "Your bet was matched (Total): " + betPrice.ToString()); Stop(); } }You can download the source code of this betfair bot.
Monday, November 22, 2010
That's an outstandingly fast response Stefan - many thanks. I will take a look on Tuesday and test as it's my girlfriend's birthday on Monday and she would not like me testing bots on her birthday :-)
Providing all goes ok I will look to post up selections on here around 11.30am each day from December 1st for a month to see how it pans out. For those with smaller bank sizes the strategy works equally well in the place market - obviously the odds ranges would have to be fractions of the odds ranges in the win markets - would that just be a case of adjusting the odds parameters in the source code or would there need to be other work done for the place market ?
Monday, November 22, 2010
Maria Laying Strategy for To Be Placed Markets
The bot uses three odds ranges to assign different percentage of your starting bank for a lay stake. If you want to use this bot on to be placed markets then copy the bot script file and rename it, for instance to:
Bfexplorer.Scripting.MariaLayingStrategyToBePlacedBot.cs
and of course the new class will be: MariaLayingStrategyToBePlacedBot
Change values for following parameters:
And you will get two version of bots, the one for win markets and the other one for to be placed markets.
Wednesday, November 24, 2010
Maria Laying for Liability
Hi Stefan
Is it possible to provide a Maria "Liability" version. This would result in lower profits but higher ROI and a steadier, less risky upward profit curve ?
The Maria Liability Staking Plan pretty much uses the same rules as the default Maria Staking Plan however there is one difference. Instead of a fixed stake being used for each odds range. There is a fixed liability.
There are 3 odds ranges. Each odds range has its own liability level. For instance in the example above with all odds less than 3.5 the liability will be 1% of the bank. In this case 1% x 1000 or £10.
The next odds range is less than or equal to 7.5 (but obviously greater than 3.5). In this instance the liability per bet is 0.6% x 1000 or £6.
The final odds range is less than or equal to 11 (but obviously greater than 7.5). In this
instance the liability per bet is 0.3% x 1000 or £3.
Any odds over 11 are shown as a zero stake.
Wednesday, November 24, 2010
Hi Dave, Exactly this way is calculated your stake, for a lay bet liability. I think the function GetStake is readable for non programmers as well:
Friday, November 26, 2010
Ah ok thanks Stefan I hadn't realised it was a liability-based plan already so I have setup two, one for stakes and one for liability although I suspect the latter will produce the better ROI.
I am almost ready to go with testing, I will put up my best lays each day from Dec 1st but obviously won't put them all up...is this the best place to post them ?
There is one final thing I need. I have a rule where I only lay in races with 8 runners or more, how would I build this logic into the bots so that 7-runner races and less are ignored by the bot ?
Many Thanks
Dave
Friday, November 26, 2010
Hi Dave, I have just updated the betfair bot script as you requested.
Wednesday, December 01, 2010
I am publishing out my daily lays for a week on BfExplorer Pro using the Tipster name FormBet
Many thanks for setting this all up and the bot configuration Stefan.
Thursday, December 02, 2010
http://formbet.co.uk/
FormBet,
I see the video on the website how selections were picked. I want to ask if you plan fully automated subscription for this product based on BFE? I am insterested in as a subscriber.
Thanks!