Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Hi
I'd like to know how to build my own moving average with the average of 4 indicators
double ma = iMA(NULL, 0, 14, 0, MODE_EMA, PRICE_CLOSE,Current + 0);
double ma_m15 = iMA(NULL, PERIOD_M15, 14, 0, MODE_EMA,PRICE_CLOSE, Current + 0);
double ma_m30 = iMA(NULL, PERIOD_M30, 14, 0, MODE_EMA,PRICE_CLOSE, Current + 0);
double ma_m60 = iMA(NULL, PERIOD_H1, 14, 0, MODE_EMA,PRICE_CLOSE, Current + 0);
double var1 = ma, var2 = ma_m15, var3 = ma_m30, var4=ma_m60 ;
double var_myMA = (var1 + var2 + var3 + var4)/4;
How can I draw var_myMA in the main window? I don't know how to use ObjectCreate().
Best regards