OnsetTrend

Description

The Onset Trend strategy is based upon the Onset Trend Detector study, a zero-lag trend analyzing oscillator. This oscillator incorporates two filters, the Super Smoother Filter and the Roofing Filter, both developed by John F. Ehlers. Data derived from these two filters is processed by automatic gain control algorithm and then subjected to the quotient transform. The quotient transform, controlled by the K coefficient, collapses small oscillator values while keeping higher values high.

The strategy uses the oscillator twice, with different values of K coefficient. This ensures more precise trend detection. Suggested values for the coefficient are 0.8 and 0.4, customizable via input parameters. The strategy adds a simulated Buy order when the first oscillator crosses above zero (which corresponds to uptrend detection) and a Sell to close order when the second oscillator crosses below zero (which signifies that the uptrend is over).

Input Parameters

price

Defines the price to which the oscillator is applied.

cutoff length

Defines the minimum cycle length in bars. Cycles with lesser lengths will be considered noise and eliminated.

roof cutoff length

Defines the maximum cycle length in bars. Cycles with greater lengths will be considered spectral dilation and eliminated.

k1

The K coefficient used in quotient transform for the first oscillator.

k2

The K coefficient used in quotient transform for the second oscillator.

Further Reading

1. "The Quotient Transform" by John F. Ehlers. Technical Analysis of Stocks & Commodities, August 2014.

Backtesting is the evaluation of a particular trading strategy using historical data. Results presented are hypothetical, and there is no guarantee that the same strategy implemented today would produce similar results.

Technical analysis is not recommended as a sole means of investment research.

For educational purposes only. Not a recommendation of a specific security or investment strategy.