The CFramaOnArray class is intended for calulcation of Fractal Adaptive Moving Average (FRAMA) on indicator buffers.
The Init() method with the following parameters is called in the OnInit() function of the indicator:
The Solve() method with the following parameters is called in the OnCalculate() function:
The Test_FramaOnArray.mq5 is an indicator demonstrating how to use the CFramaOnArray class. The IncFramaOnArray file must be located in the MQL5\Include\IncOnArray directory of the terminal data folder (the IncOnArray folder must be created).
Fractal Adaptive Moving Average Technical Indicator (FRAMA) was developed by John Ehlers. This indicator is constructed based on the algorithm of the Exponential Moving Average, in which the smoothing factor is calculated based on the current fractal dimension of the price series. The advantage of FRAMA is the possibility to follow strong trend movements and to sufficiently slow down at the moments of price consolidation.

Translated from Russian by MetaQuotes Software Corp.
Original code: http://www.mql5.com/ru/code/660