ADX from x days back

Forums ProRealTime English forum ProOrder support ADX from x days back

Viewing 8 posts - 1 through 8 (of 8 total)
  • #42175

    Is there a possibility to refer to the ADX of x days back? So I maybe want to know what the ADX[14] was last friday. Can this be done?

    #42176

    Just save the ADX value in a variable and if current day is Friday?

    #42177

    Yes, I thought about this option. Thought there maybe was another way but thank you. I will to it like this.

    #42178

    I guess you ask because you might think the [14] syntax is “taken” by nature of adx[], and can’t use the [x] on top of this to look back x days before, but PRT language allows you to cumulate both sets of brackets, so… adx[14][x] works (as long as your x is a positive integer of course)

    1 user thanked author for this post.
    #42183

    Hmm but if I want to have this condition rolling, say: Compare adx[14] with adx[14] x bars ago. It is not so easy to save the value x bars ago in a variable. Any idea Nicolas?

    #42186

    I got an idea. I can put a 1 period average on the ads and then refer to the average x periods back. This should work, shouldn’t it?

    #42187

    Why not? 🙂

    #42193

    It worked with a 1-period average but Noobywans solutions seems more elegant. I thought cumulating brackets wasn’t allowed. Thanks for this advice!

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

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