Minimum value over a look back period

Optuma Forums Optuma Scripting Minimum value over a look back period

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #65133
    Deepak
    • Topics: 53
    • Replies: 40
    • Posts: 93

    Hiii Sir,

    I know there is a min function in Optuma which compares 2 values however what if we want to know a minimum value over a lookback period is it possible.

    For example i want to know if v3 is minimum over 21 days.

    #65134
    Matthew
    • Topics: 5
    • Replies: 377
    • Posts: 382

    Hi,

    The Vergence() function produces a Boolean result, so it’s either True or False, there isn’t really a minimum to look for in the script you have posted. (Also MIN requires two reference points, so the last line would not work either).

    Can you provide a screen shot of the setup you are trying to identify?

    #65141
    Deepak
    • Topics: 53
    • Replies: 40
    • Posts: 93

    Hii Sir,

    My idea is to see if BB are squeezing and if they are squeezing is todays value is minimum value in past 21 days.

    Regards,
    Deepak

    #65142
    Matthew
    • Topics: 5
    • Replies: 377
    • Posts: 382

    Which value do you mean though?  Do you mean the value of the charts close?  The value of the Bolinger Bands High, or Low, or the difference between the two BB lines?

    You would use the ValueWhen() function, with V3 as the trigger, but I am not sure which value to reference?

    Once the ValueWhen() function was setup, you could wrap a LowestLow() function around it to see if it is the lowest value over the last 21 days.

    This example is using the difference between the BB High – Low values.

     

    • This reply was modified 3 weeks ago by Matthew.
    1 user thanked author for this post.
    #65145
    Jeffrey A.
    • Topics: 39
    • Replies: 63
    • Posts: 102

    Would using Bollinger “Bandwidth” tool also help identify the areas?

    https://help.optuma.com/kb/faq.php?id=271

    1 user thanked author for this post.
Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.

Pin It on Pinterest