Rsi cycle indicator converted in pro real-time from tradingviiew codee

Forums ProRealTime English forum ProBuilder support Rsi cycle indicator converted in pro real-time from tradingviiew codee

  • This topic has 4 replies, 2 voices, and was last updated 1 year ago by avataryas.
Viewing 5 posts - 1 through 5 (of 5 total)
  • #206475
    yas

    //@version=3

    study(“Better RSI”)

    cycler = na

    myPeriod = input(defval = 14, type=integer, title=”Period”)

    src = input(close, type=source)

    showCycler = input(true,’Show cycler?’)

    lvl = input(50, ‘Cycler level on plot’)

    myRSI = rsi(src, myPeriod)

    firstcolor = color(white,10)

    secondcolor = color(orange,50)

    thirdcolor = gray

     

    h30 = hline(30,color=firstcolor,linestyle=dashed,title=’Low’)

    h70 = hline(70,color=firstcolor,linestyle=dashed,title = ‘High’)

    h20 = hline(20, color=secondcolor,linestyle = solid,title=’Second low’)

    h80 = hline(80, color=secondcolor,linestyle=solid,title=’Second high’)

    //h50 = hline(50, color=orange, title= ‘Mid line’)

    h40 = hline(40, color = thirdcolor, linestyle = dashed,title = ’40 line’)

    h60 = hline(60, color = thirdcolor, linestyle = dashed, title = ’60 line’)

    //fill(h30,h20,red,transp=80, title=’Oversold color’)

    //fill(h80,h70,red,transp=80, title=’Overbought color’)

    fill(h30,h70,fuchsia,transp=90, title= ‘Background color’)

    //cond =? red:white

    RSIplot = plot(myRSI,color=white,linewidth=2,transp=0,title=”RSI”)

    plot(myRSI >= 70 or myRSI<= 30? myRSI:na,style = linebr,linewidth=3,color=red,transp = 0, title = ‘Oversold color’)

     

    //cycler

    cycler := if myRSI > 69 or myRSI< 31

    a = if myRSI > 69

    1 // bullish

    else

    2 // bearish

    a

    else

    b = if (nz(cycler[1]) == 1 and myRSI < 39) or (nz(cycler[1]) == 2 and myRSI > 61)

    0

    else

    nz(cycler[1])

    b

     

     

    mycolor = if cycler == 0

    white

    else

    c = if cycler == 1

    lime

    else

    red

    c

     

    plot(showCycler? lvl:na, style = line, color = mycolor, transp = 30, linewidth=2, title = ‘Cycler colors’)

     

     

     

    #206566
    yas

    Is it possible that we can get the above code converted, please

    #206580
    yas

    Can someone help me convert this into pro real time please 🙏

    #206660

    Sorry but I didn’t want to be late at new year’s party, so I postponed your request 😆

    Here is the translated code for the BetterRSI code you submit:

     

    #206670
    yas

    Thanks mate much appreciated and happy new year

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