Using machine learning to Improve systematic trading

Discussion in 'Strategy Building' started by Rogerahan, Aug 12, 2017.

  1. Rogerahan

    Rogerahan

    I separated the trading data into 3 groups (Training, CV, Test). But only used the test set data group for an unbiased comparison of the results of the original and ML improved algorithm.

    Based on trading 1 contract with an account value of $3960 (Initial margin value). over 1yr and 2 months (test set data length).

    The original very simple market timing strategy had a drawdown of (-81%) with a cumulative return of (146%) with 100 trades taken.

    While the machine learning improved algorithm had a drawdown of (-42%) with a cumulative return of (145%) with 52 trades taken.

    Personally, I would think the original algorithm was to risky trade as it is. However the ML improved algorithm really could be traded as its risk profile is better.

    Since the DD percentage is based on an account the size of an initial margin it automatically has 16X leverage. I think It would be prudent to drop the leverage down by a third or so which would give the ML improved strategy a drawdown of (-14%) and a cumulative return of (48%)
     
    #11     Aug 13, 2017
    fordewind likes this.
  2. 1 year is a bit small of a sample, 14% of DD is also a lot.I know the guys doing 25-40% per year in Forex, with 5-7% of DD, with the order flow system.Doubtful ML has any merit.
     
    #12     Aug 13, 2017
  3. themickey

    themickey

    Is machine learning similar to Neural Networks (NN)?
    In other words algos which attempt to curve fit previous market behaviour.
    From what I have gathered is NN was never much of a success, but that is possibly information fed to the public.
    The main advantage I can see is that like automated trading systems they just continually fire off trades without the advent of emotions or fatigue.
    The downside I see is their inability to weigh up the importance of signals be they short term or long term, eg the algos give a weighting to some indicator(s) but those weightings can in reality change in ideal lookback over time.
    Machine learning attempts to trade based on past behaviour but by the time ML has computated and traded on the lookback time, the next ideal lookback time has changed from the previous one.
    Does machine learning work best as a short term trading system, eg intraday?

    The human brain at the moment is the most advanced computer in existance yet even 95% of humans stumble attempting to profit from trading and that's after several years of practice.
    Possibly though a computer which just continually bangs out trades repetitively, cutting losses short and letting profits run may have an edge.
     
    Last edited: Aug 13, 2017
    #13     Aug 13, 2017
  4. Rogerahan

    Rogerahan

    Well I would say by substantially dropping the leverage of the ML improved system, you could get returns of about 25% with a drawdown of about 7% which is quite similar to the metrics you posted.

    However, this paper isnt really about a single stand alone strategy, and I wanted to pick something simple and straightforward to show the logic therein.

    I am curious about why you would say ML has no merit when it reduced the drawdown of the system by about half. what makes you come to that conclusion?
     
    #14     Aug 13, 2017
  5. No extra merit i should say.I said that b/c some OF system does the same, with no additional complexity.
     
    #15     Aug 13, 2017
  6. Simples

    Simples

    Any pro-tips for us dumb ones of resources on how to understand logistics regression, or at least simple examples on how to use it in code (ie. like online linear regression examples)?
     
    #16     Aug 13, 2017
  7. Rogerahan

    Rogerahan

    I definitely wouldn't say your dumb because you don't understand it yet.

    I personally took, and highly recommend Andrew NG's coursera online course on machine learning. You can check out any of the lectures including the one on Logistic regression for free.

    And If you have matlab or octave you can literally copy and paste my codes from the document into files then run the script code.
     
    #17     Aug 13, 2017
    Simples likes this.
  8. traider

    traider

    Hi roger,

    I'm wondering if you have traded professionally (full time) before or you just beginning your journey?
     
    #18     Aug 13, 2017
  9. Rogerahan

    Rogerahan

    Artificial neural networks (NN) are a type of ML algorithm that aims to mimic the way the brains works, in terms of its neurones, synapses, dendrites etc. It uses a method known as forward propagation and back propagation to optimise it's weights.

    It is definitely notorious for overfiting the data. But alot of non linear ML algos are subject to the same variance (overfiting) issues eg Support vector machine algos.

    Ernie Chan and alot of other quants discuss using a rolling window for optimisation of the model, and state that the simpler a model is the better. And I also think out of sample testing is a must.
     
    #19     Aug 13, 2017
  10. Rogerahan

    Rogerahan

    At a few prop shops. But in the past year I switched away from discretionary trading to a more quantitative and systematic methodology.

    It really helps me with my weaknesses.
     
    #20     Aug 13, 2017