Help to Modify Gary's "Simple scalping using CLEAR trigger"

Discuss anything related to using the program (eg. triggered betting tactics)

Moderator: 2020vision

Help to Modify Gary's "Simple scalping using CLEAR trigger"

Postby xraymitch » Fri Jun 05, 2015 8:49 am

Hi folks,

Gary posted an example trigger some years ago which I spent 3 hours last night trying to modify without success.

This is Gary's trigger. =IF(AND(T5<>"",W5=S1),"CLEAR",IF(Y5=Z5,"BACK","LAY"))

I want the trigger to stop firing when the race goes In Play but to place a lay bet immediately in running if the Back bets are greater than the Lay bets.

The trigger below is what I have so far which stops when In Play.

=IF(AND($E$2="Not In Play",$F$2="",T5<>"",W5=S1),"CLEAR",IF(Y5=Z5,"BACK","LAY"))

Can some kind soul amend it for me so that it will place a Lay bet if Back bets matched are greater than Lay bets matched.

Spent 3 hours on this last night with no success - I am now depressed by my inability to achieve what I want, perhaps I am going senile... :(
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby Captain Sensible » Fri Jun 05, 2015 12:56 pm

It'd probably help if you gave more of an idea of how the BOT is firing i.e. what comes first back or lay? If the bot simply backs then lays it's a lot easier to write a formula than if it can either back or lay first. Mainly because you'd just apply another AND condition about inplay to the BACK routine if it backed first and let the LAY run as usual. MIght even be easier for you to control things if it's random by using the excel offset triggers.
User avatar
Captain Sensible
 
Posts: 2883
Joined: Sat Nov 19, 2005 2:29 pm

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 5:38 pm

Captain Sensible wrote:It'd probably help if you gave more of an idea of how the BOT is firing i.e. what comes first back or lay? If the bot simply backs then lays it's a lot easier to write a formula than if it can either back or lay first. Mainly because you'd just apply another AND condition about inplay to the BACK routine if it backed first and let the LAY run as usual. MIght even be easier for you to control things if it's random by using the excel offset triggers.


Hi Captain,

Just got away from work early and good to hear from you and that so many of the regulars such as Osknows, Doris_Day, 2020Vision and many others I have a great respect for such as your self are still here. I have been off the scene for almost a year (still paid my subs each month though) so no doubt I have got rusty with triggers in the meantime.

Sorry for not making my post clear, Gary's trigger fires the BACK bet first then LAYS, below is Gary's description.

This spreadsheet will place a back bet at the current best back odds and when matched placed a lay bet for the same stake at the current best lay odds. You must select to log My Bets when linking to the spreadsheet for it to work correctly.

It uses the SUMIFS function to calculate the total matched back and lay stakes. When they are the same it means another back can be triggered as the previous trade is closed. It only checks up to row 100 on my bets so if the number of bets exceeds 99 it will not work correctly.


My trigger will stop firing when race goes In Play thus there may be a Back bet matched with no corresponding Lay bet. I want the lay bet to be placed ( I realise it may not be matched but that is fine for the moment.)

Your suggestion
Mainly because you'd just apply another AND condition about inplay to the BACK routine if it backed first and let the LAY run as usual.
is exactly what I was trying to do without success as I would end up in a loop placing multiple Lay Bets.

If you could put an example trigger together for me based on the above that would be brilliant :D

Many thanks for your time and input.

xraymitch 8)
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby Captain Sensible » Fri Jun 05, 2015 6:01 pm

I'm not aware of the sheet so no need what all the W5=S1 and Y5=Z5 all refer to. If the sheet BACKs first then realistically it seems all you need to do is stop the back routine from firing when in play but allowing the lay routine to fire whenever your other conditions are matched, So I'd just suggest you replace your BACK condition with added criteria that stops it firing when the market is inplay that way the lay should fire as before. but I've no idea how your other conditions handle with part matched bets.

So simply changing the BACK in your formula to something like IF($E$2="Not In Play","BACK","BACKING_CRITERIA_NOT_MET") should stop it firing back bets in play, but like I say I've no idea how your code handles part matched bets. If they're a problem it's probably easiest to look at including addtional In play criteria to your Y5=Z5 conditions

=IF(AND($E$2="Not In Play",$F$2="",T5<>"",W5=S1),"CLEAR",IF(Y5=Z5,"BACK","LAY"))

would therefore become

=IF(AND($F$2="",T5<>"",W5=S1),"CLEAR",IF(Y5=Z5, IF($E$2="Not In Play","BACK","BACKING_CRITERIA_NOT_MET") ,"LAY"))
User avatar
Captain Sensible
 
Posts: 2883
Joined: Sat Nov 19, 2005 2:29 pm

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 6:45 pm

Hi Captain,

Thanks for such a fast response. W5 is matched stake and S1 is the stake. Y5 is matched BACK bets and Z5 is matched LAY bets, thus when they are equal a new back bet is placed. My trigger is only firing when Not In Play, thus you can have a BACK bet matched and the trigger stops when in play leaving you with an outstanding LAY bet .

I just need you to modify my trigger so that only one Lay bet is placed in running if Y5>Z5

Cheers,

xraymitch
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 6:53 pm

Hi again Captain,

Looking at your trigger example I will give it a try later this evening - I am tired so maybe it does exactly what I want but I am just not understanding properly...
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 7:03 pm

Hi Captain,

YOU ARE A STAR !!!

Just ran your trigger on the 18:55 and it did exactly what I wanted.

I need to look at your trigger tomorrow as right now I am mentally exhausted from working on PC's all day. I am going to play all tonight's races with your trigger and report back tomorrow.

Big thanks

xraymitch 8)
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby Captain Sensible » Fri Jun 05, 2015 7:15 pm

All I did was apply a condition so the BACK bets would stop firing when the market was in play, it wouldn't affect the LAY side of things, so that would carry on regardless of whether the market was in play or not, so should mop up any outstanding BACK bets as normal.

BUT with any BOT you should always consider all options and if your last BACK bet was part matched your criteria W5=S1 (Should it be $S$1?) would not be met so the CLEAR wouldn't fire and if it was matched right at the off your AND $E$2="Not In Play" would also stop it from clearing and triggering a LAY also.

I think what you'd need to do was set a separate set of rules for once the market was inplay to cover any part matched BACK bets or play it safe and just use fill or kill options ensure any BACK bets are killed before the off time, easy enough to do using the the time to off as your fill/kill figure. I'd also use LAY-SP or LAY-IP to catch any unmatched lays once the markets gone in play. Most bots play on such a small percentage take its easy to throw it away by not covering all bases.
User avatar
Captain Sensible
 
Posts: 2883
Joined: Sat Nov 19, 2005 2:29 pm

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 7:25 pm

Hi Captain,

You are really so good and I take on board what you say. I am only playing with £2 stakes for the moment whilst testing and looking to see if I can get out with a small percentage profit during the race (which I have still to automate).

Right now all this evenings races are being played and I am manually taking a profit or cutting the losses. I will report back tomorrow on the outcome and share my spreadsheet with you.

Cheers,

xraymitch 8)
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 7:38 pm

Hi Captain,

Tried to back a horse to be told I had no money - I thought everything was working only to discover I had all these lays as you can see in the screen shot. Need to check the spreadsheet in case I made a mistake setting up the sheets ... LOL just seen Vincentti would have lost !!

Wanted to send you a screenshot but for some reason I cannot for the moment. Will do so later.
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 7:44 pm

MEA CULPA, nothing wrong with your trigger. I had missed updating one of the sheets !!
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Fri Jun 05, 2015 9:35 pm

Hi Captain,

Sad to say I have at least 2 examples from this evenings meetings where the LAY bet was not placed. Will give you a full update tomorrow morning and thanks again for all your input it is really appreciated.

Switching off as I am totally exhausted from a stressful day at work.

Cheers,

xraymitch 8)
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Sat Jun 06, 2015 10:47 am

Hi Captain,

Just a quick update. I can see from the transaction logs and Betfair history that if a LAY bet is not matched before the off its reference needs to be cancelled. So I will need to adjust your trigger accordingly ( You did mention that could be a possibility)

Thanks again as you have been a tremendous help in sorting out the trigger logic flow, which only this morning have I fully come to understand.

Cheers,

xraymitch 8)
Attachments
Unmatched.PNG
Unmatched.PNG (156.52 KiB) Viewed 34302 times
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby Captain Sensible » Sat Jun 06, 2015 12:17 pm

If you're only backing one horse and looking for one tick surely you'd be better off just using a trigger like BACK-T1-IPC pre inplay as that would be more efficient and save all the hassle of trying to fire lays back into the market only when all the initial bet was matched. You could just use your routine that ounts up stakes of back and lays to decide when to fire.
User avatar
Captain Sensible
 
Posts: 2883
Joined: Sat Nov 19, 2005 2:29 pm

Re: Help to Modify Gary's "Simple scalping using CLEAR trigg

Postby xraymitch » Sat Jun 06, 2015 4:45 pm

I agree 100%, but I am exploring the germ of an idea which will ultimately mean looking to back and lay every horse - it is early days yet and I will update you if it shows any merit.

Just watched the Derby - absolutely fantastic race and a superb result for Frankie !!

8)

PS I made a penny profit LOL :)
xraymitch
 
Posts: 410
Joined: Wed Jun 25, 2008 7:06 am
Location: UK

Next

Return to Discussion

Who is online

Users browsing this forum: No registered users and 24 guests

Sports betting software from Gruss Software


The strength of Gruss Software is that it’s been designed by one of you, a frustrated sports punter, and then developed by listening to dozens of like-minded enthusiasts.

Gruss is owned and run by brothers Gary and Mark Russell. Gary discovered Betfair in 2004 and soon realised that using bespoke software to place bets was much more efficient than merely placing them through the website.

Gary built his own software and then enhanced its features after trialling it through other Betfair users and reacting to their improvement ideas, something that still happens today.

He started making a small monthly charge so he could work on it full-time and then recruited Mark to help develop the products and Gruss Software was born.

We think it’s the best of its kind and so do a lot of our customers. But you can never stand still in this game and we’ll continue to improve the software if any more great ideas emerge.