Menu
Brokers
MT4 Forex Brokers
MT5 Forex brokers
PayPal Brokers
Skrill Brokers
Oil Trading Brokers
Gold Trading Brokers
Web Browser Platform
Brokers with CFD Trading
ECN Brokers
Bitcoin FX Brokers
PAMM Forex Brokers
With Cent Accounts
With High Leverage
Cryptocurrency Brokers
Forums
All threads
New threads
New posts
Trending
Search forums
What's new
New threads
New posts
Latest activity
Log in
Register
Search
Search titles only
By:
Search titles only
By:
Menu
Install the app
Install
Reply to thread
Forums
Trading Platforms
MetaTrader 4
Inside bar
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
[QUOTE="abiroid, post: 210261, member: 86758"] If you are only interested in candle body, use Open and Close. This is just a sample of what you could do. [CODE=mql4] // Candle1 is on right side and candle2 is on left double open1 = iOpen(Symbol(), PERIOD_CURRENT, shift); double open2 = iOpen(Symbol(), PERIOD_CURRENT, shift+1); double close1 = iClose(Symbol(), PERIOD_CURRENT, shift); double close2 = iClose(Symbol(), PERIOD_CURRENT, shift+1); // Candle2 is Bearish and Candle1 is bullish if(type == OP_BUY && close1 > open1 && open2 > close2 && close1 > open2) { return true; } // Candle2 is Bullish and Candle1 is bearish else if(type == OP_SELL && close1 < open1 && open2 < close2 && close1 < open2) { return true; }[/CODE] int type could be whatever direction you are checking for. You could look through mql5.com codebase for engulfing EA code. There are a few. Or maybe look for a simple EA and build from there. [/QUOTE]
Insert quotes…
Verification
Post reply
Top
Bottom
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.
Accept
Learn more…