Results 1 to 4 of 4

Thread: Matlab for Backtesting

  1. Default Matlab for Backtesting

    I have been building mechanical trading models in excel for a time now, but have decided that i need to move on to something more powerful for future models.
    The attached spreadsheet is a small example of how I have typically built models. Trade signals are shown as a 1, generated by various methods not shown. A trailing stop handles the exit.
    Has anyone built a model in Matlab similar to this, or has seen something on the net where I could gain some insight to cut down on my learning curve?
    I want to use matlab for its optimisation abilities, but my biggest problem has been how to get the trade entries/exits/PnL to work.

  2. #2
    AndrewAbugs Guest


    Haven't done anything similar, but there are some excellent webinars on the Mathworks site.

  3. Default

    I have viewed the webinars, but it deals more with the optimisation once the framework is set up. I have been able to import my data and generate entry/exit signals, but am having trouble with calculating the profit of trades. Has anyone has experience with this before?

  4. Default

    You could have a sift around on this blog Quantitative Trading as the guy uses Matlab for his quantitative strategies. I have just bought his book which has some examples of Matlab coding, mainly for strategy back-testing, however I really couldn't recommend it yet as I haven't finished reading it. Perhaps have a browse at your local B&N.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts