EURUSD daily strategy
Forums › ProRealTime English forum › ProOrder support › EURUSD daily strategy
- This topic has 15 replies, 4 voices, and was last updated 6 years ago by Vonasi.
-
-
02/12/2018 at 1:34 PM #62173
eurusd strategy that works for very long time on daily TF.
Walk forward parameters:
rangemin
pr
period
No walk forward on seasonality parameters. (day and month forbidden)
1234567891011121314151617181920212223242526272829303132333435363738394041424344//-------------------------------------------------------------------------// Main code : eurusd_TF_daily//-------------------------------------------------------------------------DEFPARAM cumulateOrders = False // Cumulating positions deactivated///parameter definition//inputsrangemin = 3pr = 170period = 10dayforbiddenlong =4dayforbiddenshort = 2monthforbiddenlong =1monthforbiddenshort =4//variablesmav = average[period](close)oscillator = close-mavrossa = (Dclose(0)-Dopen(0))<0verde = (Dclose(0)-Dopen(0))>0rangetoday = abs(Dclose(0)-Dopen(0))//entry conditioncl = oscillator > 0cl = cl and rossacl = cl and rangetoday > rangemincl = cl and dayofweek <> dayforbiddenlong and month <> monthforbiddenlongcs = oscillator<0cs =cs and verdecs = cs and rangetoday > rangemincs = cs and dayofweek <> dayforbiddenshort and month <> monthforbiddenshortIF cl THENbuy 1 PERPOINT AT MARKETENDIFif cs thensellshort 1 perpoint at marketendif//exit conditionset target pprofit pr02/12/2018 at 1:39 PM #62426Hi Francesco! Been a long time since your last post 🙂 Thanks a lot for this new automatic trading idea.
I get almost the same result as you, but I need to understand something for a better comprehension, what is rangemin? Is is in pips? is it 3 or 30 pips?
With a PRT-CFD account, EURUSD is 5 decimals, so I guess we must adapt this value to the correct pip size?
I made this modification:
1234567891011121314151617181920212223242526272829303132333435363738394041424344//-------------------------------------------------------------------------// Main code : eurusd_TF_daily//-------------------------------------------------------------------------DEFPARAM cumulateOrders = False // Cumulating positions deactivated///parameter definition//inputsrangemin = 30pr = 170period = 10dayforbiddenlong =4dayforbiddenshort = 2monthforbiddenlong =1monthforbiddenshort =4//variablesmav = average[period](close)oscillator = close-mavrossa = (Dclose(0)-Dopen(0))<0verde = (Dclose(0)-Dopen(0))>0rangetoday = abs(Dclose(0)-Dopen(0))//entry conditioncl = oscillator > 0cl = cl and rossacl = cl and rangetoday > rangemin*pipsizecl = cl and dayofweek <> dayforbiddenlong and month <> monthforbiddenlongcs = oscillator<0cs =cs and verdecs = cs and rangetoday > rangemin*pipsizecs = cs and dayofweek <> dayforbiddenshort and month <> monthforbiddenshortIF cl THENbuy 1 PERPOINT AT MARKETENDIFif cs thensellshort 1 perpoint at marketendif//exit conditionset target pprofit prBelow is the test with 30 pips.
02/12/2018 at 2:09 PM #62431Hi Nicolas,
I see your point, yes It should be 30 pips indeed, I have it quoted 12264.5-12265.0 and 3 is a variation of 3 of your 4th decimal digit.
I have uk account, pls see if with GMT it is more similar..
Many thanks!
Francesco
02/12/2018 at 4:30 PM #62441Hi Francesco
I took the liberty to optimize your code on IG prt eur/usd.
I also added a stop loss. A big chunk of the profit disappeared but the draw down is down 60%. I optimized it from year 2000 until today. Before is oos.12345678910111213141516171819202122232425262728293031323334353637383940414243DEFPARAM cumulateOrders = False // Cumulating positions deactivated///parameter definition//inputsrangemin = 5pr = 70pl = 80period = 7dayforbiddenlong =4dayforbiddenshort = 2monthforbiddenlong =1monthforbiddenshort =4//variablesmav = average[period](close)oscillator = close-mavrossa = (Dclose(0)-Dopen(0))<0verde = (Dclose(0)-Dopen(0))>0rangetoday = abs(Dclose(0)-Dopen(0))//entry conditioncl = oscillator > 0cl = cl and rossacl = cl and rangetoday > rangemin*pipsizecl = cl and dayofweek <> dayforbiddenlong and month <> monthforbiddenlongcs = oscillator<0cs =cs and verdecs = cs and rangetoday > rangemin*pipsizecs = cs and dayofweek <> dayforbiddenshort and month <> monthforbiddenshortIF cl THENbuy 1 PERPOINT AT MARKETENDIFif cs thensellshort 1 perpoint at marketendif//exit conditionset target pprofit prset stop ploss pl1 user thanked author for this post.
02/12/2018 at 4:46 PM #62444@T-rader Cool, but that’s a range filter of about only 5 pips on a daily timeframe 🙂 What difference without it? I got almost the same result as you, but without the tick by tick option.
Below is the result I have with the tick backtest and a spread of 2 pips. Timezone is UTC 0 (default forex timezone).
1 user thanked author for this post.
02/12/2018 at 4:54 PM #62449Tick to tick shouldnt matter right? we dont have stop and profit on the same candle. yes I agree its a bit weird to have e pips filter.You can set it to zero but the results will be worst. The point of this strategy is that is working since 1980.
.
02/12/2018 at 5:05 PM #6245202/12/2018 at 5:14 PM #62457Tick to tick shouldnt matter right? we dont have stop and profit on the same candle.
Why? I got many “zero bars orders” in the orders list.
02/12/2018 at 5:28 PM #62460Tick to tick shouldnt matter right? we dont have stop and profit on the same candle.
Why? I got many “zero bars orders” in the orders list.
Yep you are right, Im writing a version that have no zero bars. Posting soon
1 user thanked author for this post.
02/12/2018 at 5:45 PM #62462voila’, I got rid of 2 parameters (rangemin and pr ), no zero bars now
123456789101112131415161718192021222324252627282930313233343536373839//-------------------------------------------------------------------------// Main code : eurusd_TF_daily//-------------------------------------------------------------------------DEFPARAM cumulateOrders = False // Cumulating positions deactivated///parameter definition//inputsperiod = 7dayforbiddenlong =4dayforbiddenshort = 2monthforbiddenlong =1monthforbiddenshort =4//variablesmav = average[period](close)oscillator = close-mavrossa = (Dclose(0)-Dopen(0))<0verde = (Dclose(0)-Dopen(0))>0//entry conditioncl = oscillator > 0cl = cl and rossacl = cl and dayofweek <> dayforbiddenlong and month <> monthforbiddenlongcs = oscillator<0cs =cs and verdecs = cs and dayofweek <> dayforbiddenshort and month <> monthforbiddenshortIF cl THENbuy 1 PERPOINT AT MARKETENDIFif cs thensellshort 1 perpoint at marketendif02/12/2018 at 7:53 PM #6247702/12/2018 at 8:39 PM #6248502/12/2018 at 11:21 PM #62507yes Nicolas, that is the case.
02/13/2018 at 11:44 AM #62558Nicolas do oyu think we can post this last version in the library?
Thank you
02/13/2018 at 11:47 AM #62560yes Nicolas, that is the case.
Ok, so that explain the large drawdown.
Nicolas do oyu think we can post this last version in the library?
Yes, just after a quick review 😉
1 user thanked author for this post.
-
AuthorPosts
Find exclusive trading pro-tools on