|
|||||||
| Register in Forex TSD! | |
|
Trading Systems Leaders in this forum (automated trading systems) are winning more than 3000 pips in a month (30000$ investing one lot every time). Click here to register and get more information |
|
![]() |
|
|
LinkBack (2) | Thread Tools | Display Modes |
|
|||
|
Hi
I am so sorry if my question is very basic. I am learing mql4. Please help me how to express this math conditions in mql4: IF( (A>B) AND (|X| <1) AND (Y<Z) ) then.. ... ... ... |X| is absoulute; it means (X < -1) OR (X> 1) I got messege from MetaEditor " IF EXPRESSION IS TOO COMPLEX" After many times trying,... I have no more Idea..So please tell me how to.. Thanks |
|
|||
|
Quote:
I studied Codersguru lessons together with everybody: it was one time when Codersguru was posting his lessons live (in real time) on this forum and many people (together with me) studied this lessons. I remember that && is and. || is or. And be cafully with ;, { and } and ( and ). Also be cafuly with the point and number (just a number - 70,or 100, 0r -100, or 30, or whatever) because it should be coded in different way (don't remember now sorry). |
|
||||
|
Quote:
if((a>b && MathAbs(x)<1) && y<z) { //write here what should happen }
__________________
You need proffesional mql coder? Contact me! I will help you! ........................................ http://www.fxservice.eu/ ........................................ |
|
|||
|
advice please
Is it possible to create bar indicators in separate windows like the indicator in the pic i have posted [dont know what they are officially called] for say a red bar if the MACD crosses negative and stays red if in negative zones and green if crosses positive etc etc. Also is it possible to create the same bar indicator windows for say if the price goes below a moving average.
if this seems a daft question please bear with me. When i look at indicators on a chart i tend to try and anticipate what the price will do so im looking to try and have separate window indicators which when all show the same colour i will trade. [Psychology reasons]. Is the creation of these separate bar type indicators something i could learn to create , im far from a programmer in any language. any advice would be greatly appreciated. dh |
|
|||
|
Quote:
;your code } or maybe x == 0 instead of (x < -1 || x > 1) because only way MathAbs(x) < 1 is true when x=0 http://docs.mql4.com/basis/operations/bool on the other thought maybe you simply need this: if(a>b && x<1 && y<z) or this if(a>b && x<-1 && y<z) since x is never 0 or -1 according to your definition I am confused by your definition of absolute value Last edited by asmdev : 02-23-2007 at 10:51 PM. |
|
||||
|
Quote:
Just put the indicators on top of each other on the chart , I mean add it more than once and change the setting and you will have what you want I hope Last edited by MiniMe : 02-24-2007 at 12:18 AM. |
|
||||
|
Quote:
__________________
You need proffesional mql coder? Contact me! I will help you! ........................................ http://www.fxservice.eu/ ........................................ |
|
||||
|
Quote:
Here you are exactly what you want, load all 4 of the same indicator on one chart all with different settings as shown below, when all red sell, when all blue buy. settings set first for 15 minutes second 30 mins third 60 mins forth 140 mins |
![]() |
| Thread Tools | |
| Display Modes | |
|
|
LinkBacks (?)
LinkBack to this Thread: http://www.forex-tsd.com/questions/270-ask.html
|
|||
| Posted By | For | Type | Date |
| OzFx System:) - Page 639 | This thread | Refback | 06-21-2008 09:53 PM |
| Forex SRDC Sidus Sibkis EA MT4 Forum OTCSmart | This thread | Refback | 12-08-2007 11:46 AM |