Optimization moving average crossing strategy

Forums ProRealTime English forum ProOrder support Optimization moving average crossing strategy

Viewing 15 posts - 61 through 75 (of 186 total)
  • #126008

    hi Nonetheless,

    I have been back tested your 69 cross over strategy for the last week or so and its great.

    I have decider to try automated trading and was setting up for th coming week and the program has asked me to remove all variables in the protback test section.

    Can you help with this?

    Thanks

     

    #126034

    Can you help with this?

    Please don’t go Live with any strategies until you are familiar with everything?

    Have you checked under Help on the top menu bar?

    Watch the video on the link below, it may answer your questions?

    https://www.prorealtime.com/en/videos_tutorial/142_trading_system_backtest_optimization

    Also read the PRT Manual on the link below …

    https://www.prorealtime.com/en/help-manual/create-trading-systems

     

     

     

    #126054

    Hi @rsd001

    A few things to mention: first, I didn’t build this system, I only made some minor modifications and started the discussion. You have @Jan and before him @Laurenzo to thank for doing all the heavy lifting.

    Second, as @Grahal says, not a good idea to jump in too fast unless you mean to start running it in demo mode; that’s always a good place to start til you get a feel for how it behaves.

    As for removing the variables, that means inserting the values from the optimization window into the body of the code. For example, you need to have (or to find, if it already exists) a couple of lines that say

    MAType =

    MATypeV2 =

    where you put the corresponding numbers that the optimization found for you. Then you have to delete everything from the opt window before you click Prepare for Automatic Trading. Hope that helps.

    2 users thanked author for this post.
    #126738

    I appreciate the help.

    Im till back testing, and managing to learn slowly.

    Im struggling with one area, on my EMA Cossings, Ive got it to work, but for example a 10 mms time frame, its opening on an ema cross over which occurred at 8.00  at 8.20, is there anyway I can get this to happen on the same candle or at least the next one instead of missing the second 10 min candle?

    #126739

    its opening on an ema cross over which occurred at 8.00  at 8.20

    Best you provide screen shots of above as otherwise we’ll be guessing what may be the cause?

    If you post the exact code that produces what you say above then I would run it for you on my platform and see if I get the same problem?

    Others may also spot an issue in the code if you post the code.

    #129233

    Hi Jan / Everyone.

    I am new to ProRealTime and the forum, so with this being my first post. Please forgive me.

    Great indicator btw, love it.

    I found an awesome MA cross on GBPAUD after countless testing on various TF’s etc. I found this by doing the walk forward method which gave me above 50%. After doing some further extensive testing  with the periods etc I came to a conclusion with the set up. Ran this set up and it gave me different results. I noticed that this must be down to the EMA which filters noise.

    I was wondering how the EMA plays a part in this whole strategy and how it filters out the noise exactly? Does the strategy only enter when the cross happens above the 30EMA or below? How is it playing a part so I can incorporate this into my strategy.

    I have attached 3 screenshots.

    The first is the comparison between the 2 results.

    The left being my current setup which has no EMA incorporated, performs pretty poorly in my honest opinion.

    The right is the performance based upon YOUR strategy, with minor tweaks.. such as period change, and a DEFINITIVE set type of EMA’s.

    Looking at these you can see that my version is in and out the market more, where as your version is more conservative, presumably down to the EMA playing a part.

    Also the timing seems to be off.. with the entries. Both are set to the same time and exit points, but seem to be entering at different times.
    One version (e.g. Mine enters sometimes at 8:00, your’s waits and enters at 10:00)

    Both set to start the backtest at 1st May 2015 however your strategy doesn’t enter it’s first trade until a month later.. on 4th June 2015

    Hopefully I have given you enough information to help, and that it’s not too overwhelming.

    Many thanks.

    #129235

    For some odd reason, the first attachment isn’t readily seen on my previous post, therefore I am posting it here.

    Apologies in advance.

    #129251

    Does the lower curve use a ‘crosses over or under’ condition?

    Reason I ask : if other conditions are combined  with ‘crosses over / under’ then a trade can be a long time coming.

    Also I note that while the equity curve was flat so also  was the price curve and then it went down and then back up … so this may have given a crosses over trigger?

    Both Systems appear to have good performance overall per quarter … judging from the white histo bars??

    #129290

    how the EMA plays a part in this whole strategy and how it filters out the noise exactly?

    There is no EMA 30 as such, it’s a 30 period exponential applied to the AFR – ie it averages the selected MAType.

    In the above code, the brackets are the period and the parenthesis is what it is applied to. A standard EMA would be exponentialaverage[30](close) or (typicalprice).

    Looking at your results, there’s a few things that stand out. Like, one shows 11k profit and the other shows 213k. That’s quite a difference, or is MM applied to the second? Also, 66 trades in 5 years seems v low, 1 per month.

    #129651

    Something i found playing around with DAX  1H and  Jan’s excellent algo

    MiniPos size 2

    You can play around and change the time to stop taking trades from 21.00 to lets say 14.00 or change the stop loss from 2% to 2,50% or 1,80 %

    It will mostly just affect the number of trades taken but the overall profitability will still be roughly the same. i like it when a change in variables wont brake the entire strategy

    I am very new to this so it is probably curve fitted , not back tested in any meaningful way. and it runs very flat for long periods of time  so be kind and dont use it LIVE

    But maybe someone who is better then me at this things can make something out of it

    I like it when people share their work so i mostly just wanted to share something back even if it is not great

    #129657

    Here’s a variation I’ve been working on, adds some of my go-to indicators and another TF. I tried lots of other stuff as well – smooth stochastic, Parabolic SAR etc but this is the best combination I could find. All suggestions welcome.

    It keeps @Jan’s excellent OTD idea … but expands it to OTD in multiple time slots. So, you’re looking for 1 trade between 08 – 10, 1 trade 10-12 etc etc. with a different crossing pair for each. I have tried to keep the other variables to a minimum; Supertrend and StochasticRSI stay at their defaults, SL and TP stay at 1% and 2%. The only things I optimise are the 2 MAs (period,type) and the trailing stop although this is optional.

    This was designed primarily for short TFs. I’m using it mostly at 5m with 15m in the upper TF but if you don’t mind shorter back tests then 2m/6m and 1m/5m also give good results. Should get you ~90% wins on almost anything you point it at, often higher.

    A word of warning: these tend to do very well in WF analysis but v poor in VRT. I don’t know why that is. Maybe it doesn’t work to randomise something that’s only doing one trade per day? After all, if it finds the entry conditions, that’s the trade you’re going to get that day, end of story. Trades are rarely still open the next day. Whatever the reasons, it’s something to be aware of. If you’re hooked on VRT results then this is prob not for you.

    Best of luck with it.

    1 user thanked author for this post.
    #129662

    Here’s the DJ 5m itfs

    1 user thanked author for this post.
    #129667

    And I know you like micro-trend TFs, so @GraHal, this one’s for you (not OTD)

    3 users thanked author for this post.
    #129674

    Here’s the code I added

     

    #129701

    it is not necessary to insert the values : mb; mb2; mc; mc2?
    inside the code?

Viewing 15 posts - 61 through 75 (of 186 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login