Hi dev,
I want to code a MQL5 EA as described below.
I can provide my custom tradingview pinescript v5 code as a reference.
*** Strategy description ***
The strategy looks for a specific 4 candle pattern to open long or short.
Current candle is candle 0, previous candle is 1 and so on.
For longs: Current candle closes above previous candle’s high (candle 1) and also closes above candle 3 high.
For shorts: Current candle closes below previous candle’s low (candle 1) and also closes below candle 3 low.
The candle pattern is only valid on bar close.
*** Entry conditions ***
Once a pattern is detected we will stop looking for new patterns until the trade is closed or cancelled. If the limit order is not triggered in X number of candles we cancel the limit order and restart looking for candle patterns. If before the trade is triggered we get a contrarian signal we also cancel the trade and open the last one to appear.
Here is the candle detection code in pinescript V5:
bool greenTriangle = close > high[1] and close > high[3] and not prevGreenTriangle
bool redTriangle = close < low[1] and close < low[3] and not prevRedTriangle
When the pattern is detected a limit order is set to X pips above the last candle for longs or under for shorts. This makes sure that the trade will only open if the price actually moves in the direction of the signal. If the price moves in the opposite direction we will end up canceling the order after X candles or a contrarian signal.
That’s all for the trigger conditions.
*** Exit conditions***
For exit we use a fixed stop loss value equal to X pips and a dynamic take profit that is a multiplier of the ATR value (period 7 candles and multiplier 0.7 for instance).
An open position should also be closed if we get an opposing candle pattern.
*** Position size ***
In terms of position size we risk losing 1% of the account per trade. If this results in a value bigger than the whole account we use 90% of the account as position size.
The strategy only keeps one long or one short open per time so there is no pyramiding.
It should be possible to define two time periods for opening trades per day. For instance from 08h00 UTC to 12h30 UTC and again from 14h30 UTC until 21h00 UTC.
Closing trades can be anytime since we defined the stop loss and take profit already.
We should have an icon indicating a long and one for short. Position entry price, stop loss and take profit should also be displayed.
Please see attached image for an idea of what it should do.
Thanks
Benzer siparişler
I trade manually on M1 chart (XAUUSD) with fractals and alligator. When there is a price break on fractal (or some fractals that form a price level) or a price level created by multiple candles spikes, I enter 2 trades (0.02 lots), and 2 trades (0.04 lots). If I go in profit (5/10€), I close in profit. But if I go in loss with DD, at this point starts the management: every price level (important level) created by
99.99% signal accuracy 10-15 trades distribution all currency trade and meta AI assistance on loss[advice] stop and start robot cyber security firewall protection activation code: 20060605TLP20 Please create a trading bot with any logo with the name elevation
Refine signal trigger execution . Optimize live chart performance . Ensure stable and clean code structure : Stable and clean code is important . Otherwise its a mess . Apply with as much accurate structure you foresee
50 EMA > 200 EMA → Uptrend confirmed Price pulls back to touch or cross below 50 EMA RSI > 50 ATR(14) > 20-period ATR average (volatility expanding) Current candle closes bullish ➡ Enter BUY at candle close50 EMA < 200 EMA → Downtrend Price pulls back to touch or cross above 50 EMA RSI < 50 ATR filter confirms volatility Current candle closes bearish ➡ Enter SELL at candle closeATR(14) Take Profit: 2.5 × ATR(14) This
This post is subject to developers response . Edit the post as you like . May be with me you can make a come back . So , , , Shift calculations . More to the calculation then you can comprehend is known . What else comes to your mind
Here is an example of Requirements Specification for the development of the MACD Sample Expert Advisor, which is available in the MetaTrader 5 standard package. 1. The idea of the trading system is as follows: market entries are performed when MACD's main and signal lines intersect in the current trend direction. 2. Trend is determined based on the Exponential Moving Average with the specified period
I’m looking for a trading bot where I can use a balance of £1000 to make regular entries making £20-£40 per entry. obviously, I want to have minimum loss with a lot more profit being made
I’m hiring an experienced MQL5 developer to finish and fix an existing project (NOT building from scratch). I have: An existing MT5 EA (.mq5 + .ex5) that is based on my TradingView logic A TradingView indicator version used for signals/alerts The EA works but has logic/consistency issues and needs improvements + cleanup Goal Make the EA reliable and consistent: Ensure entries/exits match the intended logic Fix
I have a High-Frequency Trading EA and I need a full conversion and optimization for MT5. The goal is to ensure stable execution and reliable performance on real accounts (IC Markets Raw and similar ECN brokers). I need an experienced and reputable MQL5 developer to: Convert the existing strategy to MT5 with full fidelity to the original trading logic (entries, SL, breakeven, trailing, pending orders). Optimize the
Hello friends, We need Robot, EA , or Trading software with proven( 6 to 12 months) and it should be given consistent profit upto 3 % per month with no risk ( low Drawdown ), we will pay what you ask, and also We are regulated forex broker and we have all access like FIX API etc, and we dealing with Top tier 1 LPs . Thanks