Accès aux donnée renko

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #225779 quote
    LurubuLurubu
    Participant
    Senior
    Bonjour, comment écrire le haut et le bas d’un renko. Je voudrai distinguer un renko rouge d’un vert. Merci d’avance
    #225784 quote
    JSJS
    Participant
    Master

    Hi,

    There is a Renko indicator called “Renko Bricks with Wicks” made by Nicolas…

    //PRC_Renko Bricks with Wicks | indicator
    //22.05.2017
    //Nicolas @ www.prorealcode.com
    //Sharing ProRealTime knowledge
    
    //---settings
    //boxsize=20 //renko bricks size in points/pips
    //transparency=50 //brick colours alpha
    //wicksize=1 //width of wicks
    //---end of settings
    
    size=boxsize*pointsize
    
    once upbox = close
    once downbox = close - size
    once lowwick = close*100
     
    IF close > upbox + size THEN
    upbox = upbox + size
    downbox = downbox + size
    r=0
    g=200
    begin=barindex
    highwick=close
    wickbar=barindex-round((barindex-begin[1])/2)
    ELSIF close < downbox - size THEN
    upbox = upbox - size
    downbox = downbox - size
    r=200
    g=0
    begin=barindex
    wickbar=barindex-round((barindex-begin[1])/2)
    ENDIF
    
    //saving current high/low
    highwick=max(high,highwick)
    lowwick=min(low,lowwick)
    
    //compute wicks at each new contrarian brick
    if r>0 and r[1]=0 then
    //new red brick
    drawrectangle(wickbar,highwick,wickbar+wicksize,upbox[1]) coloured(r[1],g[1],0)
    lowwick=low*100
    highwick=0
    endif
    if r=0 and r[1]>0 then
    //new green brick
    drawrectangle(wickbar,lowwick,wickbar+wicksize,downbox[1]) coloured(r[1],g[1],0)
    lowwick=low*100
    highwick=0
    endif
    //compute wicks at each new same brick
    if r>0 and r[1]>0 and lastdrawn<>wickbar then
    //new red brick
    if highwick>upbox[1] then
    drawrectangle(wickbar,highwick,wickbar+wicksize,upbox[1]) coloured(r[1],g[1],0)
    endif
    lastdrawn=wickbar
    lowwick=low*100
    highwick=0
    endif
    if r=0 and r[1]=0 and lastdrawn<>wickbar then
    //new green brick
    if lowwick<downbox[1] then
    drawrectangle(wickbar,lowwick,wickbar+wicksize,downbox[1]) coloured(r[1],g[1],0)
    endif
    lastdrawn=wickbar
    lowwick=low*100
    highwick=0
    endif
    
    //draw renko candlesticks
    drawcandle(upbox,upbox,downbox,downbox)coloured(r,g,0,min(transparency,255))
    
    RETURN
    
    Scherm­afbeelding-2023-12-28-om-21.44.18.png Scherm­afbeelding-2023-12-28-om-21.44.18.png PRC_Renko-bricks-with-wicks.itf
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

Accès aux donnée renko


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
Lurubu @lurubu Participant
Summary

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

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 12/28/2023
Status: Active
Attachments: 2 files
ProRealCode ProRealCode
Loading...