Ek Trend Trading
- Experts
- Kaimin Wang
- Versione: 1.1
- Aggiornato: 20 novembre 2025
- Attivazioni: 5
Trend Trading - Gold is an automated trading program developed in MQL4 specifically for gold trading. It generates trading signals by analyzing the patterns of the most recent three candlesticks with custom volatility levels. Each signal allows individual lot size configuration and executes trades with a fixed lot size. The program employs a single-order mode, meaning only one order can be active at a time, thereby reducing trading risk.
EA can be loaded onto any timeframe. The trading signal candlestick uses the specified candlestick height and is unrelated to the candlesticks displayed on the chart.
Live Trading Signals:https://www.mql5.com/zh/signals/2344519?source=Site+Profile
Input Parameters Configuration
Order Identification Settings
MagicNumber: Magic number for identifying orders created by this EA, recommend using different magic numbers for each chart
Lot Settings
FixedLotSize: Fixed lot size used for all trades
K-line Settings
KLinePoints: Candle wave points, a candle completes when price movement reaches this point value
General Risk Parameters
TP: Take profit points, sets profit target in points
SL: Stop loss points, sets maximum loss in points
TrailTrigger: Trailing stop trigger points, activates trailing stop when profit reaches this level
TrailStop: Trailing stop points, stop loss distance after trailing stop activation
Trading Time Settings
StartHour: Trading start hour (0-23)
StartMinute: Trading start minute (0-59)
EndHour: Trading end hour (0-23)
EndMinute: Trading end minute (0-59)
SkipWeekend: Whether to skip weekend trading, true to skip, false to trade weekends
Signal Lot Settings
Lot000: Trading lot for 000 signal, set to 0 to ignore this signal
Lot001: Trading lot for 001 signal, set to 0 to ignore this signal
Lot010: Trading lot for 010 signal, set to 0 to ignore this signal
Lot011: Trading lot for 011 signal, set to 0 to ignore this signal
Lot100: Trading lot for 100 signal, set to 0 to ignore this signal
Lot101: Trading lot for 101 signal, set to 0 to ignore this signal
Lot110: Trading lot for 110 signal, set to 0 to ignore this signal
Lot111: Trading lot for 111 signal, set to 0 to ignore this signal
Interface Settings
ShowVirtualKLines: Whether to show virtual candles, true to show, false to hide
BullColor: Bullish candle display color
BearColor: Bearish candle display color
KLineWidth: Candle display width (pixels)
KLineHeight: Candle display height (pixels)
PanelBgColor: Information panel background color
PanelTextColor: Information panel text color
FontSize: Font size
UpdateInterval: Panel update interval (milliseconds)
Installation and Usage Steps
Installation Steps
-
Copy Trend Trading - Gold.mq4 file to MT4 platform's Experts folder
-
Restart MT4 platform or refresh Navigator
-
Drag EA onto Gold (XAUUSD) chart
-
Enable automated trading and set parameters
Parameter Setting Recommendations
-
Timeframe: Recommended M1 or M5 charts
-
KLinePoints: Set according to market volatility, typically 20-50 points
-
FixedLotSize: Set appropriate lot size based on account balance
-
Trading Hours: Recommend setting during high volatility periods in Beijing time
Signal Explanation
The program recognizes 8 types of 3-candle combination signals:
-
000: Three consecutive bearish candles, sell signal
-
001: Bearish-bearish-bullish, buy signal
-
010: Bearish-bullish-bearish, sell signal
-
011: Bearish-bullish-bullish, buy signal
-
100: Bullish-bearish-bearish, sell signal
-
101: Bullish-bearish-bullish, buy signal
-
110: Bullish-bullish-bearish, sell signal
-
111: Three consecutive bullish candles, buy signal
Important Notes
-
Test thoroughly on demo account before using on live account
-
Recommend using VPS to ensure continuous program operation
-
Regularly check program status and order conditions
-
Adjust parameters according to market conditions
-
Ensure sufficient account margin to avoid margin calls
Troubleshooting
-
If EA not trading: Check if automated trading is enabled, parameters set correctly
-
If panel not displaying: Check if chart objects are hidden
-
If orders cannot be placed: Check if spread is too wide, account has sufficient funds
