Heiken Ashi smoothed

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #17559 quote
    torkelabtorkelab
    Participant
    Senior

    Hi there!

    I´m a newbie and this is my first indicator query 🙂

    I found this in the web, but it doesen´t work in this state, its giving syntax error and I don´t have the skill yet to correct it.
    Could someone have mercy with me? I think it is a quite simple error..

    This is the link, it´s in french.
    http://sohocool.over-blog.com/article-29022036.html

    Here is the code: Syntax error line 28, 30

    /// Heiken ashi smoothed histogram
    
    // Average variable p = 1 period (default = 6) and t = mm Type (default smoothing wilder)
    
    // Average variable 2 p1 = period (default = 2) and t1 = mm type (weighted default)
    
    {// t and the deviation of the mean: 
    t = 0 = simple average 
    t = 1 = exponential average 
    t = 2 weighted average = 
    t = 3 = average wilder 
    t = 4 = average triangular 
    t = 5 = average end-point 
    t = 6 = average time series}
    
    // set histogrammme
    
    
    if BarIndex> p Then 
    mo = average [p, t] (open) 
    mc = average [p, t] (close) 
    ml = average [p, t] (low) 
    mh = average [p, t] (high) 
    endif
    
    
    haopen ounce = mo
    
    haclose = (mc mo + + + mh ml) / 4 
    if BarIndex> p + 1 then 
    haopen = (haopen [1] + haclose [1]) / 2 
    endif
    
    haopen1 average = [p1, t1] (haopen) 
    haclose1 average = [p1, t1] (haclose)
    
    if haclose1> haopen1 Then 
    a = 1 
    else 
    a = -1 
    endif
    
    
    return 1 colored by aa as "Smoothed Heiken Histo"
    
    ///////// end
    
    
    cloud code to open in the graph:
    
    
    /// Heiken ashi smoothed histogram
    
    // Average variable p = 1 period (default = 6) and t = mm Type (default smoothing wilder)
    
    // Average variable 2 p1 = period (default = 2) and t1 = mm type (weighted default)
    {t and the deviation of the mean: 
    t = 0 = simple average 
    t = 1 = exponential average 
    t = 2 = weighted average 
    t = 3 = average wilder 
    t = 4 = average triandulaire 
    t = 5 = average end-point 
    t = 6 = average time series}
    
    if BarIndex> p Then 
    mo = average [p, t] (open) 
    mc = average [p, t] (close) 
    ml = average [p, t] (low) 
    mh = average [p, t] (high) 
    endif
    
    
    haopen ounce = mo
    
    haclose = (mc mo + + + mh ml) / 4 
    if BarIndex> p + 1 then 
    haopen = (haopen [1] + haclose [1]) / 2 
    endif
    
    haopen1 average = [p1, t1] (haopen) 
    haclose1 average = [p1, t1] (haclose)
    
    
    haopen1 return as "Smoothed Heiken Nuageopen" haclose1 as "Smoothed Heiken nuageclose"
    
    
    ///////end
    
    
    
    
    HAsmoothed.png HAsmoothed.png
    #17563 quote
    NicolasNicolas
    Keymaster
    Legend

    You made wrong copy/paste of the 2 codes and into a single one too ..

    Please find attached the modified and fixed version to import directly into prorealtime.

    Iván González thanked this post
    heikin-ashi-smooth-indicators-prorealtime.png heikin-ashi-smooth-indicators-prorealtime.png Heiken-Ashi-Smoothed-Cloud.itf Heikin-Ashi-Smooth-Histogram.itf
    #17584 quote
    torkelabtorkelab
    Participant
    Senior

    Thanks a lot Nicholas, very kind of you!

    I also found this indicator on your eminent website, but it seemes only to work in 10.3 and I have 10.2..?

    Is it possible to have a beta PRT10.3 working in the IG-world or do we have to wait for the official one? Have you heard anything about when?
    I would love to get my hands on it and get rid of the inside-bar problem when backtesting.

    DRAWBARCHART

    //Smooth Heiken Ashi barchart
    
    period = 20
    
    if barindex>period then
    
      avgO = average[period](open)
      avgH = average[period](high)
      avgL = average[period](low)
      avgC = average[period](close)
    
      HAClose = (avgO+avgH+avgL+avgC) /4
      HAOpen = (HAOpen[1]+HAClose[1]) / 2
      HAHigh = MAX(avgH,MAX(HAOpen,HAClose))
      HALow = MIN(avgL,MIN(HAOpen,HAClose))
    
       IF avgO <= avgC THEN
         // Green candlestick
         DRAWBARCHART(HAOpen,HAHigh,HALow,HAClose) COLOURED(0,255,0)
       ELSE
         // Red candlestick
         DRAWBARCHART(HAOpen,HAHigh,HALow,HAClose) COLOURED(255,0,0)
       ENDIF
    endif
    
    RETURN
    HAprorealcode10.3.png HAprorealcode10.3.png
    #17588 quote
    NicolasNicolas
    Keymaster
    Legend

    You’ll have to wait until next year for 10.3 if you are an IG customer, you’ll get the ETA information directly @ IG

    #17603 quote
    torkelabtorkelab
    Participant
    Senior

    Aha, you mean draw barchart is not possible in prt 10.2?

    #17614 quote
    NicolasNicolas
    Keymaster
    Legend

    Exactly, this is a part of PRT 10.3 new graphical instructions. I should make the tag “prorealtime 10.3” more readable in the documentation’s pages I believe 🙂

    torkelab thanked this post
    drawbarchart-prorealtime-10.3.png drawbarchart-prorealtime-10.3.png
    #252731 quote
    ErreerraErreerra
    Participant
    New

    Hi Nicolás, do you have a screener that detects color changes on the Heiken Ashi Smooth indicator?
    Thanks for your work.

    #252734 quote
    jacquesgermainjacquesgermain
    Participant
    Veteran

    Hello voir screener ci-joint

    Erreerra thanked this post
    MonProScreener3.itf
    #252736 quote
    ErreerraErreerra
    Participant
    New

    Merci beaucoup, Jacques.
    Je constate dans les résultats que vous sélectionnez de nombreuses valeurs sans changement de couleur dans le HAS. Est-ce normal ? Quels paramètres sont sélectionnés ?
    Le Heiken Ashi Smooth que j’utilise est celui-ci :

    Heiken-Ashi-Smooth.itf
    #252777 quote
    jacquesgermainjacquesgermain
    Participant
    Veteran

    Hello voici ci-joint proscreener associé à votre indicateur pour détecter rouge vers bleu

    robertogozzi thanked this post
    MonProScreener8.itf
    #252786 quote
    ErreerraErreerra
    Participant
    New

    Merci beaucoup Jacques, je l’ai essayé et ça fonctionne parfaitement.

    Une dernière chose, si ce n’est pas trop demander, le screener pourrait-il être réglé pour sélectionner également les valeurs qui ont changé de couleur, mais sur la bougie précédente ?

    #252789 quote
    jacquesgermainjacquesgermain
    Participant
    Veteran

    Hello voici ci-joint proscreener associé à votre indicateur pour détecter rouge vers bleu today et yesterday

    Erreerra thanked this post
    MonProScreener9.itf
    #252959 quote
    ErreerraErreerra
    Participant
    New

    Merci Beaucoup, Jaques.

Viewing 13 posts - 1 through 13 (of 13 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

Heiken Ashi smoothed


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
torkelab @torkelab Participant
Summary

This topic contains 12 replies,
has 2 voices, and was last updated by ErreerraErreerra
11 months, 1 week ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 11/30/2016
Status: Active
Attachments: 10 files
ProRealCode ProRealCode
Loading...