Proximity to pivot points

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #203496 quote
    brunoasoliveira
    Participant
    New

    Hello,

    I’m needing some help please. I made a screener to identify stocks with the price near (my fst test is 20%) the pivot points but my problem is that i’m using pre/post market period. When i’m using pivot points, I defined the indicator in the chart to pre and post martket data, which the indicator uses the high and low of the previous day considering the pre and post market time, but, the close of the previous day is auto defined with the close price at the end of the regular time, meaning 16:00 est. <span class=”HwtZe” lang=”en”><span class=”jCAhz ChMk0b”><span class=”ryNqvb”>For me it is not congruent but i need to know how I identify the close price when the market closes at the regular time i.e. 4 p.m est.</span></span></span>

    Many thanks in advance. Here is my code:

    A = DHigh(1)
    L = DLow(1)
    C = DClose(1)

    //////Pivot Point
    Pp = ((A + L + C)/3)
    //R1
    R1 = (2 * Pp)- L
    //R2
    R22 = Pp + A – L
    //R3
    R3 = A + 2 * (Pp – L)
    //S1
    S1 = (2 * Pp)- A
    //S2
    S2 = Pp – A + L
    //S3
    S3 = L – 2 * (A – Pp)

    ////Proximity to S3
    c1 = Close <= S3 + S3 *((20/100)*S3) and Close >= S3 – S3 *((20/100)*S3)
    ////Proximity to S2
    c2 = Close <= S2 + S2 *((20/100)*S2) and Close >= S2 – S2 *((20/100)*S2)
    ////Proximity to S1
    c3 = Close <= S1 + S1 *((20/100)*S1) and Close >= S1 – S1 *((20/100)*S1)
    ////Proximity to R3
    c4 = Close <= R3 – R3 * ((20/100)*R3) and Close >= R3 + R3 * ((20/100)*R3)
    ////Proximity to R2
    c5 = Close <= R22 – R22 * ((20/100)*R22) and Close >= R22 + R22 * ((20/100)*R22)
    ////Proximity to R1
    c6 = Close <= R1 – R1 * ((20/100)*R1) and Close >= R1 + R1 * ((20/100)*R1)
    ///Proximity to Pp
    c7 = Close <= Pp – Pp * ((20/100)*Pp) AND Close >= Pp + Pp * ((20/100)*Pp)

    SCREENER[C1 OR C2 Or C3 Or C4 Or C5 Or C6 Or C7] (Criteria as “Pivot”)

    #203497 quote
    robertogozzi
    Moderator
    Master

    This is how to store the CLOSE price at 16:00 (4pm):

    IF Time = 160000 THEN
       myCLOSE = close
    ENDIF

    them you can use myCLOSE anywhere you need it.

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

Proximity to pivot points


ProBuilder: Indicators & Custom Tools

New Reply
Author
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by robertogozzi
3 years, 3 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 11/04/2022
Status: Active
Attachments: No files
Logo Logo
Loading...