// Définition des paramètres du code
DEFPARAM CumulateOrders = False // Cumul des positions désactivé
// Graphique 1 heure
// Conditions pour ouvrir une position acheteuse
timeframe(1 hour,updateonclose)
stochastichoraire1 = WilderAverage[3](Stochastic[34,1](totalPrice))
stochastichoraire2 = WilderAverage[5](WilderAverage[3](Stochastic[34,1](totalPrice)))
c1 = (stochastichoraire1 CROSSES OVER stochastichoraire2)
// Graphique 15 minutes
// Conditions pour ouvrir une position acheteuse
timeframe(15 minutes,updateonclose)
stochasticminute1 = WilderAverage[3](Stochastic[34,1](totalPrice))
stochasticminute2 = WilderAverage[5](WilderAverage[3](Stochastic[34,1](totalPrice)))
c2 = (stochasticminute1 CROSSES OVER stochasticminute2)
// Graphique 1 minute
// Conditions pour ouvrir une position acheteuse
timeframe(default)
indicator1 = WilderAverage[3](Stochastic[34,1](totalPrice))
indicator2 = WilderAverage[5](WilderAverage[3](Stochastic[34,1](totalPrice)))
c3 = (indicator1 CROSSES OVER indicator2)
IF c1 and c2 and c3 THEN
BUY 1 CONTRACT AT MARKET
ENDIF
// Stops et objectifs
SET STOP pLOSS 10
SET TARGET pPROFIT 10