Time is also relative for markets

The use of moving averages that take time in the form of days, hours, minutes and other time frames as a unit, is an arbitrary construction that can also have risks. Is there another way to calculate moving averages without having to depend on the passage of time? This article will explain an original and more effective way.

The time in our lives

It is a known fact that traders are at risk by not considering that the day we started trading a model can have a significant impact on the final results.

In this article, we will see that the use of moving averages taking “days” as the time unit is an arbitrary construction that can also have risks.

The alarm sounds, you get up, go to the kitchen and have breakfast looking at the coffee with your eyes still lost. That look that does not lose until it reaches the shower and stays a few minutes underwater. Does it sound to you? It is usually the daily routine of millions of people. A routine based on a time system, as it is repeated every 24 hours, due to the relationship we have with sunlight as a species.

The truth is that light does not last every day the same, and the duration of days and nights varies during the year. However, we wake up every day at the same time, unless we fall asleep. The same thing happens with the markets, each session lasts the same and there are few changes.

So predictable we are sometimes that we program the systems in Japanese candles of 5 minutes, 10 minutes or 1 hour. This leads to much more accumulation of orders in the “o’clock” hours because everyone is operating there. The most expert traders know it and use different candles (7 minutes, 13, or any other of this style).

And is that time is an arbitrary variable, and when we calculate moving averages over time, we are giving equal importance to the days when the market did not move, than to those that moved a lot. And that can lead to us making decisions too late and having little reaction capacity.

We are so predictable sometimes that we program our trading systems with japanese candlesticks of 5 minutes, 10 minutes or 1 hour. This leads to an increase in the orders accumulation in the “o’clock” hours because everyone is trading there. The most expert traders know this and use different candlesticks periods (7 minutes, 13, or any other of this style).

Time is an arbitrary variable, and when we calculate moving averages over time, we are giving equal importance to the days in which the market did not move and the periods in which the market moved a lot. And this can cause the trader to make decisions too late and have little reaction capacity.

It is not the same thing that for 10 days it rains 1 every 2 days, or it rains only the last 5 days in a row. Yes, the average is the same, it has rained half of the days. But in a second way, there are more chances that the city’s drainage system will collapse. In life, there are periods where there is a perceptible calm, nothing special happens, and the days pass calmly. While other days are frantic, overwhelming and everything changes very fast and it is difficult to react.

The time in the markets

In the markets, we also find periods where nothing happens and periods with very high volatilities. In addition, these environmental changes are usually abrupt. That is why the big falls are associated with the volatility spikes.

In addition, the movements do not have the same strength. The ups and downs, do not even have the same times, nor the same rhythms. The descents tend to be faster and with more volatile movements than the upward movements.

Therefore, the widespread use of moving averages with days as time units may tend to underweight or overweight the different periods of the market, giving every day the same relevance, regardless of whether the price has moved a little or a lot

In fact, that is the big problem of simple moving averages, and that is why we try to mix and match moving averages from different periods. In many periods, long moving averages take a long time to react compared to short moving averages, while in others, short moving averages provide too much noise and false signals.

Looking for market rhythms

Taking the idea of New Found Research, we can see how the market movement is not a constant flow, finding periods where it moves much more than in others. To see the flow, in the following price chart we see the cumulative variance of returns for the SP&500.

Here you can clearly see how there are periods with movements much larger than others. From New Found Research they posed the following question: is one day a relevant unit of information?

If we want to use the moving averages as a mechanism to be able to follow the trends, these averages must adapt to price trends. And for that, it is essential to be able to follow the changes in the market.

We are going to propose a moving average in which each period is a set of days in which the market has moved 2.5% (in absolute value) in an accumulated way. As long as the movements are small, it will not count as a period until the total accumulated move is 2.5%. On the other hand, each day that moves more than 2.5% will count as a period by itself.

In this way, each period contains at least an accumulated movement of 2.5%. The price may not have moved at all, but in that period, accumulated movements have been 2.5%.

Because the number of periods of accumulated movement is less than the number of days, to make equivalent the signals of the moving averages, we will use a moving average of 200 days vs a moving average of 100 periods per accumulated movement.

They are two really similar moving averages, especially in quiet moments, but in large falls the cumulative moving average is more precisely adapted to the trend.

But does this modification work?

To see if this way of studying market movements makes sense, we are going to build the classic model of crossing moving averages and see the results. In this case, the system will be used to trade in the SP&500, so that when the price is above the corresponding moving average, a buy position will be opened, and when a crossing occurs in the opposite direction, the position is closed.

 

 

In the previous images, we see that the results are very similar, but the fact of using moving averages with periods of cumulative movement improves the final result and the drawdowns recovery periods are reduced. However, these small long-term differences can have a very significant impact on the final results.

Conclusions

“Information does not flow into the market at a constant rate. While time may be a convenient measure, it may actually cause us to sample too frequently in some market environments and not frequently enough in others.”

It is true that it may seem overoptimization. Why use a cumulative movement amount of 2.5% for periods?

It is true that it is still another arbitrary variable that you are considering. But it is no more arbitrary than separating the days in periods of market movement of X hours. Not even all markets open the same hours. And yet, moving averages per day is used for all assets and markets alike.

On the other hand, I am not saying that daily averages do not work, much less. I just try to reveal all those risks that we do not know, and all the things that we consider valid because we have never questioned them.

Knowing the risks we have when trading and designing a model to try to avoid those risks is often much more important than trying to have the best system, with less drawdown and higher performance.

That is why with this article I would like to help you reflect on this: there are other ways of doing things, different from those established. I hope I have provided a useful tool for all of us who use moving averages to follow the market.


 

Leave a Comment