TREND FOLLOWING EA Note to developers: PLEASE READ THIS DOCUMENT FULLY TO ENSURE THAT YOU UNDERSTAND THE WHOLE BRIEF. PLEASE RESPOND ONLY IF YOU ARE CERTAIN THAT YOU CAN COMPLETE THE BRIEF. PLEASE ALSO LOOK AT THE ACCOMPANYING SCRENN SHOTS WHICH ILLUSTRATE THE CONCEPT. This is a very simple concept. Based on just two indicators: Supertrend and EMA. The aim is to trade short term (M15 or M30) in the direction of the trend established by a slow EMA (maybe 50 period, maybe 100, maybe 200). The shorter the time frame traded (say 15m), the more trades there are. So many, in fact, that we can be quite selective in the filters we use. Values expressed here as [xxx] are variable settings to be included in the EA. How it works: Enter a buy trade when: Supertrend [1.7, 10] crosses up, while Long term [200] [ema] is rising (the absolute value of the EMA at the close of the current candle is higher than the value of the EMA at the close of the previous candle). Enter a sell trade when: Supertrend [1.7, 10] crosses down, while Long term [200] [ema] is falling (the absolute value of the EMA at the close of the current candle is lower than the value of the EMA at the close of the previous candle). Once trade is open, the value and direction of the EMA are ignored - the trade is managed by the Supertrend alone and the other trade management settings in the EA. Trade Management: Number of Trades per signal When a signal to trade is given, open up to 2 trades if lot size (below) or equity are both not zero. If the lot size and the equity factor are both zero, do not open that trade. Trade limits Limit the total number of open trades to [6] open trades at any one time. (Once this number of trades is open, do not open any more new trades, irrespective of trade signals) The Two trades: Trade 1: SWING TRADE Lot sizing: [0.01] fixed manually by user OR (if manual lot size = 0), Auto lot size calculation: Auto lot account equity per 0.01 lots: [500] Take Profit: Take Profit and close trade at [0.50%] of equity. If the equity % figure is set at 0, there is no Take Profit set. So, as an example, if the account equity is 1000 euros and the Take Profit setting is 0.5%, then the trade would hit its Take Profit and close at 5 euros. If the account equity was 1000 euros and Take Profit setting was 3.0%, then the trade would close at 30 euros. Stop Loss: * The value of the Supertrend [+/- 3 pips] is used as the stop loss. * No separate stop loss is set when trade is opened except the value of the Supertrend line plus [3] pips in a sell trade (Supertrend -[3] pips in a buy trade). * When trade is [15] pips in profit, set stop loss to break even plus [1 pip]. Exit of a BUY trade. One of these: * Manually * Hitting the stop loss described above * Hitting a predefined Take Profit level Trade re-entry in the same direction: Whilst the long term EMA remains rising, new trades can be entered, according to the Supertrend signal. Trade 2: SCALP TRADE Lot sizing: [0.01] fixed manually by user OR (if manual lot size = 0), Auto lot size calculation: Auto lot account equity per 0.01 lots: [500] Take Profit: Take Profit and close trade at [0.25%] of equity. If the equity % figure is set at 0, there is no Take Profit set. Stop Loss: * The value of the Supertrend [+/- 3 pips] is used as the stop loss. * No stop loss is set when trade is opened except the value of the Supertrend line plus [3] pips in a sell trade (Supertrend -[3] pips in a buy trade). * When trade is [15] pips in profit, set stop loss to break even plus [10 pips]. Exit of a BUY trade. One of these: * Manually * Hitting the stop loss described above * Hitting a Take Profit level Trade Re-entry in the same direction: Whilst the long term EMA remains rising, new trades can be entered, according to the Supertrend signal Further Trade Management Functions and Trade Filters: High Impact news events: Option [TRUE/FALSE]: Don’t open trades within [30] [minutes] before and [120] [minutes] after big news events. Days and times to trade: Monday: Don’t open a new trade before [09:00] Don’t open a new trade after [22:00] Tuesday: Don’t open a new trade before [09:00] Don’t open a new trade after [22:00] Wednesday: Don’t open a new trade before [09:00] Don’t open a new trade after [22:00] Thursday: Don’t open a new trade before [09:00] Don’t open a new trade after [22:00] Friday: Don’t open a new trade before [09:00] Don’t open a new trade after [22:00] Manual trade entry I would like the ability to be able to open a trade manually and have it managed by the EA. Is that possible? Exit trades on a “spike” candle The EA should exit any trade on a “spike” candle in the direction of the trade (“spike” defined as the move from open to close on one candle of [20] pips). Avoid trade entry on a “spike” candle The EA should NOT open a trade on a signal if the candle size (open to close) which triggers the trade > [20] pips in size (open to close). Allow late confirmation In some cases, the Supertrend will cross first, stay that way, then the EMA crosses in support later. The EA should allow such “late confirmation” if the EMA cross is up to [2] candles after the Supertrend signal Magic Number: xyz Please feel free to suggest enhancements to this brief. __________________________________________________ Option 2: Is it worth having a separate trailing stop? As the rules currently work, the Supertrend is effectively a stool loss, with a cross below the (rising) Supertrend (in a BUY trade) being the level of the stop loss. For example, is it possible to have a trailing stop below “the previous swing low / swing high”?