Conversion de la strategie SSL CHANNEL CROSS de Tradingview

Forums ProRealTime forum Français Support ProBuilder Conversion de la strategie SSL CHANNEL CROSS de Tradingview

Viewing 4 posts - 1 through 4 (of 4 total)
  • #193310

    Voici une strategie simple basée sur le croisement de 2 lignes mais qui semble interessante au vu des backtests effectués

    code TradingView

    //@version=4
    strategy(“SSL Channel Cross”, overlay=true)
    period=input(title=”Period”, defval=10)
    len=input(title=”Period”, defval=10)
    smaHigh=sma(high, len)
    smaLow=sma(low, len)
    Hlv = 0
    Hlv := close > smaHigh ? 1 : close < smaLow ? -1 : Hlv[1]
    sslDown = Hlv < 0 ? smaHigh: smaLow
    sslUp = Hlv < 0 ? smaLow : smaHigh

    plot(sslDown, linewidth=2, color=color.red)
    plot(sslUp, linewidth=2, color=color.lime)

    longCondition = crossover(sslUp, sslDown)
    shortCondition = crossunder(sslUp, sslDown)

    if (longCondition)
    strategy.close(“Short”, strategy.long)
    strategy.entry(“Long”, strategy.long)

    if (shortCondition)
    strategy.close(“Long”, strategy.long)
    strategy.entry(“Short”, strategy.short)

    Merci d’avance

    #193314

    J’ai omis de specifier que la conversion est demandée, bien sur,  afin d’etre utilisée sur PRT

    Je rajoute un premier resultat des derniers backtests

    #193315

    Tradingview-SSL-CHANNEL-STRATEGIE-RESULTATS

    #193323
Viewing 4 posts - 1 through 4 (of 4 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login