Hi all,
I feel it is a good strategy to enter/open order using Moving Average Crossover (MA20,MA50,MA100,MA200 ).
However, i don't think it is a good strategy to exit by Moving Average Crossover
Any of you have a better idea for the exit strategy ? using TP and SL ? using MACD crossover ?
How about using time exit strategy ? where if the MA is in H1 chart, the order will be closed after xx hour no matter win lose . How do you think ?
Thanks
From
erekit
Hi engcomp,
You are using so much strategy for entry. Do you program your own EA ? Is it working well ?
No worry, I will not ask to get your EA. Just interested to know how well is the entry and exit strategy you used.
To me, using trailingstop though can reduce us from loss risk but it also limits the TP.
Hi engcomp,
You are using so much strategy for entry. Do you program your own EA ? Is it working well ?
It's very simple. I developed a template where all components that are common to all EAs are proven to work, for example:
count_position(), CloseAll(), CloseLongs(), CloseShorts(), SetStops(), SetTrailingStops(), CheckForClose(), OpenLong(), OpenShort(), etc.
I set the global variables for the strategy in start() and program the entry strategy in a function called get_signal().
The template also includes functions for money management, Call_MM(), and facilitates control over the EA while running.
For example, you may not want it to take a new position but still manage the exit strategy. Or you may want to add a position manually.
The template is working well. Some of the strategies can be improved with the introduction of filters.
All the components I use are freely available on this very generous forum, which has been the source of my template.
Thanks for the great tips.
I guess I myself need to start develop the template with the components as you did
from last time till now, I usually write from scratch
It's very simple. I developed a template where all components that are common to all EAs are proven to work, for example:
count_position(), CloseAll(), CloseLongs(), CloseShorts(), SetStops(), SetTrailingStops(), CheckForClose(), OpenLong(), OpenShort(), etc.
I set the global variables for the strategy in start() and program the entry strategy in a function called get_signal().
The template also includes functions for money management, Call_MM(), and facilitates control over the EA while running.
For example, you may not want it to take a new position but still manage the exit strategy. Or you may want to add a position manually.
The template is working well. Some of the strategies can be improved with the introduction of filters.
All the components I use are freely available on this very generous forum, which has been the source of my template.
Excuse me Engcomp, I'm new here and i'm just learning to develop EA, could you kindly post the link where to find the components you use?
Thank you very much.
Excuse me Engcomp, I'm new here and i'm just learning to develop EA, could you kindly post the link where to find the components you use?
Thank you very much.
To me, using trailingstop though can reduce us from loss risk but it also limits the TP.
Very correct. I find setting trailingstops the most challenging part in optimizing an EA.
Set it too close and you could be knocked out from a great trend.
Set it too far and you are giving back too much in a short trend.
In my opinion, parabolic SAR is an excellent model for intelligent stops. Not perfect but excellent.
Anyone knows a better model, please let us know.
Thanks for the great tips.
I guess I myself need to start develop the template with the components as you did
from last time till now, I usually write from scratch
engcomp:
In my opinion, parabolic SAR is an excellent model for intelligent stops. Not perfect but excellent.
Anyone knows a better model, please let us know.
stopATR = Bid - SL.Trail.ATR*ATR.value;
See also ATRStops_v1 [ 1 ]. 1 - MQL4 Code Base// once per bar static int LBcntB=3, LBcntS=3; if (High[1] > High[2]) LBcntB = MathMax(SL.bars.Minimum, LBcntB-2); else LBcntB++; if ( Low[1] < Low[2]) LBcntS = MathMax(SL.bars.Minimum, LBcntS-2); else LBcntS++; H.H = High[Highest(NULL,0, MODE_HIGH, LBcntS, 0)]; // stop.bars L.L = Low[ Lowest(NULL,0, MODE_LOW, LBcntB, 0)]; // stop.bars ... stop.bars = MathMin(Low[0], L.L) - SL.Extra.Pips*pips2dbl - SL.Extra.ATR*ATR.value;
extern int SL.bars.Minimum = 3; extern double SL.Extra.ATR = 0.1; extern int SL.Extra.Pips = 1; extern double SL.Trail.ATR = 2.8; extern int ATR.Period = 29;

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi all,
I feel it is a good strategy to enter/open order using Moving Average Crossover (MA20,MA50,MA100,MA200 ).
However, i don't think it is a good strategy to exit by Moving Average Crossover
Any of you have a better idea for the exit strategy ? using TP and SL ? using MACD crossover ?
How about using time exit strategy ? where if the MA is in H1 chart, the order will be closed after xx hour no matter win lose . How do you think ?
Thanks
From
erekit
https://www.mql5.com/go?link=http://100k2.blogspot.com//