Trade rule 1:
If the last bar was a bullish bar, enter a buy order when a new bar open.
IF Close > Open, Then Enter Market buy.
Trade rule 2:
When a new bar open, close last opened trade.
The problem is, when rule1 place a trade and rule2 immediately close it when a new bar formed!