Three lays in a row

Discussion regarding the spreadsheet functionality of Bet Angel.
Post Reply
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

Hi everybody,
I'm a new entry with no big skills both on BetAngel and Excel software so please forgive me in advance.

I need to place three consecutive lays at different odds (if reached): let's say first lay at 1.2, second (if the odds continue to decrease) at 1.1 and third (if the odds continue to decrease) at 1.05.
How can I realize it?

I did the job for the first lay but:

- How can I clean the instruction sheet (or status cell) to apply the second and third bet?
- How can I change the previous threshold of 1,2 to the new value of 1,1 in time (during the cleaning operation??) so that the system does not place another lay at 1.2?

Thanks and sorry if too stupid :)

Max
User avatar
RichStone
Posts: 26
Joined: Sun Oct 28, 2012 1:31 pm

Hi Max,

Welcome to Betangel, quickly from the sounds of your trading aims it could be possible to use guardians automation feature to execute your trades more simply than going down the excel route. In regards to clearing status cells on excel you should probably have a look at this

viewtopic.php?f=19&t=30

Also someone has uploaded and donated a excel spreadsheet which does clear cell statuses, should be quite easy to find on the forum with a quick search

Rich :)
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

Thanks RichStone,
but I don't think that automation section can satisfy my needs.....excel is perfect for this and I followed your suggestion, studied around and found the cleaning routine ;)

One more request, if you don't mind.
I need to verify my profit/loss after a night of trading but as you know, few minutes after final suspension, all datas disappear from BA (and consequently, from excel).
I have to go to guardian, look at the matched bets and calculate the profit/loss......ppppffffff
Is there a way to record the value of a specific cell (in this case, the greening) somewhere else so that when datas disappear this value remains?

I don't know visual basic instructions but I thought that, if exist a command for cleaning a cell, maybe it exists another to copy and special paste a value....????

Thanks
Max
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

Hi all,
I'm still looking for a solution but what I found doesn't work.

I still have to record the value of few cells (the ones where the P&L and green up appear) at the end of a NBA match but before they disappear after sunspension. This is the code I tried to use:

Private Sub Worksheet_Calculate()
If Range("K1").Value = "SUSPENDED" Then
Range("c9:d12").Select
Selection.Copy
Range("c19:d22").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, skipblanks:=False, Transpose:=False
End If
End Sub


Basket market goes in suspension only when matches end and data remain available for few minutes more.....it should work but it doesn't.
I don't know VB and I realized this code craftly; could anybody tell me where is the mistake?
Thanks and best regards
Max
gallybloke
Posts: 41
Joined: Sun Nov 01, 2009 1:25 pm

Hi Max
A couple of things, first regarding the 3 lays I know you have sorted out a work around for this but for future ref you are able to do this through Automation.

You simply apply a green all profit rule to the second and 3rd lays for example the second lay can only be placed if the current price is <1.11 and the green all profit rule is <0.01 which can only be the case if the first lay at 1.2 has been matched.

You then apply the same principle to the 3rd lay.

Regarding the VBA code your using, try this...

Use a blank cel on the bet-angel sheet - example A2 and add this code into that cell(with the IF formula cell A1, you will need to change the "A1" to whatever cell on the betangel sheet contains the suspended formula)
=IF(A1="SUSPENDED",1,"")

Then alter your VBA code to this below, It’s this line of code that’s been altered (If Range("A2").Value = "1" Then)

Private Sub Worksheet_Calculate()
If Range("A2").Value = "1" Then
Range("c9:d12").Select
Selection.Copy
Range("c19:d22").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, skipblanks:=False, Transpose:=False
End If
End Sub

That should work

Regards
Gally
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

Ciao Gallybloke,
thanks for your help, I appreciated.
About the code, you suggest to trigger it through a number instead of a string? Mmhhh....ok, I'll ty and hope it works fine...thanks ;)

About automation....ok, maybe I don't know automation so good to understand how to realize it (I also have problem with excel so......I'm definitely in a trouble :) )

My problem with automation is the following:

Let's consider a simple example (not three lays but only one): I wanna lay if (ANY OF THE 2 TEAMS has) odds < 1,5 just once and back when same odds increase so that total profit is 15% of original lay bet. This means that I can take Lay odds wherever below 1,5 and calculate bet amount under condition that liability has to be £30. So if initial odds is 1,5 I'll lay £60, if initial odds is 1,2 I'll lay £150.
This first step is very simple with excel but how to set it in automation?
- In General: LAY bet during play time with trigger up to one time...but I don't know how to apply it to the first team who reaches 1,5 in LAY as the three available options can't help me
- In Parameters: best market price but what stake? I tried by liability with £30 but I don't think it works like I need
- In conditions: the market is In play and unmatched bets on selection=0
The second step is a Greening when profit >= 15% initial bet (which is variable because we fixed the liability):
- In General: rule type could be green all selections or close trade on selection triggered once with the same time of previous lay...???
- In parameters: nothing
- In conditions: how can I calculate the 15% of initial amount bet to put into Close Trade Profit Condition or Green All Profit Condition cell? In excel it's very simple but in automation?

Problems with three lays in a row are similar.....or even more.....that's why I chose excel.
Do you think there is a way to solve these problems in automation, too?

Thanks and regards
Max
gallybloke
Posts: 41
Joined: Sun Nov 01, 2009 1:25 pm

Hi Max

I will have a look at that automation file when I get 5 minutes spare knee deep in trading the tennis at the moment.

Regards
Gally
gallybloke
Posts: 41
Joined: Sun Nov 01, 2009 1:25 pm

Hi Max

The first thing you would need to do is create a rule – Place Lay bet, for each outcome Home, Away and Draw (if reqd)

Add the times you want to place the lays 1 second before the start etc and allow rule to trigger 1 times
Then you would have need to add the Parameters Place at <=1.5 and stake by liability £30.00

You would then add the conditions In-play and Green all profit condition =£0.00 (the reason you do this as soon as the first lay is placed the market will move against you and you will have a red book or more preferably the market will move in your favour and you will hit your target profit either way if any of the other outcomes hit’s the lay range the Green all profit condition will not be £0.00 meaning the condition is not met and no more lay bets will be placed)

The second issue is more of a head scratcher as you cannot offset a variable entry point by a % to green up on automation - as far as I know.

The only way you could kinda of work around it is by batching the odds into ranges for example 1.5 to 1.4 or 1.5 to1.45 and so on and so on

Work out roughly 15% of the batch so for example 1.45-1.5 is going to be a £60.00 stake give or take based on a £30.00 liability, slightly more on the bottom end so 15% of £60.00 is target profit £9.00

You could then work on the lowest odds is this case 1.45 and look on the ladder where the green all profit would be >=£9.00 in this case 1,68 would be a £9.13 green book based on a lay at 1.45 with a liability of £30.00.

Then you would write a rule - Green all Selections with Conditions - Green all profit condition is >=£9.00 and Relative Odds condition the selections Back price is >=1.68 (shown in the example above) you would need to have a Relative Odds condition for each outcome as you won’t know when it’s being automated which outcome had the lay-bet placed.

You would then write rules for each batch of odds adjusting the Green all profit figure and relative odds figure to suit.

A bit laborious but that’s the only way I think you could do it.

Regards
Gally
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

Ciao Gally,
thanks for the time you spent to help me ;)

I realized an automation rule (see attachment) following more or less your suggestions.
2 Lays instructions (one for row 1 and one for row 2 ....my bets on basket have no draw option). In this case it's possible that both instructions will work but this is not a problem because before the second will be triggered, the first already closed the green.

The green instruction is more complicated.
First, I'd like to consider BF commission. And second, 15% is to be calculated not everytime on 60€ but on specific amount which generates 30€ liability. This means that in your case of 1.45 (amount required: 66,66€) I'd like to have a profit >= 10€ and I'd need a back odds of 1.73 (commission included).

You wrote: "On Relative Odds condition the selections Back price is >=1.68". Despite the value, this kind of instruction is impossible to set if I choose RELATIVE (I have it only in FIXED).
In RELATIVE I need to refer to the price of in row 1 (or 2) plus.....a odds or tick value.
Assuming that the price in row 1 means the odds we used for placing the initial LAY, I put a value of 0,28 as PLUS in terms of ODDS (hoping that this means 1,78 if LAY was placed at 1,50 or 1.73 if LAY was placed at 1.45 or....etc etc....could u confirm?).
I chose 0.28 for 2 different reasons:
1) to simplify...otherwise we have to calculate this value for every batch of odds
2)1.78 is what I need in case of LAY at 1,5. 1.55 is what I need in case of LAY at 1,3. 1,31 is what I need in case of LAY at 1,1 etc etc. So the difference decreases from 0.28 to let's say 0.2.....if I consider 0.28 everywhere I'll never have profit less than 15%.

I didn't test this rule yet.....do you think it could work as we said?

Thanks
Max
You do not have the required permissions to view the files attached to this post.
gallybloke
Posts: 41
Joined: Sun Nov 01, 2009 1:25 pm

Hi Max

I will run it though pratice on the tennis and see if it works or if needs tweaking.

Regards
Gally
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

Hey Gally,
did you win billions of euro with my rule and moved to Bahamas enjoying tropical cocktails and gorgeous local women?
:lol:

Joking aside, did you test the automation? I'm not sure it works fine. Tested twice and obtained strange results...

Ciao
Max
gallybloke
Posts: 41
Joined: Sun Nov 01, 2009 1:25 pm

Hey Max

Not quite but a nice thought all the same, had a few days away from the PC - back to work today.

Your correct the file is not working, ive made two alterations to the lay's and these now work i.e. they will only lay one outcome and they will lay to a £30.00 libility at any price point below 1.5.

Regarding the target profit having to be 15% plus the commision as we discussed before automation does not have a feature to allow you to put a target profit in based on a % return.

So what you will have to do is work out a 15.5% return on each price point 1.5,1.49 etc etc and see where on the ladder you hit that target profit, then add a slightly lower green up value and one tick lower on the ladder to allow this to happen, I have attached a file with an example of a few price points to show you what to do....

The only thing you may need to change on the file is on the green up. I have this currently set on the fixed odds condition that the back price selection is on the (Current selection) you may have to change this to nominated and write the rule twice once for team A and once for team B – you will need to do this on every price point as well.

As I said in a previous post – quiet laborious but I think it’s the only way you will do it as your so specific about the % return you require.


Hope that helps

Regards
Gally
You do not have the required permissions to view the files attached to this post.
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

Thanks Gally.

I made it but not for every single position (I can accept discrepancies from 15% ROI....it's not mandatory).
I think it's ok now (if I understood what you mean).

I'll try it and let you know.

Ciao
Max
You do not have the required permissions to view the files attached to this post.
maxrizza
Posts: 12
Joined: Wed Dec 26, 2012 6:36 pm

I tried it.....and it was a small disaster :D

Well....not in terms of profit (I applied it on 5 NBA matches and won everywhere - Liability fixed at 30€ -> Profit overall: 52.9€) but in terms of behaviour: it simply worked differently from what I tried to set....and we all know that this is not acceptable, even if it wins.

I write here what it did, hoping that from this data is possible to understand the mistakes and identify where to correct:

Brooklyn - Lakers: Lay @ 1.5 (60€) and Back @ 1,77 instead of greater than 1,77 (are the 2 conditions of Green Up rule in "AND" or in "OR"?....it seems OR....)
Indiana - Atlanta: Lay @ 1,41 (73,17€) and Back @ 1.61. Once again it greened when profit was greater than 9 which is one of the condition of GREEN UP 1.5 FOR 15% rule...but here initial LAY was 1,41!!!!
Memphis - Phoenix: Lay @ 1,24 (125€) and Back two times @ 1.35 (???) the same amount of 114,81€ . Four minutes later it Lays @ 1.33 (116.53€)....????
Houston - Golden State: Lay @ 1.49 (61.22€) and Back @ 1.76. (this is the only correct if, when in the range 1.45<Odds<1.5, the rule applies to 1.45)
Denver - Milwaukee: This is weird! 9 Lays and 7 Backs (all of them on Denver) in this order:
Lay @ 1.36 (83.33€)
Back @ 1.56 (72.65€)
Back @ 1.56 (72.65€)
Lay @ 1.5 (75.56€)
Lay @ 1.5 (75.56€)
Back @ 1.63 (69.53€)
Back @ 1.63 (69.53€)
Back @ 1.63 (69.53€)
Lay @ 1.51 (150.11€)
Lay @ 1.51 (150.11€)
Lay @ 1.51 (150.11€)
Lay @ 1.51 (150.11€)
Back @ 1.59 (433.12€)
Back @ 1.59 (433.12€)
Lay @ 1.74 (396.20€)
Lay @ 1.82 (4.36€)

The same identical orders were applied in the same moment as it triggered more than once.....???

As I said...a little disaster :)

Unfortunately this strange behaviour happened with Excel spredsheet too so my opinion is that in this kind of market odds change so quickly that automatism can't be precise and from time to time get crazy.

What do you think?

Max
Post Reply

Return to “Bet Angel - Spreadsheet / Excel chat”