Indicator Lab · STC · Momentum
Schaff Trend Cycle
Processes MACD with stochastic range normalization and additional smoothing.
BTCUSDC · 1h · latest 30 complete days · shared snapshot · no account required
How does repeatedly normalized MACD move within its local ranges?
Processes MACD with stochastic range normalization and additional smoothing.
One dataset, the same parameters and the same candle for application and explanation.
BTCUSDC · confirmed hourly candles
Snapshot retrieved: 11 Oct 2026, 15:52 UTC · stored snapshot · background refresh scheduled · age when opened: 3,137.5 min
11 Sept 2026, 15:00 — 11 Oct 2026, 15:00 UTC · 720 evaluation candles · 3000 earlier candles for warm-up only. Your opened snapshot stays fixed. A visit can refresh a stale cache in the background for later visitors; fetching fresh is not a tick stream.
Parameters and precise application
Number of confirmed hourly candles. Warm-up history stays fixed; only this parameter changes.
Number of confirmed hourly candles. Warm-up history stays fixed; only this parameter changes.
Number of confirmed hourly candles. Warm-up history stays fixed; only this parameter changes.
Explicit formula parameter of the calculation convention described below.
Directional rule · long or cash
BUY on re-entry from ≤25 to >25; SELL from ≥75 to <75. Confirmed closes only; cash start, no shorts/pyramiding. Fills no earlier than the next open with fees and slippage. Thresholds are analysis conventions, not optimized recommendations.
Shared capital and cost model
Includes the buy fee; the remainder stays in cash.
One adverse markup/markdown. Do not add spread a second time.
1 = next open. No retroactive trade at the signal close.
Preparing the calculation module. The shared market snapshot is already available.
Calculation and interpretation of the same candle
Threshold changes describe the relative position of transformed MACD, not directly a price probability.
Two stochastic/filter stages of EMA_fast−EMA_slow
Doug Schaff range>0 normalization includes negative MACD; zero-span stages retain their previous fraction. Corrects pandas-ta minimum>0 and zero-span reset bugs. SMA-seeded EMAs; each stochastic stage requires a full cycle of valid inputs. Fractions/filters start at zero only when that stage becomes valid; recursion rounded to 8 decimals. Default MACD/first filter/STC start at zero-based indices 49/58/67; unavailable warmup observations remain null.
Saturation at scale limits can persist; repeated transformation produces dependent values and initialization effects.
Checked sources and reproducibility
- Doug Schaff · Releasing the Code to the Schaff Trend Cycle · 2008, S.15
Original code: double stochastic uses a positive high-low range; negative MACD values are allowed. Its performance assertions are not adopted. · checked 2026-10-11
- pandas-ta 0.4.71b0 · pandas_ta/momentum/stc.py
Verified original file from the versioned library; the implemented convention and deliberate differences accompany the formula. · checked 2026-10-11
- The Probability of Backtest Overfitting
Why selection across many historical trials can produce misleading results. This tool does not estimate PBO or claim out-of-sample profitability. · checked 2026-10-11
Data source, versions and hash
- Market data source
- https://data-api.binance.vision/api/v3/klines?symbol=BTCUSDC&interval=1h&startTime=1778338800000&endTime=1791730799999
- Specification
- indicator-library-1.0.0
- Execution model
- signal-simulation-1.0.0
- Data hash
- 42ac75e03e017bcac023d319dabb0928e0562fda0e51f4bfa5549ac50e3e8be4
- Disclosed candles including warm-up
- 3720
The sources support definitions and methodological limits. They do not establish profit for this specific BTCUSDC rule. This analysis is descriptive; parameter trials on the same history are not independent out-of-sample evidence. Parity with a deployed unCoded engine is not claimed.