Timeframe has become period and i guess they dropped the base price enumeration because when trend moves up the average direction of all these price bases will also move up and when there is a down trend, all prices will also have a decreasing direction.
So the question will be why do you need them ?
I just re-coded a mql5 indicator for mql4 and I realized the difference of the parameters. Yes, I have overseen the existence of timeframe, but the applied_price - I don't need it in my case, but generally speaking?
Ok, PRICE_HIGH and PRICE_LOW or PRICE_OPEN are probably very seldom used, but what about Median, Weighted, ...?
Well it's a directional indicator so if one moves up they all move up.
One can not simply stay behind.
Median for example is Ask+Bid / 2 so if the trend direction is up those two will also move up and there will be no difference in the directional output of said indicator.
Well it's a directional indicator so if one moves up they all move up.
One can not simply stay behind.
Median for example is Ask+Bid / 2 so if the trend direction is up those two will also move up and there will be no difference in the directional output of said indicator.
hmm?
prcTypical[i] = (High[i]+Low[i]+Close[i])/3.0,
...
;
Well that depends on which median you are looking for of course you can also use High and Low or Open and Close and etc.
ENUM_APPLIED_PRICE
ID |
Value |
Description |
PRICE_CLOSE |
0 |
Close price |
PRICE_OPEN |
1 |
Open price |
PRICE_HIGH |
2 |
The maximum price for the period |
PRICE_LOW |
3 |
The minimum price for the period |
PRICE_MEDIAN |
4 |
Median price, (high + low)/2 |
PRICE_TYPICAL |
5 |
Typical price, (high + low + close)/3 |
PRICE_WEIGHTED |
6 |
Weighted close price, (high + low + close + close)/4 |
Well that depends on which median you are looking for of course you can also use High and Low or Open and Close and etc.
ENUM_APPLIED_PRICE
ID |
Value |
Description |
PRICE_CLOSE |
0 |
Close price |
PRICE_OPEN |
1 |
Open price |
PRICE_HIGH |
2 |
The maximum price for the period |
PRICE_LOW |
3 |
The minimum price for the period |
PRICE_MEDIAN |
4 |
Median price, (high + low)/2 |
PRICE_TYPICAL |
5 |
Typical price, (high + low + close)/3 |
PRICE_WEIGHTED |
6 |
Weighted close price, (high + low + close + close)/4 |
Reduced to one if you ask me.
This is related to the actual indicator.
If you look at for example iMacd it's still there.
iMACD
The function returns the handle of the Moving Averages Convergence/Divergence indicator. In systems where OsMA is called MACD Histogram, this indicator is shown as two lines. In the client terminal the Moving Averages Convergence/Divergence looks like a histogram.
string symbol, // symbol name
ENUM_TIMEFRAMES period, // period
int fast_ema_period, // period for Fast average calculation
int slow_ema_period, // period for Slow average calculation
int signal_period, // period for their difference averaging
ENUM_APPLIED_PRICE applied_price // type of price or handle
);

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi, I just realized in MQL4 iADX is defined as:
string symbol, // symbol
int timeframe, // timeframe
int period, // averaging period
int applied_price, // applied price
int mode, // line index
int shift // shift
);
in MQL5 some options are missing - or am I wrong:
string symbol, // symbol name
ENUM_TIMEFRAMES period, // period
int adx_period // averaging period
);
the "timeframe" and "applied_price" - have they been lost or is there another way of getting that?