Watch how to download trading robots for free

Interesting script?
So post a link to it -
let others appraise it

You liked the script? Try it in the MetaTrader 5 terminal

votes: 13
2011.12.14 12:25
2016.11.22 07:32
jfatl.mq5 (7.56 KB)view

The hybrid of digital and analog filters that displays larger timeframe values at a smaller one in a completely minimized way and is located in a separate chart window.

In this case, only direction of the current trend is used from the indicator. It should be noted that since the indicator calculates its values using larger timeframe, it rewrites its readings on the number of bars equivalent to the larger timeframe bar size.

The indicator is calculated the following way:

JFATL[bar] = JMA(FATL(PRICE[bar]))


  • FATL() - FATL digital filter value;
  • JMA() - JMA adaptive smoothing algorithm;
  • PRICE[] - price series value.
  • bar - current bar index.

Additional JMA smoothing is used to prevent the indicator actuating at each random market movement.

Place the JFatl indicator compiled file to the terminal_data_folder\MQL5\Indicators\.

JFatl uses CJJMA class of the SmoothAlgorithms.mqh library. Working with that class was described in details in the article "Averaging Price Series for Intermediate Calculations Without Using Additional Buffers".

JFatl HTF Baby

Translated from Russian by MetaQuotes Software Corp.
Original code:

VGridLine_Annual VGridLine_Annual

Vertical time grid with one year step.


The hybrid of digital and analog filters that displays its larger timeframe values at a smaller one.

VGridLine Monthly VGridLine Monthly

Vertical time grid with one month step.

IncMAOnArray IncMAOnArray

CMAOnArray class is used for Moving Average calculation on indicator buffer's data. The example of use of the class is provided.