Buy condition

#1
Hi Ami Broker experts,

I need help with the buy condition in the following code:

Code:
O1 = Ref(O,-1);O2 = Ref(O,-2);O3 = Ref(O,-3);O4 = Ref(O,-4);
H1 = Ref(H,-1);H2 = Ref(H,-2);H3 = Ref(H,-3);H4 = Ref(H,-4);
C1 = Ref(C,-1);C2 = Ref(C,-2);C3 = Ref(C,-3);C4 = Ref(C,-4);
L1 = Ref(L,-1);L2 = Ref(L,-2);L3 = Ref(L,-3);L4 = Ref(L,-4);

Liquidity = MA( V, 21 );

				
ThreeBlackCrows = (O>C*1.01) AND (O1>C1*1.01) AND (O2>C2*1.01) AND (C<C1) AND (C1<C2) AND (O>C1) AND (O<O1) AND (O1>C2) AND (O1<O2)AND (((C-L)/(H-L))<.2) AND (((C1-L1)/(H1-L1))<.2) AND (((C2-L2)/(H2-L2))<.2)  AND C >=1.0 AND Liquidity >= 1000000;


Buy = ???
Sell = Barssince(buy)==10;
I would like to buy the share if a ThreeBlackCrows appear and the stock price rises above the Three Black Crows Pattern.

Please help

Regards

Michael