Работа завершена
Техническое задание
1: This is a momentum based, breakout trading methodology on a Range Bar based offline chart using the "Night Nurse" and "Night Nurse Extra" indicators. The "Session" indicator is to filter out negative R:R as well as target profits and move S/L.
2: Opening Position is determined when Night Nurse and/or Night Nurse Extra signal. S/L is set to the extreme (H/L) of the previous candle. (i.e. if Night Nurse and/or Night Nurse Extra signal a long entry then S/L is placed at previous candles low)
2a. Entry candle must have an open time past the user defined time (default 1000 server time)
-note; Range bars candles are timeless and open at a non-interval rate. The signal CANDLE itself must have the open time greater than user defined setting, NOT server's time.
2b. Position size user defined as either lot size or based on account %
3: Take Profit is user defined based on the total session range (default 60 pips from 1000-1800)
4: S/L is moved to B/E when session reaches user defined range (default 40 pips)
5: Option to filter out trades with a user defined R:R ratio (default 1:1). (e.g. If the session reached a 36 pip range when signaling an entry and has a S/L of 25 pips. Then, with a target set to a 60 pip session range, the distance to profit would be 24 pips with a S/L of 25. This R:R would be less than 1:1 and signal would be ignored).
-note; Set to zero to use range in pips filter.
6: Option to filter out trades with a user defined session range in pips (default 32). (e.g. session starts a 1000 price makes a range of 32 pips and then if Night Nurse or Night Nurse Extra signal entry it is ignored)
7: Option to enter on reversal If a signal is skipped/ignored. (default off)
7a. Entry on signal in opposite direction of ignored signal if still within user defined session times.
7b. S/L is previous candle High or Low. TP user defined (default 40 pips)
8: Option to enter on user defined consecutive signals (default 1). (e.g. If set to 2, then, when Night Nurse or Night Nurse Extra signal long then entry would be on either/or the next long signal. If both indicators signal on same candle, then entry is taken as well.)
8a. Must be consecutive signals, but not consecutive candles. If Night Nurse Extra signals long and Night Nurse signals short, then entry would be taken on next short signal by either indicator.
To summarize;
After a specified candle open time, the EA looks for a signal from the indicators while measuring the price range of the session. If within parameters, the EA opens a position in the direction of the trade signal, it sets s/l to previous candle (H/L) and sets T/P to where the range of the session reaches specified pips. S/L is moved to B/E when the session's range exceeds the set value to do so. If the signal is not taken due to the session's range being larger than set value, then, the EA looks for a signal of the opposite direction to enter (optional). S/L set to previous candle (H/L) and T/P set to pips away from session (H/L). Option to have entry after consecutive signals as well.
(i.e.) I am watching London session. Starting at 1000 mt4 time. During the first hour price moves in a range of 20 pips. Its now 1100 and the next range bar closes with one of the Night Nurse indicators signaling long. The range bar's open time is 1037 and the parameter is set to have an open time past 1000 so the position is opened with t/p set to 40 pips away as the EA see's the session is already has a range of 20 pips and the parameters are set to place t/p where the session reaches 60 pips. The s/l is set to the previous candles low. Price then moves in my favor, expanding the sessions range another 20 pips. The EA now sees the session’s range is at 40 pips and moves s/l to b/e. Price hits t/p and the party begins.
(If the session’s range would have been 32 and more, or the open candle time was set to 1100 instead of 1000, then the signal would have been ignored and the EA would be looking for a reversal signal.)
Here's a link to the range bar Indi, dll and instructions
http://liveforexsignal.com/download/Range-Bars-Chart-Indicator