Help With Formula Please

S

spreadbet

Hello I hope someone can help me I spreadbet and have a program tha
triggers bets using excel I need a formula that will buy two shares bu
only when they are priced below 2.

I have this so far but all it achieves is the buying of one bet whe
two are under 2

IF(AND(AND(r_1_layp<2.0, r_2_layp<2.0), OR(lay_price<=r_1_layp
lay_price<=r_2_layp)), 2, 0)

I hope someone can help me someone else helped me with the above but w
dont know how to get it to work!

thanks in advanc
 
B

Bearacade

Sorry, I am not understanding your terms

So if r_1_layp and r_2_layp is lower than 2, you buy two shares?

what about this lay_price thing? From your formula, you are basicall
saying, that r_1_layp and r_2_layp must be lower than 2 AND laypric
must be either lower than r_1_layp or lower than r_2_layp...

can you clarify
 
S

spreadbet

Hi thanks for replying - yes what I want to do is buy two shares i
r_1_layp and
r_2_layp are under 2 but only if they are both under 2.

lay_price is the price of the share in real time. its the second par
of the formula that is confusing me!

again thanks for replying this has me tearing my hair out
 
B

Bearacade

Maybe it's a communication problem. I am still not understanding what
it is you require.

If r_1_layp *AND* r_2_layp is less than 2 then you want to show a 2,
else a 0?

if that is the cast, just do =IF(AND(r_1_layp<=2, r_2_layp<=2), 2, 0)

is there another condition you want? something to do with the layprice
being lower than or equal to r_1_layp *OR* lower than or equal to
r_2_layp?
 
S

spreadbet

Thanks for being patient I am going to think through the best way to
explain it and will post it tomorrow basically the condition I want is
for there to be no bet unless both prices are less than 2 and the bets
on bothe must be placed when the price is under 2

r_1 is the first share
r_2 is the second share

and lay_Price is the actual price

please stick with me untill I can explain it better! thanks have a
good evening
 
S

spreadbet

Thanks for being patient I am going to think through the best way to
explain it and will post it tomorrow basically the condition I want is
for there to be no bet unless both prices are less than 2 and the bets
on bothe must be placed when the price is under 2

r_1 is the first share
r_2 is the second share

and lay_Price is the actual price

please stick with me untill I can explain it better! thanks have a
good evening
 
Top