little discrepancy between the code and the default PRT pivot points

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #222541 quote
    Inertia
    Participant
    Master
    // POINT PIVOT HEBDOMADAIRE
    IF dayofweek < dayofweek[1] THEN
    weekhigh = prevweekhigh
    weeklow = prevweeklow
    weekclose = prevweekclose
    prevweekhigh = high
    prevweeklow = low
    ENDIF
     
    prevweekhigh = max(prevweekhigh, high)
    prevweeklow = min(prevweeklow, low)
    prevweekclose = close
     
    PPWeek = (weekhigh + weeklow + weekclose) / 3
      
    
    Res3 = Res1 + (weekhigh - weeklow)
    Res2 = PPWeek + weekhigh - weeklow
    Res1 = (2 * PPWeek) - weeklow
    Sup1 = (2 * PPWeek) - weekhigh
    Sup2 = PPWeek - (weekhigh - weeklow)
    Sup3 = Sup1 - (weekhigh - weeklow)
    
    Return Res1        AS "Res1"      coloured("green"), Res2        AS "Res2"      coloured("green"), Res3        AS "Res3"      coloured("green"), PPWeek        AS "Pivot"      coloured("black"), Sup1        AS "Sup1"      coloured("red"), Sup2        AS "Sup2"      coloured("red"), Sup3        AS "Sup3"      coloured("red"), PPWeek COLOURED(50,50,220) AS"Pivot Week"
    

    Hi, there is couple of gap pts between the code attached end the PRT point pivots.

    Any idea why?

    Thank you.

    #222542 quote
    Inertia
    Participant
    Master

    here is a link >

    #222666 quote
    Inertia
    Participant
    Master

    Hello all,

    Question about multiple triggers versus one single line to trigger a trade.

    Attached are two pictures with both the same trigger: Point Pivots mS1M (33635)

    One works fine, not the other (with more lines in it).

    Any idea why please?

    Thank you

    Damien

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

little discrepancy between the code and the default PRT pivot points


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
Inertia @inertia Participant
Summary

This topic contains 2 replies,
has 1 voice, and was last updated by Inertia
2 years, 3 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 10/17/2023
Status: Active
Attachments: 3 files
Logo Logo
Loading...