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
I just took a look at the WPR by MQ and I noticed a strange thing.
There are no such Highest() and Lowest() functions defined but yet it compiles and it works. Somehow the compiler must identify them as iHighest() and iLowest() but it probably shouldn't be doing that. I wonder what would happen if there were user functions called Highest() and Lowest().
Edit: I tried it, the compiler threw up a bunch of errors when I made a function called Highest().
I just took a look at the WPR by MQ and I noticed a strange thing.
There are no such Highest() and Lowest() functions defined but yet it compiles and it works. Somehow the compiler must identify them as iHighest() and iLowest() but it probably shouldn't be doing that. I wonder what would happen if there were user functions called Highest() and Lowest().
Edit: I tried it, the compiler threw up a bunch of errors when I made a function called Highest().
Highest and Lowest are still supported but obsolete: https://docs.mql4.com/obsolete
OK, sorry to trouble you.
RaptorUK:
I took other's idea to take a break, and think I own you an apologize. So...Sorry for my words to you!
It just because I eager to get the problem resolved so much.
Anyway, the person who offer other people helps should not be treated like this, Sorry again!
By the way, by the time i take a rest, I solved the problem by myself and think maybe there's other people may need this.
So below is my resluts.
The first way is to use ArrayMaximum/Minimum() function to compute the local high/low.
the code:
just part of the most important code....
the reslut pics:
the first signal is the MT4 iWPR, the second signal is the reslut export by my code.
you can see the dynamics is the same, but the exact value is different, it's because I use the "close" as the import data. and the iWPR use the "High/Low" as the import data.
the second way is to use the "for" loop to compute the local high/low.
the code:
the reslut pic is exactly the same as the last pics.