- Implemented SgmaIndicator class in C# with properties for Period, Degree, and Source. - Added unit tests for SgmaIndicator covering constructor defaults, initialization, and various update scenarios. - Created a new Quantower adapter for the SGMA indicator, including input parameters and line series setup. - Removed legacy SGMA implementation and tests to streamline the codebase. - Updated project files to include new indicator and tests in the build process. - Generated a missing indicators report and outlined a plan for oscillator documentation rewrite.
22 KiB
Indicator Catalog
QuanTAlib provides technical indicators organized into mathematical families. Understanding these families helps choose the right tool for the analytical problem at hand. Selecting an indicator without understanding its category leads to confusion at best, losses at worst.
Category Reference
| Category | What It Measures | Representative Indicators | When to Reach for It |
|---|---|---|---|
| Trends (FIR) | Trend direction via finite impulse response filters | SMA, WMA, ALMA, HMA, LSMA | Trend identification with predictable lag and finite memory. Output depends only on a fixed window of past prices. |
| Trends (IIR) | Trend direction via infinite impulse response filters | EMA, DEMA, TEMA, JMA, KAMA, MAMA | Trend identification with recursive calculation and theoretically infinite memory. More responsive per unit of smoothness. |
| Filters | Signal processing filters for noise reduction | Bessel, Butterworth, Super Smoother | Removing noise while preserving trend structure. Designed by engineers, borrowed by traders. |
| Oscillators | Cyclical movement around a baseline | RSI, MACD, AO, UltOsc | Identifying overbought/oversold conditions and potential reversals. Bounded indicators that oscillate. |
| Dynamics | Trend strength and structural changes | ADX, Aroon, SuperTrend, Chop | Determining market regime (trending vs ranging) and measuring trend conviction. |
| Momentum | Speed and magnitude of price changes | Momentum, ROC, Velocity | Measuring acceleration or deceleration in price. First derivative territory. |
| Volatility | Size and variability of price movements | ATR, StdDev, Bollinger Bands | Position sizing, stop-loss placement, regime identification. How much prices move matters as much as direction. |
| Volume | Trading activity and price-volume relationships | OBV, VWAP, A/D | Confirming price movements with participation. Volume validates or contradicts price action. |
| Channels | Price boundaries and range definitions | Donchian, Keltner, Bollinger | Breakout strategies and range-bound trading. Defining "normal" so abnormal becomes visible. |
| Statistics | Mathematical relationships between price series | Correlation, Covariance, Beta, Z-Score | Portfolio analysis, pairs trading, statistical arbitrage. Quantitative analysis beyond single instruments. |
| Numerics | Mathematical transformations and signal processing | Convolution, Integration, Differentiation | Custom indicator development and advanced signal processing. Building blocks for novel indicators. |
| Errors | Measurement accuracy and model fit quality | MAE, RMSE, Residuals, R² | Model validation and forecast assessment. Quantifying wrongness before production quantifies losses. |
| Forecasts | Future price prediction and projection | Linear regression extrapolation, adaptive prediction | Projecting price based on historical patterns. Predictions that invite humility. |
| Cycles | Periodic patterns and dominant frequencies | Hilbert Transform, Dominant Cycle | Identifying cyclical market behavior. Markets exhibit cycles; detecting them reliably remains hard. |
| Reversals | Turning points and stop levels | Pivot Points, PSAR, Chande Kroll Stop | Identifying potential trend reversals, computing adaptive stops, and defining support/resistance. |
Selection by Experience Level
Beginning technical analysis? Start with Trends (FIR/IIR), Volatility, and Oscillators. SMA teaches moving average fundamentals. ATR teaches volatility measurement. RSI teaches bounded oscillators. These provide foundation for everything else.
Building a trading strategy? Add Volume for confirmation, Channels for breakouts, Dynamics for regime detection. Volume validates price moves. Channels define breakout boundaries. ADX distinguishes trending from ranging markets.
Quantitative development? Filters, Statistics, Numerics, and Errors provide tools for signal processing, model validation, and custom indicator construction. Butterworth filters for noise reduction. Correlation for pairs trading. Error metrics for model selection.
Implemented Indicators
Trends (FIR)
Finite Impulse Response filters. Output depends only on a fixed window of inputs. Always stable. Predictable lag characteristics.
| Indicator | Full Name | Notes |
|---|---|---|
| ALMA | Arnaud Legoux MA | Gaussian-weighted with offset parameter |
| BLMA | Blackman Window MA | Spectral leakage reduction |
| BWMA | Bessel-Weighted MA | Linear phase response |
| CONV | Convolution MA | Arbitrary kernel support |
| DWMA | Double Weighted MA | WMA applied twice |
| GWMA | Gaussian Weighted MA | Normal distribution weights |
| HAMMA | Hamming Weighted MA | Spectral analysis window |
| HANMA | Hanning Weighted MA | Cosine-based window |
| HMA | Hull MA | Reduced lag via WMA differencing |
| HWMA | Holt-Winters MA | Triple exponential smoothing |
| LSMA | Least Squares MA | Linear regression endpoint |
| PWMA | Pascal Weighted MA | Binomial coefficient weights |
| SGMA | Savitzky-Golay MA | Polynomial smoothing |
| SINEMA | Sine-Weighted MA | Sinusoidal weight distribution |
| SMA | Simple MA | Equal weights, the baseline |
| TRIMA | Triangular MA | Double-smoothed SMA |
| WMA | Weighted MA | Linear weight decay |
Trends (IIR)
Infinite Impulse Response filters. Output depends on current input and past outputs. Recursive structure. More responsive but requires stability analysis.
| Indicator | Full Name | Notes |
|---|---|---|
| DEMA | Double Exponential MA | EMA of EMA with lag compensation |
| DSMA | Deviation-Scaled MA | Volatility-adaptive smoothing |
| EMA | Exponential MA | The fundamental IIR filter |
| FRAMA | Fractal Adaptive MA | Dimension-based adaptation |
| HEMA | Hull Exponential MA | Hull concept with EMA |
| HTIT | Hilbert Instantaneous Trend | Dominant cycle extraction |
| JMA | Jurik MA | Adaptive, low-lag, proprietary algorithm |
| KAMA | Kaufman Adaptive MA | Efficiency ratio adaptation |
| MAMA | MESA Adaptive MA | Homodyne discriminator based |
| MMA | Modified MA | Smoothed EMA variant |
| MGDI | McGinley Dynamic | Market-speed tracking |
| QEMA | Quad Exponential MA | Four-stage exponential |
| RGMA | Recursive Gaussian MA | Gaussian approximation |
| REMA | Regularized Exponential MA | Regularization for stability |
| RMA | WildeR MA | Wilder's smoothing (1/n decay) |
| T3 | Tillson T3 MA | Six-stage DEMA variant |
| TEMA | Triple Exponential MA | Three-stage lag reduction |
| VAMA | Volatility Adjusted MA | ATR-based adaptation |
| VIDYA | Variable Index Dynamic | CMO-based adaptation |
| YZVAMA | Yang-Zhang Vol Adjusted | YZ volatility adaptation |
| ZLEMA | Zero-Lag Exponential MA | Momentum-compensated EMA |
Filters
Signal processing filters adapted for financial time series. Designed to separate signal from noise with controlled frequency response.
| Indicator | Full Name | Notes |
|---|---|---|
| BESSEL | Bessel Filter | Maximally flat group delay |
| BILATERAL | Bilateral Filter | Edge-preserving smoothing |
| BPF | BandPass Filter | Frequency band isolation |
| BUTTER | Butterworth Filter | Maximally flat passband |
| CHEBY1 | Chebyshev Type I | Steeper rolloff with ripple |
| SSF | Super Smooth Filter | Ehlers two-pole design |
| USF | Ultimate Smoother | Ehlers high-fidelity filter |
Oscillators
Bounded indicators that oscillate around a centerline or between fixed extremes. Useful for mean-reversion signals.
| Indicator | Full Name | Notes |
|---|---|---|
| AC | Acceleration Oscillator | AO acceleration (2nd derivative) |
| AO | Awesome Oscillator | Midpoint momentum |
| APO | Absolute Price Oscillator | EMA difference |
| BBB | Bollinger %B | Position within Bollinger Bands |
| BBS | Bollinger Band Squeeze | BB inside KC squeeze detection |
| CFO | Chande Forecast Oscillator | Forecast error percentage |
| DPO | Detrended Price Oscillator | Displaced SMA trend removal |
| FISHER | Fisher Transform | Gaussian-normalized price reversal |
| INERTIA | Inertia | Linear regression residual |
| KDJ | KDJ Indicator | Enhanced Stochastic (J = 3K − 2D) |
| PGO | Pretty Good Oscillator | ATR-normalized SMA displacement |
| SMI | Stochastic Momentum Index | Distance from range midpoint (K/D lines) |
| STOCH | Stochastic Oscillator | Close within N-period H/L range (%K/%D) |
| STOCHF | Stochastic Fast | Unsmoothed Stochastic (%K/%D, SMA smoothing only) |
| STOCHRSI | Stochastic RSI | Stochastic applied to RSI (%K/%D) |
| TRIX | Triple Exponential Average | ROC of triple-smoothed EMA |
| MACD | MACD | EMA crossover system |
| RSI | Relative Strength Index | Bounded 0-100 momentum |
| ULTOSC | Ultimate Oscillator | Multi-timeframe weighted |
| TTM_WAVE | TTM Wave | Fibonacci-period MACD composite (A/B/C waves) |
| WILLR | Williams %R | Inverse Stochastic (-100 to 0) |
Dynamics
Indicators measuring trend strength, regime, and directional movement quality.
| Indicator | Full Name | Notes |
|---|---|---|
| ADX | Average Directional Index | Trend strength 0-100 |
| ADXR | ADX Rating | Smoothed ADX |
| AMAT | Archer MA Trends | MA-based trend detection |
| AROON | Aroon | High/low recency |
| AROONOSC | Aroon Oscillator | Aroon Up minus Down |
| DMX | Jurik DMX | Enhanced directional movement |
| IMPULSE | Elder Impulse System | EMA + MACD-H trend/momentum fusion |
| SUPER | SuperTrend | ATR-based trend bands |
Momentum
Rate of change and velocity measurements. First derivatives of price.
| Indicator | Full Name | Notes |
|---|---|---|
| BOP | Balance of Power | Close position in range |
| CFB | Composite Fractal Behavior | Jurik fractal momentum |
| ROC | Rate of Change | Absolute price change over N periods |
| ROCP | Rate of Change Percentage | Percentage price change over N periods |
| ROCR | Rate of Change Ratio | Price ratio over N periods |
| PRS | Price Relative Strength | Dual-input ratio comparison |
| RSX | Jurik RSX | Smoothed RSI variant |
| TSI | True Strength Index | Double-smoothed momentum oscillator |
| VEL | Jurik Velocity | Adaptive velocity |
Volatility
Measures of price variability and range. Essential for position sizing and stop placement.
| Indicator | Full Name | Notes |
|---|---|---|
| ADR | Average Daily Range | Simple range averaging |
| ATR | Average True Range | Gap-adjusted range |
| ATRP | ATR Percent | Normalized ATR |
Volume
Price-volume relationships and accumulation/distribution measurements.
| Indicator | Full Name | Notes |
|---|---|---|
| ADL | Accumulation/Distribution | Volume-weighted close position |
| ADOSC | Chaikin A/D Oscillator | ADL momentum |
| TWAP | Time Weighted Average Price | Time-equal-weighted price average |
| VA | Volume Accumulation | Cumulative volume by close position |
| VF | Volume Force | EMA-smoothed price-volume force |
| VO | Volume Oscillator | Short vs long volume MA difference |
| VROC | Volume Rate of Change | Volume change over lookback period |
Channels
Price envelope and boundary indicators for breakout and mean-reversion strategies.
| Indicator | Full Name | Notes |
|---|---|---|
| ABBER | Aberration Bands | Statistical deviation bands |
| ACCBANDS | Acceleration Bands | Volatility-adjusted envelope |
| DCHANNEL | Donchian Channels | Highest-high / lowest-low breakout bands |
| DECAYCHANNEL | Decay Min-Max Channel | Exponential decay toward midpoint |
| FCB | Fractal Chaos Bands | Williams fractal-based support/resistance |
| JBANDS | Jurik Adaptive Envelope Bands | Snap-to-extreme, decay-to-price volatility bands |
| KCHANNEL | Keltner Channel | EMA with ATR bands; smoother than Bollinger |
| MAENV | Moving Average Envelope | Fixed percentage bands around selectable MA type |
| MMCHANNEL | Min-Max Channel | Rolling highest high / lowest low; O(1) monotonic deques |
| PCHANNEL | Price Channel | Highest high / lowest low; identical to Donchian |
| REGCHANNEL | Linear Regression Channel | Linear regression line with standard deviation bands |
| SDCHANNEL | Standard Deviation Channel | Moving average with standard deviation bands |
| STARCHANNEL | Stoller Average Range Channel | SMA with ATR bands; similar to Keltner but uses SMA |
Statistics
Mathematical and statistical computations on price series.
| Indicator | Full Name | Notes |
|---|---|---|
| BIAS | Bias | Percentage deviation from SMA |
| COINTEGRATION | Cointegration | Engle-Granger two-step method with ADF test |
| CORRELATION | Pearson Correlation | Linear relationship between two series [-1, +1] |
| CMA | Cumulative Moving Average | Expanding window average |
| COVARIANCE | Covariance | Joint variability |
| ENTROPY | Shannon Entropy | Normalized information entropy via histogram binning |
| GEOMEAN | Geometric Mean | Rolling geometric mean via log-sum approach |
| GRANGER | Granger Causality | F-statistic testing if X helps predict Y |
| LINREG | Linear Regression | Best-fit line |
| MEDIAN | Rolling Median | 50th percentile |
| SKEW | Skewness | Distribution asymmetry |
| STDDEV | Standard Deviation | Dispersion measure |
| SUM | Rolling Sum | Windowed sum |
| VARIANCE | Variance | Squared deviation |
Forecasts
Predictive indicators and extrapolation methods.
| Indicator | Full Name | Notes |
|---|---|---|
| AFIRMA | Adaptive FIR MA | Predictive FIR filter |
Cycles
Periodic pattern detection and dominant frequency extraction. Markets exhibit cycles; detecting them reliably remains challenging.
| Indicator | Full Name | Notes |
|---|---|---|
| HT_SINE | Hilbert Transform SineWave | Dominant cycle phase with 45° lead signal |
| SSFDSP | SSF Detrended Synthetic Price | Dual Super Smoother Filter oscillator |
Numerics
Mathematical transformations and derivative indicators. Building blocks for analysis.
| Indicator | Full Name | Notes |
|---|---|---|
| ACCEL | Acceleration (2nd Derivative) | Change in slope; momentum |
| CHANGE | Percentage Change | Relative price movement (current - past) / past |
| EXPTRANS | Exponential Transform | e^x transform for log-space reversal |
| HIGHEST | Rolling Maximum | O(1) amortized via monotonic deque |
| JERK | Jerk (3rd Derivative) | Change in acceleration |
| LINEARTRANS | Linear Transform | y = ax + b scaling transformation |
| LOGTRANS | Logarithmic Transform | Natural log for percentage analysis |
| LOWEST | Rolling Minimum | O(1) amortized via monotonic deque |
| MIDPOINT | Rolling Midpoint | (Highest + Lowest) / 2 |
| NORMALIZE | Min-Max Normalization | Scale to [0,1] via rolling min/max |
| RELU | Rectified Linear Unit | max(0, x); activation function |
| SIGMOID | Logistic Function | 1/(1+e^-x); bounded [0,1] transform |
| SLOPE | Slope (1st Derivative) | Rate of change; velocity |
| SQRTTRANS | Square Root Transform | √x; variance to standard deviation conversion |
Errors
Error metrics and loss functions for model evaluation, forecast assessment, and strategy validation. Quantifying wrongness before production quantifies losses.
| Indicator | Full Name | Notes |
|---|---|---|
| WRMSE | Weighted Root Mean Squared Error | Custom observation weighting for error emphasis |
Reversals
Reversal indicators identify potential turning points, compute adaptive stop levels, and define support/resistance zones. Where trend indicators tell you what is happening, reversal indicators warn you when it might stop.
| Indicator | Full Name | Notes |
|---|---|---|
| CHANDELIER | Chandelier Exit | ATR-based trailing stops from HH/LL; dual ExitLong/ExitShort |
| CKSTOP | Chande Kroll Stop | ATR-based adaptive trailing stops; dual StopLong/StopShort levels |