// Definizione dei parametri del codice
DEFPARAM CumulateOrders = False // Posizioni cumulate disattivate
hig = high
lo=low
myid4high = hig<high[3] and hig[1]<high[3] and hig[2]<high[3]
myid4low =lo>low[3] and lo[1]> low[3] and lo[2]>low[3]
myID4= myid4high and myid4low
this is the code of inside like you can see on pic, so i want to go short at break out of low of thirth candelstick ( the candelstick that has the lowest of 4 candlesticks (line red)
can you help me, please
thanks
Keywords like “cumulateorders”, “buy”, “sell” only work for probacktest/proorder, not for probuilder limited to indicators programming, so we move this topic from “pro-builder” forum to “pro-order” forum, where it has more chances to attract suggestions from others users working on trading strategies too.
You can give a try with this code:
// Definizione dei parametri del codice
DEFPARAM CumulateOrders = False // Posizioni cumulate disattivate
hig = high
lo=low
myid4high = hig<high[3] and hig[1]<high[3] and hig[2]<high[3]
myid4low =lo>low[3] and lo[1]> low[3] and lo[2]>low[3]
myID4= myid4high and myid4low
if myID4 then
BUY 1 CONTRACT AT highest[4](high) stop
SELLSHORT 1 CONTRACT AT lowest[4](low) stop
endif