Trading the Channel

One of the simplest form of trend trading opens positions when the price crosses its moving average, and closes or reverses them when the price crosses back. In the latest TASC issue, Perry Kaufman suggested an alternative. He is using a linear regression line with an upper and lower band for trend trading. Such a band indicator can be used to trigger long or short positions when the price crosses the upper or lower band, or when it gets close. Continue reading “Trading the Channel”

The Ultimate Strength Index

The RSI (Relative Strength Index) is a popular indicator used in many trading systems for filters or triggers. In TASC 12/2024 John Ehlers proposed a replacement for this indicator. His USI (Ultimate Strength Index) has the advantage of symmetry – the range is -1 to 1 – and, especially important, less lag. So it can trigger trades earlier. Like the RSI, it enhances cycles and trends in the data, which makes it well suited for various sorts of trading systems. Let’s look how to realize it in code. Continue reading “The Ultimate Strength Index”

Ehlers’ Precision Trend Analysis

In TASC 8/24, John Ehlers presented a new algorithm for separating the trend line from a price curve, using spectral analysis functions. Trend lines are only useful for trading when they have little lag, so that trend changes can immediately trigger trade signals. The usual suspects like SMA, WMA, EMA are too laggy for this. Let’s see how good this new algorithm works. The functions below are a 1:1 conversion from Ehlers’ TradeStation code to C. Continue reading “Ehlers’ Precision Trend Analysis”

Ehlers’ Ultimate Smoother

In TASC 3/24, John Ehlers presented several functions for smoothing a price curve without lag, smoothing it even more, and applying a highpass and bandpass filter. No-lag smoothing, highpass, and bandpass filters are already available in the indicator library of the Zorro platform, but not Ehlers’ latest invention, the Ultimate Smoother. It achieves its tremendous smoothing power by subtracting the high frequency components from the price curve, using a highpass filter. Continue reading “Ehlers’ Ultimate Smoother”

The Gap Momentum System

Perry Kaufman, known for his technical indicators bible, presented in TASC 1/24 a trading strategy based on upwards and downwards gaps. For his system, he invented the Gap Momentum Indicator (GAPM). Here I’m publishing the C version of his indicator, and a simple trading system based on it. Continue reading “The Gap Momentum System”

High-Conviction Trading

In the TASC September issue, Alfred Tagher presented a new indicator based on the Commitment Of Traders (COT) report. This report is available on the NASDAQ website. It is released weekly by the Commodities Futures Trading Commission and reflects the activities of various groups of commercial and noncommercial traders. Evaluating this report allows trading systems to automatically follow the “smart money”.
Continue reading “High-Conviction Trading”

Undersampling

All the popular ‘smoothing’ indicators, like SMA or lowpass filters, exchange more lag for more smoothing. In TASC 4/2023, John Ehlers suggested the undersampling of price curves for achieving a better compromise between smoothness and lag. We will check that by applying a Hann filter to the original price curve and to a 5-fold undersampled curve. Continue reading “Undersampling”

Open or Close? Why Not Both?

In his TASC February 2023 article, John Ehlers proposed to use the average of open and close, rather than the close price, for technical indicators. The advantage is a certain amount of noise reduction. On intraday bars the open-close average is similar to an SMA(2). It makes the data a bit smoother, but at cost of additional lag by half a bar. Continue reading “Open or Close? Why Not Both?”

The Linear Regression-Adjusted Exponential Moving Average

There are already uncounted variants of moving averages. Vitali Apirine invented another one in his article in the Stocks&Commodities September issue. The LREMA is an EMA with a variable period derived from the distance of the current price and a linear regression line. This ensures an optimal EMA period at any point – at least in theory. Will this complex EMA variant beat the standard EMA for detecting trend changes? 

Continue reading “The Linear Regression-Adjusted Exponential Moving Average”