Skip to content

Catching the momentum effect in crypto with machine learning

  • Article
  • Finance

Read the announcement on Facebook

Cryptocurrency markets are among the most volatile markets there are. Most quantitative trading systems that try to profit from the momentum effect, the tendency of a price that has moved sharply to keep moving in the same direction for a while, are built from rules written by people. Those rules do not adapt well when conditions change quickly, which is the normal state of a crypto market. A 2022 paper by Gian Pietro Bellocca, Giuseppe Attanasio, Luca Cagliero, and Jacopo Fior asks whether machine learning can detect the momentum effect directly from market data instead.

Approach

The authors frame the problem as classification. They collected a long run of historical prices for three well-known coins, Bitcoin (BTC), Ethereum (ETH), and Litecoin (LTC). Each day in the dataset was labeled with an indicator function that marks whether the market overreacted that day, since overreaction is what produces the momentum the strategy wants to ride. A classifier was then trained to predict, for the next trading day, whether an overreaction condition will be present and in which direction it will move. The main drawback of the heuristic method the paper compares against is false trading signals, so the target of the machine learning approach is to cut those down.

Findings

The headline result is that the return per trade of the machine learning approach is significantly higher than what the heuristic approach achieves. On Bitcoin, a k-nearest neighbors classifier returned 0.78 percent per trade against 0.06 percent for the heuristic. On Ethereum, k-nearest neighbors returned 1.87 percent per trade against 0.71 percent, and a logistic regression model did better still, with 90 percent of its 30 trades profitable and a total return of 126.23 percent. On Litecoin, a support vector classifier led with 1.75 percent per trade. The models tend to trade less often than the heuristic and to be right more often when they do.

The authors conclude that machine learning is useful for this kind of trading, especially when the historical data contains a large number of overreaction days for the model to learn from.

What they recommend

The heuristic approach is overly reactive and the machine learning approach is comparatively cautious. The authors suggest a hybrid design that combines heuristic rules based on technical analysis with the machine learning classifier, so that each covers for the other’s weakness.

Source: Bellocca, G. P., Attanasio, G., Cagliero, L., and Fior, J. (2022). Leveraging the momentum effect in machine learning-based cryptocurrency trading. Machine Learning with Applications, 8, 100310. doi:10.1016/j.mlwa.2022.100310

Originally shared on Facebook.

Query console

Connected to dssoc. Type \h for the commands this console understands.