April 30, 2020

Often, we ignore the very structure we have given our automated stock trading strategies. We code them to behave in a certain way for as long as they will be executed. For example, in most Python programs showcased on Quantopian, we can find variants of the following line of code:

schedule_function(rebalance, date_rules.month_start(), time_rules.market_open())

It instructs the program to rebalance its portfolio the first trading day of each month as the market opens. That single line of code will execute, on its preset schedule, no matter what. Other programming languages would use a different syntax and wording to accomplish the same task.

This rebalancing gives a structure to the program. From the payoff matrix equation, we have: Σ (H ∙ ΔP) = n ∙ xavg = \$X where n is the number of trades, xavg the average net profit per trade and \$X is the total generated profit.

Due to the scheduling, we can determine (estimate) how many trades our trading strategy will execute over time simply by knowing how many stocks we are going to trade and what might be the turnover rate.

A monthly scheduling, evidently, will occur 12 times a year for as long as the trading strategy is applied. An estimate for a 400-stock portfolio rebalanced on a monthly basis with a 40% turnover rate would give an averaged 160 trades executed every month (400*0.40 = 160).

The Portfolio Rebalancing

(click to enlarge)

The above table shows the number of trades to be executed based on the number of stocks in the portfolio, the rebalancing frequency (daily, weekly, monthly, or yearly), and a 40% turnover rate over a period of 30 years. You could easily rebuild this table to test other turnover rates or number of years.

My first question after building that table was: where is the money?

The table can tell me how many trades I might do over the next 30 years, and yet, it says absolutely nothing on how much I might win or lose. As if it is just a part of the structure of the program.

I am not saying that the trades will not happen, they will, due to the scheduling function. It is just that it does not say how much will come out of it, other than trades will be executed. It predetermines what will happen on the trading side of things and not how much money will be made or lost.

In a recent 400-stock simulation over a 17.16-year trading interval with a turnover in the vicinity of 0.40, the above table would have given an estimate of 142,771 trades to be executed on a weekly basis over the period. The simulation came in at 143,610 which is less than 0.6% away from the estimate.

That you know the number of trades that your trading strategy will do, or might do, over the years, does not tell you how much you will make, but it does give you the profit multiplier since, from the payoff matrix equation, you do have two numbers to worry about, one of which is no longer a strict unknown. For example: Σ (H ∙ ΔP) = E[n ≈ 142,771] ∙ xavg = \$X.

How much are you going to extract now that you know how many trades your trading strategy is estimated to do over its trading interval and rebalancing frequency? What average profit per trade xavg can you get? How, and why?

It will be your ability to extract xavg that will matter here. You do know, even before you start, that every dollar you can add to xavg will be multiplied by E[n] (142,771 in the 17.16-year scenario). If the rebalance had been done on a monthly basis, the multiplier would have been around 32,947 requiring a higher profit margin per trade to achieve the same results.

If you rebalance on a monthly basis, you can only get monthly price changes, the same if you do it on a yearly basis. It is not the market that is dictating the trade mechanics, it is you, by having prescheduled the trading activity.

And the question remains: where is the money?

Related Recent Articles:

Reverse-Engineer For More Profits

Portfolio Doubling Times II

Durability And Scalability