Nice idea! But work is incomplete for Exponential and Smoothed, it return 0. See the code
double CalculateMovingAverage(int position, int period, const double &price[]) { switch(InpMaMethod) { case Simple: return SimpleMA(position, period, price); case Exponential: // Corrigindo a chamada da função iMA com os parâmetros corretos return iMA(NULL, 0, period, 0, MODE_EMA, PRICE_CLOSE); case Smoothed: // Implemente sua função SMMA aqui break; case LinearWeighted: return LinearWeightedMA(position, period, price); } return 0; // Retorno padrão em caso de método indefinido }
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Custom Bollinger Bands:
Standard Bollinger Bands indicator with averaging features added
Author: Lucas Moura Vidal Da Silva