TANGIER Germany30 Strategy– Time frame 30 minutes
Forums › ProRealTime English forum › ProOrder support › TANGIER Germany30 Strategy– Time frame 30 minutes
- This topic has 33 replies, 10 voices, and was last updated 5 years ago by
Sebastian Arsjo.
-
-
02/13/2019 at 2:19 PM #91286
Hello everybody,
I post here a strategy that I am using with real money.
It uses trend direction (slope) of the 20 periods moving average and the price momentum.
Orders are then triggered once the RSI 20 periods enter in overbought and oversold areas.
Tested with 100k bars: if someone could test it with 200k bars and let me then know the result, this would be many appreciated!!
Best regards.
123456789101112131415161718192021222324252627282930313233343536373839// Definizione dei parametri del codiceDEFPARAM CumulateOrders = False // Posizioni cumulate disattivateDEFPARAM FLATBEFORE = 090000DEFPARAM FLATafter = 175500indicator1 = RSI[20](close)c1 = (indicator1 CROSSES OVER 70)c8=close>average[20]c65=Momentum[12]>momentum[12][1]c66=momentum[12][1]>momentum[12][2]IF c8 and c1 and c65 and c66 THENBUY 2 CONTRACT AT MARKETENDIFindicator2 = RSI[20](close)c2 = (indicator2 CROSSES UNDER 60)c13= average[20]<average[20][1]IF c2 or c13 THENSELL AT MARKETENDIFindicator3 = RSI[20](close)c3 = (indicator3 CROSSES UNDER 30)c34=close<average[20]c65=Momentum[12]<momentum[12][1]c66=momentum[12][1]<momentum[12][2]IF c3 and c34 and c65 and c66 THENSELLSHORT 2 CONTRACT AT MARKETENDIFindicator5 = RSI[20](close)c5 = (indicator5 CROSSES OVER 40)c13= average[20]>average[20][1]IF c5 or c13 THENEXITSHORT AT MARKETENDIFSET STOP pLOSS 40SET TARGET pPROFIT 401 user thanked author for this post.
02/13/2019 at 2:29 PM #91289Is the strategy the same than the one you post 2 weeks ago? It is already featured in the library: https://www.prorealcode.com/prorealtime-trading-strategies/tangier-germany30-time-frame-30-minutes/
02/13/2019 at 2:32 PM #91290Hey good! Now we have a discussion Topic for your strategy in the Library
I’ve got 3 versions of your strategy running on Demo Forward Test since 10 Feb 19 … see attached for TF and market.
You have to satisfy my curiosity … why is your strategy described as Tangier (am I missing some trading lingo?? 🙂 )?
02/13/2019 at 2:58 PM #9129402/13/2019 at 3:20 PM #9130402/13/2019 at 8:19 PM #91326Hi, for what its worth i did something to this as well. I optimized everything “very quick and dirty” meaning i didnt want to spend too much time on this but i wanted to see what i could make of it.
I found that the algo gets better results by removing the time restriction + the c8 buy condition / c34 short condition after that i did the following:
- I split stop loss and target for when a trade is “longonmarket” and “shortonmarket”, optimized the stoploss and targets on data from 2012 – 2015,. The stoploss / targets was optimized before the other variables..
- I optimized on the data that @discomusic did not have. Meaning the “out of sample” period is indeed @discomusic’s “in sample” period (not sure if he has optimized on 100% of his available data or not) so this is obviously a red flag. In other words I have optimized the first 50% of the data, and he has optimized the last 50% of the data.. How much is this curvefit.. no idea.. I honestly like the Out of sample “long only” results and im gonna put it in demo to see how it goes..
- I think that you could optimize this alot “better” than what i did. I used big intervals and i havnt optimized target & stop loss, after the new variables have been optimized.
- I would say “long only” looks better than going long and short, based on my optimizing.
- In the picture included: For the “long only” i just removed the shorting-code. Its the same “long variables” as the “Long and short” variables
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758DEFPARAM CumulateOrders = False // Posizioni cumulate disattivate//n1 = 20 (opt 16-24 w/ 2 intervals)//n2 = 70 (not optimized)//n3 = 12 (opt 8-16 w/ 2 intervals)//n4 = 30 (not optimized)//n5 = 50 (opt 50-70 w/ 10 intervals)//n6 = 40 (opt 30-50 w/ 10 intervals)//e1 = 65 (opt 35-75 w/ 10 intervals)//e2 = 75 (opt 35-75 w/ 10 intervals)//e3 = 55 (opt 35-75 w/ 10 intervals)//e4 = 45 (opt 35-75 w/ 10 intervals)indicator1 = RSI[n1](close) // 20c1 = (indicator1 > n2) // 70c65=Momentum[n3]>momentum[n3][1] // 12c66=momentum[n3][1]>momentum[n3][2]IF c1 and c65 and c66 THENBUY 2 CONTRACT AT MARKETENDIFindicator2 = RSI[n1](close)c2 = (indicator2 CROSSES UNDER n5) // 60c13= average[n1]<average[n1][1]IF c2 or c13 THENSELL AT MARKETENDIFindicator3 = RSI[n1](close)c3 = (indicator3 CROSSES UNDER n4) // 30c65=Momentum[n3]<momentum[n3][1]c66=momentum[n3][1]<momentum[n3][2]IF c3 and c65 and c66 THENSELLSHORT 2 CONTRACT AT MARKETENDIFindicator5 = RSI[n1](close)c5 = (indicator5 CROSSES OVER n6) // 40c13= average[n1]>average[n1][1]IF c5 or c13 THENEXITSHORT AT MARKETENDIFif longonmarket thenSET STOP pLOSS e1 // 65SET TARGET pPROFIT e2 // 75endifif shortonmarket thenset stop ploss e3 // 55set target pprofit e4 // 45endif2 users thanked author for this post.
02/13/2019 at 8:59 PM #9132902/13/2019 at 9:13 PM #91333Oh i forgot to say, i also made another change to the original code: I Changed
indicator1 = RSI[n1](close) // 20c1 = (indicator1 > n2) // 70From crosses over to just >, i was testing out stuff regarding the time-restrictions1 user thanked author for this post.
02/13/2019 at 10:46 PM #9133902/13/2019 at 10:51 PM #91340Pic is 25 minutes dax
So are you making the point that on 25m TF (using the 30m TF optimised variables) that results are still good so that is a good sign??
02/14/2019 at 12:28 AM #91342Yes, changing the candles so its not 12:00, 12:30, 13:00, 13:30, but rather 12:00, 12:25, 12:50, 13.15 (at least in my head) should scramble up the data alot.
If this strategy is doing anything it is trying to capture momentum, and by the looks of it, 25-35 minute candles seem to get the most of it using this strategy.
That being said im going to put this in a drawer for 6 months or more. Because i didnt make it, and it might be super curvefit bullshit. If i optimized on the first 50% of the data using very similar and already optimized variables coming from the second half of the 50%, that might just make this a basicly 100% of the data curvefit algo..
if it keeps delivering results month after month tho, i might run it.
- It dosnt seem to just break down and drain ur account, should be able to spot it turning bad before anything massive happens..
- max drawdown seems OK, if u run Long only u can get an even better max drawdown.
- The profit looks pretty evenly spread which also is a good sign..
- The strategy itself is pretty simple as well, not a whole lot to it. Couple of entry conditions and exit conditions, nothing crazy.
- When market is going down, the algo is going flat, as soon as market touches “bottom”, the algo starts making profits again. Looking very good as it should. With these types of conditions you cant really expect it to make alot of money as the market is plummeting -20%, yes you will have a few small “rallys” here and there while price is going down, and if you zoom in during those times, those small rallys are actually whats keeping the algo more or less at 0 when markets are dropping, very nice. Might be super curvefitted, might actually be something. Time will tell i guess.
1 user thanked author for this post.
02/14/2019 at 12:41 AM #91343Im talking about Long only version.
Would also like to add that if you remove the exit codes, or if you remove the target and stop loss, the algo still looks pretty decent. I would say this speaks to a decent entry.
1 user thanked author for this post.
02/14/2019 at 11:36 AM #91354Hello,
Thank you Jebus for the new version. It looks really good on 200K! Some questions:
1.You have no time limits (flatbefore, flatafter) in the code attached. My result gets better when using trading hours on your code. Do you use that or is there a reason for excluding it?
2. When taking this to the Wallstreet H1 it doesnt show a result anymore. Have you optimized for that market as well? The old version showed good result whithout optimization which was really promising (100% OOS for Wallstreet).
I will take both of them to demo as well as Wallstreet H1.
Discomusic had some other tests done, it would be interesting to see them as well.
I sorry, but I cannot contribute to this one 🙂
02/14/2019 at 12:30 PM #91358When taking this to the Wallstreet H1 it doesnt show a result anymore.
What are your trading hours?
I ask because if they are for example 09:30 etc then on a 1H TF the half hour will never be hit and so this is likely why you get no results??
02/14/2019 at 12:57 PM #91371Hello,
Thank you Jebus for the new version. It looks really good on 200K! Some questions:
1.You have no time limits (flatbefore, flatafter) in the code attached. My result gets better when using trading hours on your code. Do you use that or is there a reason for excluding it?
2. When taking this to the Wallstreet H1 it doesnt show a result anymore. Have you optimized for that market as well? The old version showed good result whithout optimization which was really promising (100% OOS for Wallstreet).
——————————————————
1. I removed the time just because i wanted to see what would happen. I havnt really “worked” this code alot, just tried to add and remove a couple of things. If you got better results adding a timefilter then that might be good to do in real life as well.
2. Im not sure why u cant see results for 1h wall st anymore? Nothing in the code should make that happen. Im getting results and the results look way worse than before. Would this mean that “my optimization” has curvefit it alot more than the original code? Maybe. Is that a bad thing? Well who knows, is the answer.. Guess we just gotta throw this into demo (for me at least 6 months i think..) I have not optimized this for anything else than 30m dax.
I dont trust this code from the get-go. Cus i didnt make it. Biggest red flag i would say is that it is optimized on 50% of the data, then re-optimized using very similar variables on the other 50% of the data. I think this should be a huge red flag and justify why you should throw it into demo for a long time..
-
AuthorPosts