some basic questions about some code and CustomClose

Forums ProRealTime English forum ProBuilder support some basic questions about some code and CustomClose

Tagged: 

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

    I come from a C# background and so I understand 90% of the code but I have some questions about what some of the below code means:

    Source: https://www.prorealcode.com/prorealtime-indicators/kase-dev-stop-v3/

    mmax=max(max(high,high[1]),pricc[2]) Does the high[1] mean the previous high and the pricc[2] mean 2 prices ago? Also I’m not understanding the switching between pricc and price. It says pricc=customclose but there is no definition for the custom close anywhere and I can’t tell if the pricc is a misspelled version of price. Any ideas?

     

    #91433

    How you describe [1] and [2] is correct.

    CUSTOMCLOSE means it uses whatever value is set in the indicator settings window – so you can select close, open, median price, total price etc to be used in the indicator.

    #91462

    What about the line below?

    once price=close*100
    The code keeps switching between price and pricc and for lines like this below then price will always be chosen since it is going to be 100 times the close
    price=max(price,high)
    #91467

    I’ve not looked at the code in detail but ONCE means that line is only read on the very first run through of the code and ignored every candle after that.

    1 user thanked author for this post.
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