July 7, 2019

I have absolutely no obligation to post anything on Quantopian forums, it is just like for anyone else. However, if I post something, I stand ready to explain and discuss within my own understanding and IP disclosure limits what a trading strategy does and for what reasons it does it.

This way, anyone could design their own variations on the same themes. It might even help someone design something new. For me, the advantage is that everyone become the designer of their own thing and therefore become responsible for their own stuff. I find that acceptable. For anyone on Quantopian sharing snippets of code, templates, tearsheets, and trading ideas, as I have said before: thanks. Of note, however, not many of those shared things have value. Is it explicit enough?

I think the best way to understand the presented trading strategy is to look back at another one which is based on about the same trade mechanics. Please, read my comments from start to finish in the Robo Advisor thread where the CVXOPT optimizer controlled trading activity. Ignore the charts and other comments. Just follow the linear strategy description given, and at the end, ask the question: how could I, in my own way, reconcile into code what was said? Because that is the question.

Both this strategy and the Robo Advisor thing have different architectures. Yet, both were able to generate in excess of 200,000%+ over 14 and 15 years respectively. All of it, due to their respective trading mechanics.

In both cases, I used a long-term perspective in my strategy design and looked at the strategy's payoff matrix as this big block of data (H∙ΔP) over the entire trading interval. I cannot do anything with the price matrix P, it is recorded history.

However, I can add some elaborate and sophisticated function(s) to control the inventory part of the equation in any which way I want Σ(H∙g(t)∙ΔP). It is entirely at my discretion as to what I want to put into it.

I am a big fan of Mr. Buffett's long-term investment methods which I try to incorporate into my strategies as much as possible. However, on top of this long-term view of the market, I use trading as an additional funding mechanism which enables raising performance by recycling generated profits in new trades, a positive reinvestment feedback loop.

All of it is governed by equations, of which the most important, as described in my latest book is:

Bet Size Equation

with the section: Bet Size Equation Factorshaving the set of control parameters.

Notice that the bet size q_(i, j) ∙ p_(i, j) is not only an exponential time function but is also modulated by these compounding parameters. This way the system remains trade agnostic, scalable, and can compensate, as the portfolio grows, for return degradation due to the Law of diminishing returns. It also gives it its exponential equity curve.

In the strategy's development process, it is at the end that I added protective measures (like during periods of market turmoil or during the financial crisis for instance), and not starting with them. There is more than one way to do about the same thing even if we chose different methods to get there. We could all design variations of those protective measures and they might span more or less the same time intervals. The point is just to have some in, somehow.

Ending with the protective measures, instead of starting with them, enabled to know how far the trading strategy could go. This way, I could see not only how high it could go but also how low it could get if I did not put in the downside protection.

Doing this also justified why it was wiser to put in these protective measures. Adding protective measures at the end also enabled to see how high the strategy could soar in periods where market turmoil was more subdued and where more upward pressure could be applied knowing that the strategy's controlling functions could support it.

In the Robo Advisor trading script, the trading activity is delegated to the CVXOPT optimizer. Some stated that the program, in that case, was over-fitted, even issued disclaimers.

I understand that the optimizer, by definition, has for mathematical function to optimize the stuff it is presented with. But, it is like a black box, where you supply it some data and it gives out its feasible answer, that you like the answer or not.

Therefore, the over-fitting modicum might be hard to accept since the optimizer did not care what it was fed. Neither could you know, in any way, what it would do next: buy, sell, short, hold positions, at what times, what prices, in which stocks, and in what quantities. How can you optimize, or curve-fit, what you cannot see?

How can you over-optimize an optimizer? Does it not do its job the first time around?

Shouldn't there be nothing left to optimize after you optimized?

BTW, should an optimizer over-optimize its job, then it would put in question any trading strategy using one, including all strategies participating in the Quantopian contest, and might even render all those strategies useless.

The optimizer cannot discriminate or single out a specific strategy and declare it bad! Only people do that without seeing the code, without understanding what a strategy is really doing, and without having supporting data of any kind to justify their “opinions”. But, they will give them out anyway.

You can over-fit, if “deliberately”, you are seeking the best parameter values for your trading strategy. But trading decision control was passed on to the optimizer to do whatever it does.

With the current strategy, trading its 25 stocks, the controls are in the program, no trading decision delegation. And yet, you also get interesting results. Here, you control the equations and the degree of trade aggressiveness as demonstrated. Nonetheless, you can still push for higher performance even if you do not use an optimizer.

Two very different trading methods, each adapted to their respective designed objectives and controlled by equations. This is not how people design their trading strategies here on Quantopian. It is what makes my methods different and innovative.

It also shows that there are other ways to design strategies. It does not say that those designs are bad, only that they are different, and in these two illustrated cases, more than just productive, even if I have to say so myself.


Created. July 7, 2019, © Guy R. Fleury. All rights reserved.