Expert Advisors • Indicators • Scripts • Libraries

MQL.RobotFX.org is the biggest collection of MetaTrader expert advisors (MT5 & MT4), indicators, scripts and libraries that can be used to improve trading results, minimize risks or simply automate trading tasks

MetaTrader 5 Indicator | RegressionPolynomial

Real author:

Ivan Kornilov

RegressionPolynomial is a trend indicator calculating values of polynomial regression on each bar.

Optimized methods of calculation are used for the first and the second degrees, QRMA, described here, is of special interest. Well known formula 3 * LWMA - 2 * SMA is used for the first degree. The code also has a function calculating QWMA of more sensitive moving than LWMA.

The indicator uses SmoothAlgorithms.mqh library classes (must be copied to the terminal_data_folder\MQL5\Include). The use of the classes was thoroughly described in the article "Averaging Price Series for Intermediate Calculations Without Using Additional Buffers".

This indicator was first implemented in MQL4 and published in CodeBase on April 27, 2012.

MetaTrader Experts, Indicators, Scripts and Libraries

Fig.1. RegressionPolynomial Indicator

11388

Best MetaTrader Indicators + Profitable Expert Advisors