- Multi Timeframe Indicators
- MT4 not having the same numbers in indicators
- I will write a free mql4 advisor
Help you with what? You haven't stated a problem, you stated a want. Show us your attempt (using the CODE button) and state the nature of your difficulty.
No free help (2017)
Or pay someone. Top of every page is the link Freelance.
Hiring to write script - General - MQL5 programming forum (2018)
We're not going to code it for you (although it could happen if you are lucky or the problem is interesting).
No free help (2017)
Help you with what? You haven't stated a problem, you stated a want. Show us your attempt (using the CODE button) and state the nature of your difficulty.
No free help (2017)
Or pay someone. Top of every page is the link Freelance.
Hiring to write script - General - MQL5 programming forum (2018)
We're not going to code it for you (although it could happen if you are lucky or the problem is interesting).
No free help (2017)
This is a MACD I've been tweaking to try and get the same output as my indicator on TradingView. I want to be able to see the most recent bar of the histogram for a lower timeframe MACD on a higher timeframe chart. E.g. most recent bar of 1 minute MACD histogram on 5 minute chart as shown in the screenshot. I've seen people do it to look at higher timeframes where they print the same bar 3x for a 15 minute histogram on a 5 minute chart, but not the other way around.
#include <MovingAverages.mqh> #property indicator_separate_window #property indicator_buffers 1 #property indicator_color1 Green #property indicator_width1 3 input int InpFastEMA=12; input int InpSlowEMA=26; input int InpSignalEMA=9; input int InpTimeframe=1; double ExtOsmaBuffer[]; double ExtMacdBuffer[]; double ExtSignalBuffer[]; bool ExtParameters=false; int OnInit(void) { IndicatorBuffers(3); SetIndexStyle(0,DRAW_HISTOGRAM); SetIndexDrawBegin(0,InpSignalEMA); IndicatorDigits(Digits+2); SetIndexBuffer(0,ExtOsmaBuffer); SetIndexBuffer(1,ExtMacdBuffer); SetIndexBuffer(2,ExtSignalBuffer); IndicatorShortName("MACD 1M("+IntegerToString(InpFastEMA)+","+IntegerToString(InpSlowEMA)+","+IntegerToString(InpSignalEMA)+")"); if(InpFastEMA<=1 || InpSlowEMA<=1 || InpSignalEMA<=1 || InpFastEMA>=InpSlowEMA) { Print("Wrong input parameters"); ExtParameters=false; return(INIT_FAILED); } else ExtParameters=true; return(INIT_SUCCEEDED); } int OnCalculate (const int rates_total, const int prev_calculated, const datetime& time[], const double& open[], const double& high[], const double& low[], const double& close[], const long& tick_volume[], const long& volume[], const int& spread[]) { int i,limit; if(rates_total<=InpSignalEMA || !ExtParameters) return(0); limit=rates_total-prev_calculated; if(prev_calculated>0) limit++; for(i=0; i<limit; i++) ExtMacdBuffer[i]=iMA(NULL,InpTimeframe,InpFastEMA,0,MODE_EMA,PRICE_CLOSE,i)- iMA(NULL,InpTimeframe,InpSlowEMA,0,MODE_EMA,PRICE_CLOSE,i); ExponentialMAOnBuffer(rates_total,prev_calculated,0,InpSignalEMA,ExtMacdBuffer,ExtSignalBuffer); for(i=0; i<limit; i++) ExtOsmaBuffer[i]=ExtMacdBuffer[i]-ExtSignalBuffer[i]; return(0); } //+------------------------------------------------------------------+

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use