EOD Pivots (not working with Vers. 12)

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #262419 quote
    ZiggyZiggy
    Participant
    Average

    Can anyone please double check this. I have tried to solve it somehow, but still it does not return anything. Version 12. Was just looking for a broader Pivots in one indicator only. TIA Link https://www.prorealcode.com/prorealtime-indicators/eod-cash-market-pivots-index-trading/

    #262421 quote
    Iván GonzálezIván González
    Moderator
    Legend

    Try this:

    DEFPARAM drawonlastbaronly = true
    
    Ext = 3
    
    yHigh  = DHigh(1)
    yLow   = DLow(1)
    yClose = DClose(1)
    h2 = DHigh(2)
    l2 = DLow(2)
    
    P    = (yHigh + yLow + yClose) / 3
    CBOL = yClose + ((yHigh - yLow) * 1.1) / 2
    CBOS = yClose - ((yHigh - yLow) * 1.1) / 2
    R3 = yHigh + 2 * (P - yLow)
    R02 = P + (yHigh - yLow)
    R1 = 2 * P - yLow
    S1 = 2 * P - yHigh
    S2 = P - (yHigh - yLow)
    S3 = yLow - 2 * (yHigh - P)
    
    x1 = barindex - IntradayBarIndex
    x2 = barindex + Ext
    Voffset = 2 * pipsize
    
    DRAWSEGMENT(x1, P,  x2, P)  COLOURED(95,95,100) STYLE(line, 2)
    DRAWSEGMENT(x1, R3, x2, R3) COLOURED(235,5,30) STYLE(line, 1)
    DRAWSEGMENT(x1, R02, x2, R02) COLOURED(235,5,30) STYLE(line, 1)
    DRAWSEGMENT(x1, R1, x2, R1) COLOURED(235,5,30) STYLE(line, 1)
    DRAWSEGMENT(x1, S1, x2, S1) COLOURED(30,235,5) STYLE(line, 1)
    DRAWSEGMENT(x1, S2, x2, S2) COLOURED(30,235,5) STYLE(line, 1)
    DRAWSEGMENT(x1, S3, x2, S3) COLOURED(30,235,5) STYLE(line, 1)
    
    DRAWSEGMENT(x1, CBOL, x2, CBOL) COLOURED(255,140,0) STYLE(dottedline, 1)
    DRAWSEGMENT(x1, CBOS, x2, CBOS) COLOURED(255,140,0) STYLE(dottedline, 1)
    
    DRAWSEGMENT(x1, yHigh,  x2, yHigh)  COLOURED(45,75,240) STYLE(dottedline, 1)
    DRAWSEGMENT(x1, yLow,   x2, yLow)   COLOURED(45,75,240) STYLE(dottedline, 1)
    DRAWSEGMENT(x1, yClose, x2, yClose) COLOURED(120,120,120) STYLE(dottedline, 1)
    DRAWSEGMENT(x1, h2, x2, h2) COLOURED(45,75,240,120) STYLE(dottedline, 1)
    DRAWSEGMENT(x1, l2, x2, l2) COLOURED(45,75,240,120) STYLE(dottedline, 1)
    
    DRAWTEXT("Pivot", x2, P + Voffset, SansSerif, Bold, 11) COLOURED(95,95,100)
    DRAWTEXT("R3", x2, R3 + Voffset, SansSerif, Bold, 10) COLOURED(235,5,30)
    DRAWTEXT("R2", x2, R02 + Voffset, SansSerif, Bold, 10) COLOURED(235,5,30)
    DRAWTEXT("R1", x2, R1 + Voffset, SansSerif, Bold, 10) COLOURED(235,5,30)
    DRAWTEXT("S1", x2, S1 + Voffset, SansSerif, Bold, 10) COLOURED(30,235,5)
    DRAWTEXT("S2", x2, S2 + Voffset, SansSerif, Bold, 10) COLOURED(30,235,5)
    DRAWTEXT("S3", x2, S3 + Voffset, SansSerif, Bold, 10) COLOURED(30,235,5)
    DRAWTEXT("CBOL", x2, CBOL + Voffset, SansSerif, Bold, 10) COLOURED(255,140,0)
    DRAWTEXT("CBOS", x2, CBOS + Voffset, SansSerif, Bold, 10) COLOURED(255,140,0)
    DRAWTEXT("PDH", x2, yHigh + Voffset, SansSerif, Bold, 9) COLOURED(45,75,240)
    DRAWTEXT("PDL", x2, yLow + Voffset, SansSerif, Bold, 9) COLOURED(45,75,240)
    DRAWTEXT("PDC", x2, yClose + Voffset, SansSerif, Bold, 9) COLOURED(120,120,120)
    DRAWTEXT("2DH", x2, h2 + Voffset, SansSerif, Bold, 9) COLOURED(45,75,240)
    DRAWTEXT("2DL", x2, l2 + Voffset, SansSerif, Bold, 9) COLOURED(45,75,240)
    
    RETURN
    


    robertogozzi and Ziggy thanked this post
Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.
ProRealAI ProRealAI New

Stuck on this ProBuilder code?

Describe what this topic is trying to build, in plain English, and ProRealAI writes the ProRealTime™ indicator, screener or system for you.

Available in 7 languages
Try ProRealAI

EOD Pivots (not working with Vers. 12)


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
Ziggy @ziggy Participant
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by Iván GonzálezIván González
2 months, 1 week ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 07/08/2026
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...