I want to find if condition has been met in the last few bars

Forums ProRealTime English forum ProOrder support I want to find if condition has been met in the last few bars

Viewing 11 posts - 1 through 11 (of 11 total)
  • #181610

    I want to find if a condition has been met in the last few bars .

    Is there something similar to Lowest[N](close ) or could somebody give a code to do this .

    #181613

    a = summation[5](close > close[1])

    “a” will contain how many times the condition “close > close[1]” was met within the last 5 bars

    2 users thanked author for this post.
    #181618
    #181625

    what I am wanting to find whether an as yet undefined condition has been met in the last few bars.

    #181627

    you mean like, have any unicorns been discovered within last 5 bars?

    you have to tell the summation what to look for (unless i have completely misunderstood ???)

    1 user thanked author for this post.
    #181662

    So would i write

    a=summation[5](unicorns)

    #181664

    You got it. Easy peasy.

    Let us know the result.

    1 user thanked author for this post.
    #181678
    JS

    Haha, nice.

    #181709

    I wanted to find when the price is rejected at a resistance level more than once and this gave a result

    a=supertrend[3,10]
    b=a-close
    ind=0
    If b<2.5 AND b>0 Then
    ind=1
    Endif
    d=summation[7](ind)
    Return d

    #181717

    You should now use that new instruction: BARSSINCE ! Enjoy.

    #181725

    Nice !

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

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