Var Mov Avg
Var Mov Avg MetaTrader indicator — although it is based on a moving average, it doesn't use any standard MT4/MT5 moving average indicators. It uses its own formula to calculate the moving average with a complex noise filter to produce more accurate signals. The indicator displays dotted line in the main chart window exactly over the price curve. The changing colors of the dots signal trend changes. The indicator supports all types of alerts on trend changes. Var Mov Avg is capable of displaying higher timeframe calculation results on a lower timeframes (multi-timeframe indicator). It is available for MT4, MT5, and cTrader.
- periodAMA (default = 50) — the period of the main custom moving average. Unlike with other MAs, the higher this number is the less smooth is the line.
- nfast (default = 15) — the first noise filter parameter. Higher values make indicator less sensitive to spikes.
- nslow (default = 10) — the second noise filter parameter. Higher values make indicator less sensitive to spikes.
- G (default = 1.0) — the power of filtered part in the moving average. Another way to make the moving average line smoother.
- dK (default = 0.1) — configures signal sensitivity — higher values mean fewer signals.
- EnableNativeAlerts (default = false) — if true, a native MetaTrader popup alert will be used when a buy signal appears. Not present in cTrader.
- EnableEmailAlerts (default = false) — if true, an email message will be sent when a buy signal appears. Email should be properly configured in MetaTrader via Tools->Options->Email.
- EnablePushAlerts (default = false) — if true, an email message will be sent when a buy signal appears. Notifications should be properly configured in MetaTrader via Tools->Options->Notifications. Not present in cTrader.
- TriggerCandle (default = Previous) — the candle to issue alerts on: Previous — the most recently closed candle or Current — the yet unfinished candle.
- UpperTimeframe (default = PERIOD_CURRENT) — if set to a timeframe above the current one, it will make the indicator calculate on that timeframe's data.
Example and strategy
When the dots are red, the price is in the downtrend. When the dots are green, the price is in the uptrend. Buy when red changes to green and sell when green changes to red. Use moderate stop-loss to protect yourself from false signals.
Downloads (ver. 1.02, 2022-10-07)Var Mov Avg for MetaTrader 4 in .zip Var Mov Avg for MetaTrader 4 in .mq4 Var Mov Avg for MetaTrader 5 in .zip Var Mov Avg for MetaTrader 5 in .mq5 Var Mov Avg for cTrader in .zip Var Mov Avg for cTrader in .cs
Do you have any suggestions or questions regarding this indicator? You can always discuss Var Mov Avg with the other traders and MQL programmers on the indicators forums.
1.02 - 2022-10-07
- Added MTF capability with the UpperTimeframe input parameter.
- Added a version of Var Mov Avg for cTrader.
- Fixed some issues with alerts.
1.01 - 2022-04-07
- Added all types of alerts — native (popup), email, and mobile notifications.
- Changed the indicator to calculate at each tick (was on each new bar previously).
- Optimized it to not recalculate old bars.
- Removed unnecessary pieces of code.