Quote from no_pm_please:
I'm no TS expert, but the weaknesses in offshore's code that I see are:
- the system doesn't take the sequence of events necessary for a trade to be initiated into consideration. It just looks for the evidence of the events having occurred. It's important to not look for divergence before the adx crosses above 30, rather than spotting divergence and then adx crosses 30 so a setup is initiated. This is not a valid trade setup.
It really doesnt matter, the whole trade setup won't initiate until adx is above 30...
- it doesn't seem to take the momentum into effect at all. Both to confirm the divergence and initiate the wait for the down bar.
Didn't know there was a momentum side to consider...
- the divergence is only detecting large long term (20 bar) divergences. In real trading a divergence of 2 or 3 bars is easy to see with the eye.
The 20 strength is how long to detect divergence between two swing points....
- the method does not need to be above the upper keltner channel, however trades can't be initiated when the market is trading more than the stop amount from the high bar before entry.
The subjective part here can't be coded unless there is hard, fast rules...
- the exit limit price is wrong since it's calculated on the previous bar. The target exit point moves intrabar and somehow this needs to be taken into consideration.
TS does bar by bar analysis, so the whole code is written and execute done on each bar... from what I can tell, it exits fine.
- the time for initiating a trade should go out to 230 and outstanding trades need to be exited on the close
I added the closing condition and it didn't have any affect.