52 week low in the past

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #231955 quote
    marco7630
    Participant
    New

    Hello,

    I would like to see all the stocks that had a 52 week low close on the 10th of novembre 2023.

    Thanks

     

    gr Marco

    #231956 quote
    robertogozzi
    Moderator
    Master

    Try this one:

    Timeframe(Weekly)
    Wlow = close
    FOR j = 1 TO 51
       Wlow = min(Wlow,close[j])
    NEXT
    IF Date > 20231110 THEN
       Wlow = 999999999
    ENDIF
    //
    Timeframe(Daily)
    myLow = Wlow
    Cond  = 0
    FOR i = 0 TO 230
       IF Date[i] = 20231110 THEN
          IF close[i] = myLow[i] THEN
             IF low[i] <> high[i] THEN
                Cond = close[i]
                break
             ENDIF
          ENDIF
       ENDIF
    NEXT
    SCREENER[Cond](Cond AS "52w low")
    Iván González thanked this post
    #232008 quote
    marco7630
    Participant
    New

    Hi Roberto,

    Thanks.

     

    Unfortunately it does not work. The results i get are not 52 week lows on the 10th of november 23. In attachment you find the results.

    1 stock of which i am sure it was 52 week low on that date is not in the list. It is: VUZI

    Can you check? Thanks

     

    gr Marco

    2024-04-29_08-29-31.png 2024-04-29_08-29-31.png
    #232309 quote
    marco7630
    Participant
    New

    Hi Roberto,

    Could you have a look. Thanks

     

    gr Marco

    #232359 quote
    robertogozzi
    Moderator
    Master

    You asked for the lowest CLOSE, this is the code for the lowest LOW:

    Timeframe(Weekly)
    Wlow = low
    FOR j = 1 TO 51
       Wlow = min(Wlow,low[j])
    NEXT
    IF Date > 20231110 THEN
       Wlow = 999999999
    ENDIF
    //
    Timeframe(Daily)
    myLow = Wlow
    Cond  = 0
    FOR i = 0 TO 230
       IF Date[i] = 20231110 THEN
          IF low[i] = myLow[i] THEN
             IF low[i] <> high[i] THEN
                Cond = low[i]
                break
             ENDIF
          ENDIF
       ENDIF
    NEXT
    SCREENER[Cond](Cond AS "52w low")

    In addition, try replacing any occurrence of DATE (closing date) by OPENDATE (opening date).

    #232430 quote
    marco7630
    Participant
    New

    Thanks Roberto

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

52 week low in the past


ProScreener: Market Scanners & Detection

New Reply
Author
author-avatar
marco7630 @marco7630 Participant
Summary

This topic contains 5 replies,
has 2 voices, and was last updated by marco7630
1 year, 10 months ago.

Topic Details
Forum: ProScreener: Market Scanners & Detection
Language: English
Started: 04/25/2024
Status: Active
Attachments: 1 files
Logo Logo
Loading...