What is algorithmic trading?
- William Burger

- Feb 13
- 5 min read
To many people, algorithmic trading is a black box of complicated computer programs with hundreds or thousands of lines of code powered by AI and Machine Learning operating in milliseconds to fleece the average trader before he knows what hit him. They imagine Taylor Mason leading a team of engineers working for months on a single algorithm that will smash the S&P 500 with win rates over 90%.
In some cases, like Renaissance Technologies, which focuses on statistical and mathematical models to capture arbitrage and mean reversion opportunities, this is partially true.
But in most cases, Commodity Trading Advisors (CTAs) employ relatively simple algorithms that have less than 25 lines of code and win rates of less than 50%. In fact, the most profitable algorithm in my personal portfolio last year had 19 lines of code with a win rate of 44%.
Simple algorithms are generally based on measurable technical or fundamental data points. The algorithms are simply rules based on these discrete data points.
The mere mention of technical analysis may produce a gag reflex for some investors. Sometimes technical analysis can be associated with YouTube trader bros who have unlocked the holy grail of price patterns that pave the technicolor path to the pot of gold. If it sounds like snake oil, that is because it is.
But there are two distinct factions of technical analysis. The first is the qualitative technical analysis that may precipitate feelings of skepticism and sometimes nausea. These subjective strategies would be things like:
Trendlines
Price patterns with unique names
Head and shoulders
Pennants
Flags
Wedges
Triangles
Cup and handle
Candlesticks with even more unique names
Hammer
Doji
Evening star
Dragonfly
Morning star
Fibonacci
Retracements based on the Fibonacci sequence
Elliot wave
Life cycle of a trend
Wycoff
Market cycles of supply and demand
All of the above strategies are open to interpretation and can have multiple meanings depending not only on the perspective of the trader, but the timeframe selected for price data. All of these methodologies are also highly dependent on the visual representation of price on a chart.
What this means is that all of the above strategies are difficult to automate within a string of code. Because they are difficult to code, they are almost impossible to backtest. Because they are impossible to backtest, it is impossible to prove if the strategies work.
Because of this, these strategies are primarily used by discretionary traders, who would represent a minority of the CTA community. Discretionary traders manually place all of their trades. In the CTA community, discretionary traders tend to be longer term traders who place their trades based on fundamental data like weather, crop reports, market participant positioning and geopolitical conditions. It would be highly unlikely to find a CTA who traded on qualitative technical analysis.
On the other hand, there is a quantitative arm of technical analysis and this is primarily what drives the algorithms in use at most CTA firms. These methodologies are mathematically based and therefore can be used in rule based algorithms that can be automated. Automated trades are executed by the algorithm and do not require human intervention. Because they are mathematically based, it is possible to backtest the strategies to get an idea of how they should perform. Backtesting is a topic that deserves its own article.
Quantitative algorithms fall into three basic categories:
Trend Following
Mean Reversion
Momentum
CTAs in general are considered to be trend traders. This simply means that trades are placed following the prevailing price direction. This often means that long trades are placed at the recent highs and short trades are placed at the recent lows.
Mean reversion strategies are considered to be counter trend and look to place counter trend trades at relative extreme highs and lows with the theory that price will revert to the mean.
Momentum strategies are somewhere in between. Momentum strategies enter when price is at a relative extreme, but has shown signs of reversal to the opposite direction.
Trend Following algorithms
Many small losses (low win rate)
Few large winners
Gains on the large winning trades offset the small losing trades
Mean Reversion algorithms
Many small winners (high win rate)
Few large losers
Large losing trades can easily negate profits from previous winning trades
Momentum algorithms
Win rates between 40-60%
Gains on winning trades generally larger than losses on losing trades
Each commodity market has its own personality. It is important to match the trading strategy with the dynamics of each commodity market. For example, a trend following breakout strategy might work great in the gold market, but will get slaughtered in the live cattle market. The days of being able to apply the same strategy across a multitude of markets have been over for some time now.
In trading, survival is the name of the game. In order to survive, a trader must limit losses. Limiting losses allows a trader to live to trade another day. Survival is more important than even consistency. Because of this, many CTAs employ trend following algorithms.
Mean reversion algorithms are initially easier to follow because of the high win rate. But if a mean reverting market suddenly changes into a breakout (or trend following) market, the algorithm will be stuck on the wrong side of the trade and can easily blow out an account. Cocoa in 2022 and silver in 2025 are good examples of markets where mean reverting strategies worked really well until they didn’t.
Equity curve of mean reversion strategy in Silver:

Silver price history:

The way to combat this kind of algorithmic failure is to construct a portfolio of non-correlated algorithms across a number of non-correlated commodity markets. While this topic deserves a post of its own, the basic theory is that the performance of the general portfolio will be able to absorb the failure of one algorithm without blowing out the entire portfolio.
While algorithmic trading strategies are largely based on technical analysis, they can also be based on fundamental data. These algorithms tend to be longer timeframe trades that may span months if not years. Examples of quantitative fundamental data would be Commitment of Traders data and WASDE crop reports. Intermarket relationships can also be used in algorithms such as the price differential between Chicago wheat and Kansas City wheat or live cattle and feeder cattle. Typically these types of strategies are employed by traders with large capital reserves who can absorb initial temporary moves against their positions.
Hopefully this pulls back the curtain on algorithmic trading and how it can be less complex or intimidating for the average investor. The primary advantage of algorithmic trading is that it removes the emotion or uncertainty associated with discretionary trading. Algorithmic trading is akin to the house advantage in a casino. The goal is not to win every bet, but over the long run for the wins to out earn the losses.



