Within % of All Time High

Optuma Forums Optuma Scripting Within % of All Time High

  • This topic has 4 replies, 3 voices, and was last updated 1 year ago by AvatarJoe.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #48655
    AvatarLuke
    • Topics: 3
    • Replies: 3
    • Posts: 6

    Hi, I’m having trouble getting a scan to return stocks within a % of all time high. Thanks

    #48667
    DarrenDarren
    • Topics: 62
    • Replies: 503
    • Posts: 565

    Hi Luke,

    Use the HIGHESTHIGH() function set to All Time, and then multiply by the required value, such as this for within 15%:

    CLOSE() > (HIGHESTHIGH(RANGE=All Time) * 0.85)

    For more examples of using the HIGHESTHIGH and LOWESTLOW functions see this forum post:

    New 52 week highs and lows

    1 user thanked author for this post.
    #55329
    AvatarJoe
    • Topics: 0
    • Replies: 2
    • Posts: 2

    Hi Darren

    If I wanted to scan for those that have closed within a range of the high, ie say between 30% and 60% of a recent high, how would I adjust that? Cant seem to get this to work.

    Thanks for your help.

    #55335
    DarrenDarren
    • Topics: 62
    • Replies: 503
    • Posts: 565

    Hi Joe,

    To calculate the % from eg a 26 week high you can use the following in a watchlist column, which will give you a value:

    For a scan you would need to set the parameters for the ratio, so the last line would be R1 > 0.3 and R1 < 0.6 for your 30%/60% example, giving the true/false column here:

    Capture

     

    #55365
    AvatarJoe
    • Topics: 0
    • Replies: 2
    • Posts: 2

    That is perfect, thanks Darren!

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

Pin It on Pinterest

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close