Job finished
Specification
(please advise if I need a custom indicator as well as ea or just an ea)
Ea allows me to change the magic number
Ea runs on multiple charts or can run with different settings on the same chart.
If broker loses connection from the market or if my VPS loses connection to the broker, ea sends warning message via sms and email to 3 people.
Use market orders.
MaxxDD, close all positions.
Button to close all positions in emergency, and stop the ea work.
Input: Pick periodicy.
EA must identify a range.
The range can be flat or it can be diagonal.
(I will be honest, I don't know how to describe exactly how to identify a range in words. I have attached 3 pictures to show you. You will need to have prior experience in building an ea that identifies a range because I will not be able to describe it. If you do not know exactly how to do it, please don't bid on the job. I will definitely be looking for your advice and input on the best way to identify a range condition.)
There will need to be minimum number of "touch" on the top line and bottom line of the range before the ea can conclude that it is a range. ea will need inputs for these.
There will need to be input for minimum number of candlestick gaps before the market "touch" again to the same line. eg. if 3 consecutive candles sticks touch the bottom line, it may not be a range, but if there is minimum gap of 5 candlesticks between each touch, it can be better identifier of range. I will need your advice on this.
The ea will put a colored box over the range after it identifies it.
The ea must have inputs so the "touch" points can have percent tolerance, meaning the range may not be a perfect range, there can exist some imperfections in the range and I must be able to control how perfect or imperfect the range is that I look for. So the touches can be (percent tolerance) short of, or past, the line and the ea recognizes it as a valid "touch".
Option for support or resistance line trading: If for example there at 7 touches on the bottom (support) line but there is no clear top line (the top is out of allowable tolerance), and if the market comes back to the bottom line, trade the range (buy) and if the market breaks out from the bottom, trade the break out with a sell (the buy will be SL).
The ea must have option to specify the maximum and minimum allowable distance from the top to bottom of the range (the distance between the two lines). example, we only want to trade ranges where the distance between the top line and bottom line is maximum 80 pips and minimum 30 pips.
Trade size will be percent of balance.
After loss, option for lot increase. 0= no increase; 1= recoup the prior losses and make the TP.
Option to apply a loss modifier to input 1 above (when recoup method is used).
Eg, after 5 consecutive losses, the next lot is calculated to be 3 lot, but the loss modifier is -50% then the lot will be 1.5 lot. After the 6th loss if the next lot is calculated to be 4 lot and the loss modifier = -20%. then lot size used is 3.2 lot. Need 10 inputs for loss count and 10 inputs for the modifier. if the last modifier is -20, then if further losses happen the ea will apply -20% to each lot size until TP in pips is reached (obviously there will be a loss).
option to trailing stop
option for letting the profit continue to run, until it stops out (increase the tp to capture the move).
inputs for percent tolerance from the last touch point (or option for averaging the touch points on that line) where to place the range order (enter the market) and where to place the breakout order (enter the market). I will need separate input for these types of orders.
The ea will have option to trade the range only, break out only, or both.
The ea will have option to enter trades based on RSI and/or CCI indicators (one or both together, and/or other custom indicator that I will provide). There will be different settings on the indicators for range trading than for break out trading. So we need 2 sets of inputs for both indicators. Upon breakout, even if the indicators show not to trade, if the market breaks out N pips past the point where the breakout position should have been entered, then ignore the indicators and place the breakout order.
Show info on the chart screen
current dd
max dd
current free margin
min free margin
number of wins and loss trades and whether they are range or breakout trades.
max lot used