X number of consecutive candles above MA (Tradingview Strategy)

Forums ProRealTime English forum ProOrder support X number of consecutive candles above MA (Tradingview Strategy)

Viewing 5 posts - 1 through 5 (of 5 total)
  • #95505

    Hi all

    Are you able to please assist with converting the attached TradingView script strategy to ProBuilder please?

    System essentially does the following:

    Long entries:

    • Looks back at x number of consecutive candles’ closing price and if it forms x number of higher closes above the simple moving average enter long
    • Uses take profit and stop loss

    Short entries

    • Looks back at x number of consecutive candles’ closing price and it it forms x number of lower lows below the simple moving average enter short
    • uses take profit and stop loss

    Attached system has a lookback of 10 candles but that way too much. Maximum lookback of 5 candles is required.

     

    Thanks heaps, please advise any further questions. Cheers

    #95675

    Wow the code is huge and not well formatted, I think that we can reduce it a lot.
    You are talking about “lower lows” while short conditions are testing lower close, is that ok?

    #95676

    Yeah cheers any efficiencies you can add would be appreciated.

    Yeah correct, should read lower closes. Thank you

    #95790

    Below is the code compatible with ProBacktest / ProOrder: (consecutive candles are set to 5 and moving average period to 50, but you can change these settings at the beginning of the code).

     

    #95836

    Thank you

Viewing 5 posts - 1 through 5 (of 5 total)

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