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 | Avg_MA

Average from MA indicator calculates the average value from the specified number of moving averages, whose periods are calculated as an increment to the base МА period

It has six input parameters:

  • First MA period - МА calculation base period
  • Method - МА calculation method
  • Applied price - МА calculation price
  • Count - number of calculated МАs
  • Coefficient of increment - increment ratio of calculated MA periods
  • Incremental method - increment method
    • Addition
    • Multiplication

Example of calculation with values:

First MA period = 5
Coefficient of increment = 2
Count = 5

  • If Incremental method = Addition:
    AvgMA=(MA(5)+MA(7)+MA(9)+MA(11)+MA(13))/5
  • If Incremental method=Multiplication:
    AvgMA=(MA(5)+MA(10)+MA(20)+MA(40)+MA(80))/5

where:

MA - MovingAverage(Applied price,Method) with calculated period

MetaTrader Experts, Indicators, Scripts and Libraries

22420