MA Price Cross Touch Strategy.Avignon

Strategies are published here.

Moderator: admin

MA Price Cross Touch Strategy.Avignon

Postby Apprentice » Tue Nov 06, 2018 7:11 am

1.png

2.png

Opening and close the trade when the price touches or crosses the shortest moving average
but only if the longest moving average confirms the trend.
MA Price Cross Touch Strategy.Avignon.lua
(27.2 KiB) Downloaded 288 times
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 22710
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: MA Price Cross Touch Strategy.Avignon

Postby Avignon » Tue Nov 06, 2018 12:21 pm

The closing of the trade was not done.

Capture du 2018-11-06 15-47-31.png
Avignon
FXCodeBase: Initiate
 
Posts: 123
Joined: Mon Nov 17, 2014 3:54 am

Re: MA Price Cross Touch Strategy.Avignon

Postby Avignon » Tue Nov 06, 2018 1:21 pm

Or it's a bug, or there must be something to optimize under the conditions in lines of code because it worked.

Capture du 2018-11-06 17-14-57.png
Avignon
FXCodeBase: Initiate
 
Posts: 123
Joined: Mon Nov 17, 2014 3:54 am

Re: MA Price Cross Touch Strategy.Avignon

Postby Jyuken » Wed Jan 23, 2019 8:52 am

Hey apprentice !

Thank you so much for this strategy, I love it and have some good result with it. However I though about a way to improve it and saw some flaws in the positions taken sometimes.

For example here :
the first position was good : buying when short MA > long MA and price cross from the bottom the short MA
the second position was good : selling when short MA < long MA and price cross from the top the short MA
However the third one bothers me : buying because price cross short MA from the bottom despite of the fact that long MA > short MA

So maybe I misunderstood but what do you mean by "if the longest moving average confirms the trend" ?

Moreover I thought about a filter that would improve this strategy : if there is less than n pips separating the two moving average then we do not open a trade. Would it be possible to add that to this strategy ?

Thank you so much for your work, have a wonderful day !
Attachments
probleme strat.PNG
Example illustrated
Jyuken
 
Posts: 1
Joined: Wed Jan 23, 2019 8:30 am


Return to Custom Strategies

Who is online

Users browsing this forum: No registered users and 6 guests