Ehler’s Fractal Adaptive Moving Average (FRAMA)

Ehler’s Fractal Adaptive Moving Average (FRAMA)

The Fractal Adaptive Moving Average FRAMA was developed by John Ehlers.

The indicator is constructed on the EMA exponential moving average algorithm, with a smoothing factor calculated on the basis of the current fractal dimension of the price.

The advantage of the indicator is the ability to track strong trend movements and market consolidation moments.

Interpretation Trading Signals And Rules:
The interpretation of the indicator is identical to the interpretation of moving averages
_ The FRAMA line is relatively “flat” in periods of horizontal range trading. It could therefore be used to avoid many false signals when it is desired to use a technique of the crossing of moving averages.
_ The FRAMA line has a greater reactivity to changes in trends than moving averages, making it possible to take a much earlier position on a breakout of the horizontal channel.

 

 

original code from gigi @ http://www.aktienboard.com/forum/f29/prorealtime-cmc-script-programmierung-t94783/215#post2035965

Share this

Risk disclosure:

No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.

ProRealTime ITF files and other attachments : How to import ITF files into ProRealTime platform?

PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials

  1. century • 11/24/2016 #

    hi
    i will use it to see … and get back to tell ya

  2. luigi • 11/24/2016 #

    Ciao Nicolas. Approfitto di questo spazio per chiederti se puoi aiutarmi. Avrei bisogno di un codice che sommi in tempo reale sul grafico tick by tick tutti i volumi in intraday che vengono scambiati su ogni livello di prezzo e che venga plottato sul grafico il livello dove in quel momento si stanno scambiando più contratti. Allego un esempio dove ho messo le frecce azzurre per indicare i volumi in real time plottati sul grafic.
    Grazie.
    Luigi

    • Nicolas • 11/24/2016 #

      Si prega di utilizzare i forum per chiedere richieste di codice per favore.

  3. Wilko • 11/24/2016 #

    Hi Nicolas!,
    Thanks for providing code for the FRAMA! If I have understood correctly, one should enter both minimum MAperiod and maximum MAperiod for the adaptive process. I am uncertain if your code provides for this. If so could you tell which variables hold these values, please?
    Kind regards,
    Wilko

    • dakaodo • 11/24/2016 #

      Hi, Wilko. Acc to the original FRAMA paper by Ehlers, Ehler’s own code only takes inputs for price and N (respectively, pri and len in Nicholas’ code above). If I follow the code, then I think it adaptively generates its own min and max periods, and the N value is only intended for your desired level of smoothing, not a fixed period for calculating the MA.

  4. dakaodo • 11/24/2016 #

    For reference, here is Ehlers’ original paper:

    http://www.mesasoftware.com/papers/FRAMA.pdf

    And for anyone interested in tweaking this, ETFHQ wrote an article on adjusting the constant w, which in the code above is hardcoded as a value of -4.6. By allowing two new variables FC and SC, you can set the fast and slow averages used to calculate the FRAMA.

    http://etfhq.com/blog/2010/09/30/fractal-adaptive-moving-average-frama/#Mod

    I am only smart enough to edit in the ability to set your own slow average (variable sc), so the fc is still set to the original default of 1.

  5. dakaodo • 11/24/2016 #

    Here is the code with only SC included, per ETFHQ.

    pri=customclose
    //len>=4, even
    once len=p
    once w=2.303*log(2/(sc+1))
    //once w=-4.61015 equivalent to sc=200

    N3=(Highest[len](High)-Lowest[len](Low))/len

    mH=High
    L=Low

    For count=0 To len/2-1
    If High[count] > mH Then
    mH=High[count]
    Endif

    If Low[count] HH Then
    HH=High[count]
    Endif

    If Low[count] 0 And N2 > 0 And N3 > 0 Then
    Dimen=(Log(N1+N2)-Log(N3))/Log(2)
    Endif

    alpha=Exp(w*(Dimen-1))

    If alpha 1 Then
    alpha=1
    Endif

    Filt=alpha*pri+(1-alpha)*Filt[1]

    If Barindex < len+1 Then
    Filt=pri
    Endif

    Return Filt as "FRAMA"

avatar
Register or

Likes

avatar avatar avatar
Related users ' posts
rejo007 hello david, i'll try it could you tell me wich strategy do you use in real? thanks
David Somogyi Hello, I have a couple of DAX strategies of breakout and mean reversion. I'll try to post...
Roberto Blázquez Hi David, I just saw your strategy and it's good!!! I'm going to try it from today in real a...
Thomas007 Is there any way to build something similar for FX? I wonder what would be the replacement f...
Kris75 Hi Bolsatrilera, I love this indicator! Thanks; => did you develop a strategy around...
Nicolas No sorry, please use this file instead into a prorealtime trading platform.
rdabbs I just installed this indicator. It opens in its own pane rather than overlaid on the chart ...
Nicolas Just apply it on your price chart instead and you're ok.
KarlBenjamin This "indicator" alone has completely changed my algorithms for the better! Id even go as fa...
ashee CAN YOU SHARE MT4 FILE
coyP Big thanks ! Can you explain me how can I put this ON my graph and not under the graph please ?
Wing There's a few threads on the forum about backtest and live trades being different at times. ...
ET I agree with verdi55. As it is now, the code will only test for a breakout on the upside (li...
Philipjonasson are u still active Wing?
Nicolas We do not offer free assistance for TOS. However, you can send demand for private paid codin...
phanz Hi community. May I know how you use this indicator please? Is it on the zero cross over? ...
sydney43025 Hello, I'm digging up this topic because I uploaded the code on a PRT v11.1 but the indicato...
David Balance thanks for sharing this excellent indicator.  Here are some thoughts.  please ad...
supertiti Il manque 2 slash devant len dans le code dur car la variable ne marche pas bonne journée
bearbull As per PhilipSchultz question above, has anybody managed to add code for when it turns blue,...
Ybr35 Bonjour Nicolas, lorsque je lance l'indicateur, il m'est indiqué que je dois définir les var...
Nicolas L'idéal est de télécharger le fichier itf joint sur cette page et de l'importer dans la plat...
Samitha Prasanna Hi ALE, would you be able to provide the values for the below part of the code (time >=1...
Player Bonjour, J'ai testé cette stratégie sur EurUSD en 1 heures sur 10000 unités et le résultat ...
Player Vue du rapport du Backtest https://ibb.co/8BMrBz6
Nicolas Merci dans ce cas d'ouvrir un sujet dans le forum ProScreener svp.
Andrea Hi Nicolas, thx for your code. Please i need your help to understand this part of your code:...
Nicolas the MA200 is ascending since 20 periods.
Leo Hi Gabri, have you ever try this in a trading system?
gabri Leo, I used to crosscheck this indicator a long time ago. For the trading I was doing at tha...
Nolubok Bonjour Gabri, merci pour l'ensemble de vos publications, serait il possible d'avoir le scr...
owes29 Hi is there anyway to develop this for the pro scanner on daily or hourly scans. so it woul...
Nicolas Of course, please add a query in the proscreener forum.
Bruno Carnazzi C'est dommage, cette histoire d'énergie fractale bousille complètement la précision de l'ind...
David Somogyi Hello, This is merely a filter indicator for measuring high fractality, which helps to av...
bertrandpinoy bonjour ce code fonctionne toujours?
Nicolas Faites un backtest, vous aurez des réponses.
Krallenmann Hallo Nicolas, kannst du mir die Regeln für den Halftrend Indikator sagen? Aus dem Code kann...
davefransman Dear Nicolas, i want set a alert on the "HalfTrend "custom moving average" met Heikin Ashi w...
Nicolas Please post the question in a new forum topic, that would need custom coding I believe.
Sofitech Ce code n'est valable que sur la V10.3 ? sur le 10.2 il y a une erreur de syntaxe dans le fi...
Nicolas Oui en effet, c'est un indicateur "10.3" à cause uniquement de la mise en forme des courbes ...
Nicolas En effet, c'est le cas si on copie/colle le code. Ces 2 variables sont inscrites en externes...
Salocin Hello Nicolas, my french is not that well. It occurs an error which can not be solved by cop...
Nicolas Just download the ITF file and import it into your platform, follow these easy steps: https:...
Nicolas
7 years ago
Holt EMA
Holt EMA
1
Indicators
robertanthonyuk Hi,What do the each colour represent? Rob

Top