## Comment on Code your Technical Analysis strategy

commented on 24 May 2013, 09:31 AM

Hi The strategy is given below with the logic.

Sell Exit Expression-0

Sell Expression-

HIGH>=OPEN AND
OPEN>CLOSE AND
CLOSE>=LOW AND
LOW<REF(LOW,1) AND
CLOSE<REF(LOW,1) AND
CLOSE>=REF(OPEN,2) AND
REF(OPEN,3)=REF(OPEN,2)AND
REF(HIGH,1)>=REF(OPEN,1) AND
REF(OPEN,1)>=REF(CLOSE,1) AND
REF(CLOSE,1)>=REF(LOW,1) AND
REF(LOW,1)>=REF(OPEN,2) AND
REF(HIGH,1)<=REF(CLOSE,2) AND
REF(HIGH,2)>REF(CLOSE,2) AND
REF(CLOSE,2)>REF(OPEN,2) AND
REF(OPEN,2)>REF(LOW,2) AND
REF(HIGH,3)>=REF(OPEN,3) AND
REF(OPEN,3)>REF(CLOSE,3) AND
REF(CLOSE,3)>=REF(LOW,3) AND
REF(HIGH,2)>REF(HIGH,3) AND
REF(HIGH,2)>REF(HIGH,4) AND
REF(HIGH,2)>REF(HIGH,5) AND
REF(HIGH,2)>REF(HIGH,5) AND
REF(HIGH,2)>REF(HIGH,6)

Expression complete.

LOGIC OF EXPRESSION

HIGH IS GREATER THAN OR EQUAL TO OPEN PRICE AND(PRESENT CANDLE )
OPEN IS GREATER THAN CLOSE AND
CLOSE IS GREATER THAN OR EQUAL TO LOW PRICE AND
LOW IS LESS THAN PREVIOUS CANDLE LOW AND
CLOSE IS LESS THAN PREVIOUS CANDLE LOW AND
CLOSE IS GREATER THAN OR EQUAL TO PRIOR TWO CANDLE OPEN AND
PRIOR THREE CANDLE OPEN IS EQUAL TO PRIOR TWO CANDLE OPENING PRICE AND
PREVIOUS CANDLE HIGH IS GREATER THAN OR EQUAL TO PREVIOUS CANDLE OPENING PRICE AND
PREVIOUS CANDLE OPENING PRICE IS GREATER THAN OR EQUAL TO PREVIOUS CANDLE CLOSING PRICE AND PREVIOUS CANDLE CLOSING PRICE IS GREATER THAN OR EQUAL TO PREVIOUS CANDLE LOW PRICE AND PREVIOUS CANDLE LOW IS GREATER THAN OR EQUAL TO PRIOR TWO CANDLE OPENING PRICE AND
PREVIOUS CANDLE HIGH PRICE IS LESS THAN OR EQUAL TO PRIOR TWO CANDLE CLOSING PRICE AND
PRIOR TWO CANDLE HIGH PRICE IS GREATER THAN PRIOR TWO CANDLE CLOSING PRICE AND
PRIOR TWO CANDLE CLOSING PRICE IS IS GREATER THAN PRIOR TWO CANDLE OPENING PRICE AND
PRIOR TWO CANDLE OPENING PRICE IS GREATER THAN PRIOR TWO CANDLE LOW PRICE AND
PRIOR THREE CANDLE HIGH PRICE IS GREATER THAN OR EQUAL TO PRIOR THREE CANDLE OPENING PRICE. PRIOR THREE CANDLE OPENING PRICE IS GREATER THAN PRIOR THREE CANDLE CLOSING PRICE AND
PRIOR THREE CANDLE CLOSING PRICE IS GREATER THAN OR EQUAL TO PRIOR THREE CANDLE LOW PRICE AND PRIOR TWO CANDLE HIGH PRICE IS GREATER THAN PRIOR THREE CANDLE HIGH PRICE AND
PRIOR TWO CANDLE HIGH PRICE IS GREATER THAN PRIOR FOURTH CANDLE HIGH PRICE AND
PRIOR TWO CANDLE HIGH PRICE IS GREATER THAN PRIOR FIFTH CANDLE HIGH PRICE AND
PRIOR TWO CANDLE HIGH PRICE IS GREATER THAN PRIOR FIFTH CANDLE HIGH PRICE AND
PRIOR TWO CANDLE HIGH PRICE IS GREATER THAN PRIOR SIXTH CANDLE HIGH PRICE.

Here we need to have the signal/Alert on the candle which denotes expression-high/low/close /open.
Then we need to take the position on the next candle as all the conditions are fulfilled.