Back

Any recommended books on algorithm trading strategies?

Does anyone have good tips for books about algorithm trading strategies?

Quantconnect is pretty straitforward with the lean coding, but I need succesfull strategies to implement. 

Update Backtest






The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.



As I wrote in another similar thread, my own favorite beginner book is Building Winning Algorithmic Trading Systems by Kevin Davey, because it's teaching you principles that can allow you to build actually working algorithms without an extremely maths heavy background. It's not focusing on strategies however.

To be honest I haven't found any simple strategy online that I could copy and have working well directly, but I haven't tried them all of course. That being said, it's possible to take an existing strategy and tweak or rethink it in a way that gives acceptable results. In some simplified sense there are only two basic strategies: Momentum and mean reversion (bet on or against the trend), getting familiar with these two concepts gets you far.

Aside from beginner aimed books, I think that initially, you could simply google around and get a feel for what types of strategies works for you (and not). E.g. technical patterns/indicators can be pretty disappointing if you're trying to apply them in a basic manner in an algorithm like discretionary traders do, because they're applying additional filtering in their decisions your algorithm isn't, and a tweak parameter-backtest cycle is prone to overfitting/curve fitting.

Also, what types of strategies you want to look at depends on your mathematics skills - there's a lot of advanced material available online. Especially the Quantopian community has published a lot of useful material, but much of it requires a mathematical/statistical background or a corresponding willingness to learn.

2

Hi Joh,

I think a great introduction to trading strategies is this mini-series of articles at http://www.financial-hacker.com/build-better-strategies/ .

For books, try Evaluation and Optimization of Trading Strategies if you're looking for an emphasis on technical analysis, or Algorithmic Trading: Winning Strategies and Their Rationale by Chan for a broad overview of strategies using Matlab.

And if you're interested in machine learning, here are some simple examples that you can adapt to securities data.

1

Hi guys, Thank you very much for the great feedback really appreciate it! I ordered some books to get quickly up and running on this. 

 

Petter, what is your most succesfull algorithm until now? 
What I am thinking of is the at the moment is to, to pick a pool of stocks I might want to buy. Apple for example. I want to use the moving avarage as buy/sell indications. But problem with moving avarage is that is doesn't work when the marked becomes bumpy. So for example I need to analyse all other stocks in the tech sector with some kind of indicator and take this also in account for final buy/sell decisions. How do you look at that?

0

Recently I'm trying to make a mean reversion intraday algo based on a strong alpha signal I found work in reality, it's been a long running project due to the necessity of accurately modelling slippage. Wish I had HFT infrastructure. ;) What I'm actually algo trading meanwhile is systems run by signal providers, because I don't see a point trading something worse than what I can rent from others. (Except, ensuring the system is tested properly to survive next market crash. There's a lot of over-optimized junk for sale.) Lastly, let me add that I discovered a lot of algorithms that did great before 2016, the market seems to have become a lot more difficult mid 2016 and many strategies with alpha stopped working (ironically, precisely before I seriously started with QC).

On your idea, there are some things to consider.

First, let me say that backtesting Apple has implications because it's a historically very successful stock (well, looking back at the past decade). You need to check your algo does better than buy and hold and that you're able to select similar stocks in the future - not an easy task.

You could go with the universe selection feature of QuantConnect. What it does is to allow you select stocks for further analysis automatically based on some criteria as they were back in that time, as opposed to manually selecting them from today's criteria (that would lead to bias). Unfortunately its in its infancy at the moment and can be a bit slow. There's no "sector" information to filter on to my knowledge, either.

Addressing your particular concerns: Trading a particular strategy only in the "right" market regime is a very difficult problem I don't yet have a reliable answer to. Some alternatives I have tested:

1. Enable/disable or scale allocation of strategies based on their performance in some time window. The problem here is a past returns are not necessarily predictive of future returns, and that the time lag means you're prone to suffer from mean reversion movements.

2. A variant of the above: Track drawdown of a strategy and start scaling it down after a certain point. Always let it have a minimum allocation. Start scaling it back up again with it's draw down isn't increasing anymore. This seems like it can work better than the above, particularly because a strategy's allocation won't get it as long as it's operating within an acceptable drawdown.

3. Self-calibrating algorithms. I.e. my mean reversion algo mentioned above is in this category. In a time window, it calculates some properties of the price behavior in the market and only trades if the characteristics it needs to do its job are prevalent. I have had most success with this approach.

4. Online machine learning algorithms. ("Online" means continously learning even in production here.) Mixed results from this, the scary part about using ML this way is that's you don't really know what's going to happen in the future. It also takes a long time to run backtests with more advanced ML algorithms since they need to be running during the testing. If I had to guess, as ML gets better and better it's going to take over algorithmic trading space completely in a few years time. Working with ML is therefore "investing the future".

On your specific problem, see if you can define "bumpy market" in some way that lets you test for it in code. I guess it would somewhat fall under the self-calibration category, however, I specifically use exactly the same properties as I trade on as the ones I filter on (e.g. frequency of occurrence of a certain price pattern in the past period).

0

Quantitative Trading, Algorithmic Trading, and Machine Trading by EP Chan (http://amzn.to/2m17kfC, http://amzn.to/2myq2xY, http://amzn.to/2lFaGE3). Lots of code (in matlab, but still), and details on how different kinds of strategies work. Really solid.
0

Hi Petter, would you mind elaborating on this statement: "What I'm actually algo trading meanwhile is systems run by signal providers, because I don't see a point trading something worse than what I can rent from others."

Who are the providers you've found worthwhile? Any particular strategy you've found the signals to best complement?

Thanks

0

I'm currently using some strats on Collective2, a bit pricey but if you have enough capital that's irrelevant. Be very careful when selecting strategies though; potential problems:

- Over-optimized systems that perform great for a short amount of time and then crash

- High use of leverage than will cause disaster during a Black Swan like Swiss CHF event a few years back

- Shorting UVXY or similar, can ruin you next financial crisis if you're not careful

Most of these can be avoided if you know what you're doing, having built algos yourself is actually very helpful when evaluating others' systems from a black box perspective.

I'm considering to write a Collective2 "brokerage" to Lean so one could sell signals on C2, but I haven't looked into how viable it is yet.

1

Very interesting please keep us posted of any future projects. Thx

0

Hi Petter, is there a way on Collective2 to see out-of-sample performance for these strats?

0

Hi Petter, reading further it looks like although the label returns "hypothetical" they are actually generated by live signals from the strats. Am I understanding that correctly?

 

0

Indeed, for C2 it's actually only forward testing and lacks backtesting (unless the system developer provides you with a backtest), which is a significant reason to be careful.

0

To clarify, "forward testing" is same thing as live there. Results are hypothethical because you will have additional slippage - in my case slippage is around 20%...

Anyway to sum it up, advantages of QC over C2 and the reason I'm trying to replace my trading with my own algos on QC:

- To have access to and control backtests.

- Create a better algo than anything for sale (that's always the goal, isn't it).

- QC is less expensive but not really the dealbreaker here, since writing own algo can take a lot of time = money.

0

We also try to provide a third party way of verifying backtests integrity; verified live trading and open source the whole engine so you can run the algorithms on your own stack at home.

We would say we're serving a different layer than C2; and you could happily connect LEAN + C2 to make the best of both worlds.

0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


Yes Jared we were thinking exacty that. Doesn;t look like C2 support IB for brokerage tie-in so were thinking of possibly sending signals via API from QC to C2 and trying to sell our strat w/out revealing nuts and bolts to supplement our returns. Any reason we would have an issue pinging their API from QC?

0

QC itself needs to have libraries white listed, however you can definitely use external libraries on your own in Lean. However, one could contribute the brokerage interface implementation to the Lean Github project so they can merge it with master (or whatever branch of Lean QC runs) and then QC can officially support it.

Feel we derailed the original topic by now, should maybe have switch to a different thread. :)

0

Edit: Actually C2 has a REST interface as well, that you should be able to access simply by running a QC paper brokerage.

0

you can read this book..

 

Machine Trading: Deploying Computer Algorithms to Conquer the Markets

 

0

Update Backtest





0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


Loading...

This discussion is closed