Kalman Trailing Stop (KTS)โโ OVERVIEW
The Kalman Trailing Stop (KTS) is an advanced, math-driven trend-following system designed to keep you in winning trades longer while dynamically filtering out market noise.
Instead of relying on static moving averages or basic ATR multipliers, KTS utilizes a 2D Kalman Filter combined with Statistical Digital Signal Processing (DSP) and Williams Market Structure. It adapts to volatility and volume in real-time, effectively distinguishing between genuine trend shifts and temporary liquidity sweeps.
โโ CORE MECHANICS
1. 2D Kalman Adaptive Trailing Stop
At the heart of the indicator is a robust 2D Kalman filter that tracks both price level and velocity.
Volume-Weighted Variance: The trailing stop becomes highly responsive during high-volume pushes (high trust) and flattens out during low-volume consolidation (low trust), preventing premature stop-outs.
Sigmoid Smoothing & Structural Anchoring: Instead of jagged, abrupt jumps, the stop uses sigmoid transitions to smoothly glide to new structural floors/ceilings derived from recent Intermediate-Term Highs and Lows (ITH/ITL).
Slope Confirmation: The trailing stop will only flip its directional bias if the underlying Kalman baseline slope confirms the reversal, neutralizing fake-outs.
2. Statistical Plunger Logic (Liquidity Sweeps)
Markets frequently sweep liquidity beyond technical levels before reversing. The "Plunger" logic mathematically identifies these traps.
Dynamic Sweep Multiplier: By tracking the kurtosis (fat-tail distribution) of price returns, the script dynamically expands its sweep threshold during periods of wild volatility.
Wick Filtering: It detects deep wicks that pierce the Kalman bands and close strongly back within the bar's range, highlighting statistically validated exhaustion points.
3. Algorithmic Pyramiding & Volatility Warnings
Scale-In Detection: KTS monitors volume footprints to identify safe zones to add to your position. It looks for a sequence of volume "dry-up" during a pullback, followed by a volume-backed breakout past recent market structure.
Livermore Ejector Concept: The indicator flags abnormal, massive range expansions that occur against the prevailing trend, acting as an early warning system for sudden momentum shifts.
4. Built-in Risk & Performance Engine
Dynamic Position Sizing: Automatically calculates raw position and pyramid sizes based on your account equity, risk percentage, and maximum leverage.
Live Performance Dashboard: A built-in HUD tracks both the Global and Recent Profit Factor (PF) of the main trend signals, alongside the real-time distance to your trailing stop.
โโ VISUAL GUIDE
Colored Gradient Band: The main Kalman Trailing Stop. Green indicates an active long trend; Red indicates an active short trend.
Large Diamonds (โฆ๏ธ): Main Trend Entries. Triggered when price breaks the Kalman Stop with slope confirmation.
Small Triangles (๐ผ/๐ฝ): Bullish and Bearish Plunger signals. These indicate deep liquidity sweeps and wick rejections at statistical extremes.
Small Crosses (โ): Algorithmic Pyramid signals. Opportunities to scale into the current trend based on volume dry-ups and structural breakouts.
Yellow X-Crosses (โ): Abnormal Reaction Warnings. Signals a massive volatility spike moving against your active position.
โโ SETTINGS
Kalman Trailing Stop Settings
Kalman Responsiveness: Adjusts how quickly the system reacts to price changes (1-100).
Trailing Stop Distance (SD): Sets the baseline width of the trailing stop from the Kalman-smoothed price, measured in standard deviations of the True Range. A higher value (e.g., 3.0) gives the trade more breathing room, while a lower value tightens the stop.
Disclaimer
This script is designed for educational and informational purposes only. Trading involves significant risk. The built-in performance table is an un-optimized raw calculation and should not be used as a guarantee of future system profitability. Indicatore

[GYTS-CE] Kinetic Trend Envelope (adaptive trailing stop)Kinetic Trend Envelope (Community Edition)
๐ธ Part of GoemonYae Trading System (GYTS) ๐ธ
๐ธ --------- INTRODUCTION --------- ๐ธ
๐ฎ What is the Kinetic Trend Envelope?
The Kinetic Trend Envelope (KTE) is an adaptive directional trailing stop in the lineage of SuperTrend, rebuilt around the premise that volatility is kinetic energy . It measures per-bar motion with five academically grounded volatility estimators, then widens the envelope as energy rises and contracts it as motion settles.
In an uptrend, the lower band ratchets higher and never retreats; in a downtrend, the upper band ratchets lower. The direction changes when the active stop is breached, after which the opposite side becomes the new trailing stop.
๐ฎ Why Use This Indicator?
Conventional trailing stops typically combine a price anchor with one symmetric ATR-derived width. The KTE extends that model with:
Asymmetric volatility profiling โ Bullish- and bearish-candle volatility shape the upper and lower bands independently.
Three direction-switch methods โ High/low, close, or a smoothed estimator controls flip sensitivity without moving the band anchor.
Five volatility estimators โ ATR plus Parkinson, Garman-Klass, Rogers-Satchell, and Yang-Zhang covers different treatments of gaps, drift, and intrabar range.
The outputs are calibrated to a common width basis, so Volatility Factor remains interpretable across estimators and price scales. Fine adjustment may still be useful, but switching estimators should not require re-tuning by orders of magnitude.
โ The KTE on a trending instrument. The thick line is the active trailing stop; the thin line shows the opposing side of the envelope. Both expand and contract with market energy.
โ KTE beside TradingView's built-in SuperTrend, both using ATR with a 10-bar lookback. KTE's asymmetric profile changes how each side responds to directional volatility while the monotonic active band avoids premature loosening.
๐ธ --------- HOW IT WORKS --------- ๐ธ
๐ฎ Core Concept
The bands share a smoothed price estimator as their anchor, but use separate volatility profiles:
Upper band = estimator + (factor ร bullish-candle volatility)
Lower band = estimator โ (factor ร bearish-candle volatility)
In a bullish state, the lower band is active and can only rise. In a bearish state, the upper band is active and can only fall. This monotonic constraint prevents a live trailing stop from loosening within the trend.
The selected direction-switch method changes only the breach test. It does not change the smoothed estimator anchoring the envelope, so a wick-sensitive trigger cannot drag the bands around with the wick.
๐ฎ The Five Volatility Estimators
Each estimator reads a different part of the OHLC bar:
ATR (Wilder, 1978) โ Familiar baseline that handles gaps through true range.
Parkinson (1980) โ Uses high-low range; efficient under continuous, low-drift conditions.
Garman-Klass (1980) โ Adds open-close information; favours continuous sessions without material gaps.
Rogers-Satchell (1991) โ Drift-independent and well suited to trending, continuously traded instruments.
Yang-Zhang (2000) โ Combines overnight gaps, open-close movement, and Rogers-Satchell; the gap-aware default.
Statistical efficiency does not guarantee a visibly tighter stop. At slow Adaptation Speed settings, long averaging makes the estimators look similar; at fast settings, their different treatments of gaps, drift, and range become more visible. Choose according to the instrument's behaviour rather than expecting one estimator always to produce the narrowest band.
โ ATR and Yang-Zhang at Adaptation Speed 2. The long profile memory (low speed) smooths away most of the difference, so the two envelopes nearly overlap.
โ ATR and Yang-Zhang at Adaptation Speed 8. The short profile memory (high speed) exposes their different volatility readings, producing visibly distinct envelope widths.
๐ฎ Asymmetric Volatility Profiling and Adaptation Speed
The KTE stores volatility from bullish and bearish candles separately. Bullish samples determine the upper width; bearish samples determine the lower width. This allows the two sides to respond differently when upward and downward motion carry different energy.
Adaptation Speed controls the memory of this profile, not the speed of the price estimator and not the distance of the stop by itself. Its 1โ10 scale maps logarithmically to an internal window:
Speed 3 โ approximately 878 bars: stable and slow to re-weight
Default 3.5 โ approximately 570 bars: general-purpose smoothing
Speed 8 โ approximately 11 bars: highly responsive to recent volatility
Speed 10 โ approximately 2 bars: extremely reactive and noisy
Faster does not necessarily mean closer to price. During a volatility burst, a fast profile recognises the expansion sooner and may widen the band sharply. Because the active stop cannot loosen, it can then remain flat until the estimator catches up. A slow profile dilutes the same burst across much more history, so its narrower band may appear to follow price faster.
This is why two instances matched during a calm period can separate during a shock, especially when they also use different Volatility Factor values. Compare Adaptation Speed with the same factor first; matching lines in one regime does not make two configurations equivalent elsewhere.
The profiles are also direction-conditioned: bullish samples are replaced by later bullish candles and bearish samples by later bearish candles. A recent high-volatility sample can therefore persist through a run of opposite-colour candles, producing deliberate step-like plateaux in the relevant band.
โ Asymmetric profiling in action: the upper and lower widths respond independently to bullish- and bearish-candle volatility.
๐ฎ Direction Switch Methods
The breach source sets the balance between responsiveness and false flips:
On high/low โ Uses the current bar's wick and can switch on the breach bar. Fastest and most sensitive to noise.
On close โ Uses the previous confirmed close; the switch appears on the following bar.
On estimator โ Uses the previous smoothed estimator; the most conservative default, also switching on the following bar.
โ The three switch methods share the same band geometry but change direction at different times.
๐ธ --------- KEY FEATURES --------- ๐ธ
๐ฎ Eight Estimator Filters
The configurable price anchor includes:
Ultimate Smoother, 2- or 3-pole โ Low-noise, near-zero-lag passband response; the 2-pole version is the default.
Super Smoother, 2- or 3-pole โ Ehlers low-pass filters for progressively stronger smoothing.
BiQuad โ Second-order low-pass filter with an adjustable Q-factor.
ADXvma โ Adapts to trend strength and tends to flatten in ranges.
MAMA โ Cycle-adaptive MESA moving average.
A2RMA โ Adaptive recursive moving average with adjustable gamma.
They are provided by the open-source FiltersToolkit library.
๐ฎ Visual Layering
The display separates function from context:
Active band โ Thick directional trailing-stop line
Opposing band โ Thin reference for the inactive side
Channel fill โ Visual separation between the estimator and each band
Estimator โ Optional smoothed anchor
Palette, light/dark mode, widths, and transparencies can be adjusted independently.
๐ธ --------- USAGE GUIDE --------- ๐ธ
๐ฎ Getting Started
Start with the defaults, observe several calm and volatile regimes, and change one dimension at a time:
Tune Volatility Factor for the preferred stop distance.
Tune Adaptation Speed for how quickly width should respond to regime changes.
Choose the direction-switch method for the preferred confirmation level.
Change the volatility estimator only when its assumptions better fit the instrument.
๐ฎ Choosing a Volatility Estimator
Gapped equities โ Yang-Zhang accounts for overnight movement.
Trending 24/7 markets โ Rogers-Satchell is drift-independent without a separate gap component.
Continuous, range-led markets โ Parkinson or Garman-Klass offers efficient range-based measurement under their assumptions.
Familiar baseline โ ATR provides conventional true-range behaviour.
On continuous instruments, Rogers-Satchell and Yang-Zhang may look very similar because there are few gaps to distinguish them. Use the Volatility Toolkit to compare their raw behaviour on the intended instrument.
โ Three estimators compared on one instrument, each reading a different combination of OHLC information.
๐ฎ Tuning Width and Responsiveness
These controls solve different problems:
Volatility Factor โ Sets the distance per unit of measured volatility.
Adaptation Speed โ Sets the memory of the bullish/bearish profile; faster can widen the stop sooner during shocks.
Volatility Lookback โ Sets how quickly the underlying per-bar volatility estimate changes.
Estimator Lookback โ Sets the smoothness of the price anchor.
Use symptoms to guide adjustment:
Frequent flips on minor pullbacks โ Increase Volatility Factor or use a more conservative switch method (e.g. "on estimator").
Excessive give-back โ Decrease Volatility Factor or use a more responsive switch method (e.g. "on high/low").
Width reacts too slowly to regime changes โ Increase Adaptation Speed or reduce Volatility Lookback.
Bands become erratic during shocks โ Reduce Adaptation Speed or increase Volatility Lookback.
โ A tight factor follows price more closely and flips more often; a loose factor tolerates larger pullbacks.
๐ฎ Trading Applications
Discretionary trailing stop โ Move a protective stop with the active band as it tightens.
Trend confirmation โ Accept long signals only during a bullish KTE state, and short signals only while bearish.
Exit timing โ Treat a direction change as an exit when the trade thesis is trend-following.
๐ฎ Integration with GYTS Suite
The visible bands and estimator can be selected as sources by compatible Pine scripts. Two packed streams are also exposed:
๐ STREAM KTE ๐ช Trailing Stoploss โ Positive lower-band value in a bullish state; negative upper-band value in a bearish state.
๐ STREAM KTE ๐ช Mechanism โ Encodes the switch method and scale-invariant estimator relationship for compatible consumers.
The KTE is, first and foremost, a trailing stop, and these streams are built for stop management. The Order Orchestrator strategy consumes the Trailing Stoploss and Mechanism streams together : the first supplies the active stop level and its direction, the second makes the strategy's trailing-exit runner follow whatever switch method and estimator you set here. So the stop is configured once, in the KTE.
Beyond that primary role, the signed trailing-stop stream can also serve as a trend signal, since its sign flips with direction: it can be read through sign and magnitude as an entry/exit signal, including by Flux Composer . The KTE can also be paired with Market Regime Detector so flips are acted on only when the broader regime supports trend-following behaviour.
๐ธ --------- LIMITATIONS --------- ๐ธ
Trailing-stop latency โ Every trailing stop gives back some of the move between the trend extreme and the eventual breach.
Whipsaws in ranges โ Low-energy chop can produce repeated flips; a regime filter may help when ranging conditions dominate.
Fast adaptation can widen the stop โ Higher Adaptation Speed means faster volatility response, not guaranteed proximity to price.
Direction-conditioned memory โ A bullish or bearish outlier remains in its own profile until enough matching-direction samples replace it, which can create plateaux after shocks.
Warm-up and sample size โ Long profile windows need sufficient chart history; strongly one-sided markets may leave one side with few recent samples.
๐ธ --------- CREDITS --------- ๐ธ
๐ฎ Academic Sources
Wilder, J. W. (1978). New Concepts in Technical Trading Systems . Trend Research.
Parkinson, M. (1980). The Extreme Value Method for Estimating the Variance of the Rate of Return. Journal of Business, 53 (1), 61โ65. DOI
Garman, M. B., & Klass, M. J. (1980). On the Estimation of Security Price Volatilities from Historical Data. Journal of Business, 53 (1), 67โ78. DOI
Rogers, L. C. G., & Satchell, S. E. (1991). Estimating Variance from High, Low and Closing Prices. Annals of Applied Probability, 1 (4), 504โ512. DOI
Yang, D., & Zhang, Q. (2000). Drift-Independent Volatility Estimation Based on High, Low, Open, and Close Prices. Journal of Business, 73 (3), 477โ491. DOI
Ehlers, J. F. (2024). The Ultimate Smoother. Technical Analysis of Stocks & Commodities , 2024-04. TASC
Ehlers, J. F. (2004). Cybernetic Analysis for Stocks and Futures . Wiley. Covers SuperSmoother, MAMA and more.
๐ฎ Inspiration
Thanks to Trendoscope for inspiring us with the Supertrend - Ladder ATR (2021). It derives long-side stop distance from bearish-candle ATR and short-side distance from bullish-candle ATR, which is one of the mechanisms that we tried to develop further with the KTE.
๐ฎ Libraries Used
FiltersToolkit โ Ultimate Smoother, Super Smoother, BiQuad, ADXvma, MAMA, and A2RMA
VolatilityToolkit โ Parkinson, Garman-Klass, Rogers-Satchell, and Yang-Zhang estimators
MathTransform โ Logarithmic scaling for Adaptation Speed
ColourUtilities โ Palette management and light/dark-mode colour adjustment
Indicatore

Indicatore

Indicatore

Adaptive Source Supertrend (TESSEN)
Most Supertrend implementations do two things by default: use a fixed price source (usually hl2) and a fixed ATR multiplier. Both are decisions, not laws. This version makes them adaptive.
Source selection: on every bar, the script computes Kaufman's Efficiency Ratio โ a public-domain formula from Perry Kaufman's KAMA โ independently for Open, High, Low, and Close. ER measures how directionally a series has moved over a lookback window (1.0 = clean trend, 0.0 = pure noise). Whichever OHLC series currently has the highest ER becomes the working price source for the moving average and the trailing stop. A hysteresis margin (adjustable) stops it flipping between two near-tied sources on every bar.
Band width: the ATR multiplier isn't fixed either. It scales with a volatility percentile rank โ where current ATR sits relative to its own recent range. Bands widen automatically in high-volatility regimes and tighten in low-volatility regimes, instead of using one multiplier for every market condition.
What it deliberately doesn't do: no signals dressed up as certainty, no repainting (all selection and flips evaluate on confirmed bars only), no performance claims. A dynamic source and adaptive bands are a different set of assumptions than the classic version โ not a guaranteed improvement. Backtest both on your own instrument before trusting either.
Includes: adjustable MA type on the selected source, BUY/SELL labels and glow fills on trend flips, source-switch markers, and alerts for both trend flips and source switches. Indicatore

Swing Ladder Trend Engine [Jayadev Rana]OVERVIEW
Swing Ladder Trend Engine is a pure price-action trend-following tool. It builds its entire read of the market from confirmed swing highs and swing lows โ no moving averages, no ATR, no oscillators. From that swing structure it derives three things: the current trend state, entry and exit signals, and a structure-anchored trailing stop (the "ladder") that only steps in the direction of the trade.
HOW IT WORKS
1. Swing structure. Confirmed pivot highs and lows (Swing Detection Length bars on each side) are classified as HH, HL, LH or LL and tagged on the chart.
2. Trend engine. When a bar closes beyond the most recent confirmed swing high, the trend state flips bullish; a close below the last confirmed swing low flips it bearish. Each swing level can only be broken once, so continuation breaks are tracked cleanly and bars are tinted by the active trend.
3. Ladder stop. Instead of a volatility trail, the stop is anchored to structure itself: in an uptrend it sits below the last confirmed swing low, offset by a configurable percentage of the current swing range, and it can only ratchet upward as new higher lows confirm. The result is a stepped "ladder" that gives the trade room where structure says it needs room, and tightens where structure tightens.
4. Pullback-quality entries. In the default Pullback mode a structure break only arms a setup. The entry itself requires the market to retrace into the breakout leg (between the Min and Max Retracement %), and then print a resumption candle: a close beyond the previous bar's extreme with a directional body of at least the Trigger Body Dominance fraction of its range. Retracements deeper than the maximum void the setup. A Breakout mode is included for traders who prefer to enter on the structure break itself.
SIGNALS: ENTRY, EXIT AND STOP
LONG / SHORT labels mark entries; the label tooltip stores the entry price and the ladder stop at that moment. A trade is closed either when price closes through the ladder stop or when the structure flips against it โ the โ exit label's tooltip reports the reason and the approximate result in R (risk multiples, measured from entry to the initial ladder stop). All signals are evaluated on confirmed bars only.
DASHBOARD AND ALERTS
A compact dashboard shows the live trend state, the latest swing structure tags, the active signal, the current ladder stop level and the open trade's running R. Six alerts are available: long entry, short entry, exit long, exit short, and bullish/bearish trend flips.
SETTINGS
Swing Detection Length controls the size of the structure being tracked (larger = bigger swings, later confirmation). Entry Mode switches between Pullback and Breakout logic. Min/Max Retracement % and Trigger Body Dominance define what counts as a quality pullback entry. Stop Buffer sets how far beyond the protected swing the ladder sits, as a % of the current swing range. Dashboard position/size, structure labels, bar coloring and colors are all configurable.
LIMITATIONS
Swing points confirm only after the chosen number of right-side bars, so structure tags appear with a delay by design โ this is what keeps the logic non-repainting on confirmed bars. Signals fire on bar close, not intrabar. Like any trend-following method, it gives back ground in choppy, range-bound conditions; the pullback filters reduce but do not remove that. R values shown in tooltips and the dashboard are approximations based on closing prices and do not account for gaps, fees or slippage. This is an analysis tool, not financial advice โ always test settings on your own market and timeframe before relying on them.
WHY IT IS ORIGINAL
The combination of a swing-anchored ratcheting stop whose buffer adapts to the current swing range, plus an entry gate built from retracement depth and candle body dominance โ all derived exclusively from raw price structure โ is what this script contributes. It is not a mashup of built-in indicators; every state in the engine comes from the swing ladder itself. Indicatore

Donchian Breakout with ATR Trailing Stop (Trend Following)A simple, transparent trend-following strategy: a classic Donchian
(turtle) channel breakout with a single ATR-based trailing stop.
It was deliberately built to be robust across markets rather than
curve-fit to one โ the same code and settings held up on both an
equity index (DAX/GER40, 1h) and Bitcoin (BTCUSD, 4h), and across
trailing multipliers of 2.5โ3.5.
HOW IT WORKS
- Entry: goes long when price closes above the highest high of the
last N bars (default 20) while above the 200 EMA trend filter.
Short side is optional and off by default.
- Exit: one ATR-based trailing stop (distance = ATR ร multiplier,
default 2.5, fixed at entry). It serves as both the initial
protective stop and the trailing exit โ cutting losses and letting
winners run, fully automatically. No separate exit signal needed.
- Risk: size is derived from a fixed % risk per trade against the
stop distance (compounding), with optional risk and leverage caps.
- Optional weekend-flat close for instruments with gap risk.
HOW TO USE
- Best on genuinely trending markets. Try it on your own instrument
and timeframe.
- Tune the risk % to your own drawdown tolerance, and the ATR
multiplier to taste (2.5โ3.5 behaved similarly โ a good sign the
edge isn't fitted to one value).
- Built-in alerts: the entry alert gives you the trailing-stop
distance to set on your broker; the trailing stop handles the exit.
WHAT TO EXPECT โ READ THIS
- It's a breakout system, so win rate is LOW: ~40โ45% is normal.
The edge is that winners are bigger than losers, not that you're
right often. Judge it by profit factor and drawdown, not win rate.
- Expect long flat/drawdown periods in choppy, range-bound markets.
It performs when markets trend.
- COSTS DECIDE EVERYTHING. Set your own broker's spread/commission
in the properties before trusting any result. Something that looks
great at zero cost can be break-even or worse once real spreads โ
and, for leveraged CFDs, overnight financing โ are included.
Results vary a lot by broker and instrument.
NOTES
- No repainting: entries use the prior bar's channel; the trailing
stop only ratchets in the trade's favor.
- Not financial advice. Past backtest results do not guarantee
future performance. Always test on your own market, timeframe and
broker costs, and only risk what you can afford to lose. Strategia

Volatility Trail [BOSWaves]Volatility Trail - Hull-Anchored ATR Trail with Gradient Cloud Radiation and Multi-Mode Candle Scoring
Overview
Volatility Trail is a Hull-anchored trend trailing system that constructs an ATR-scaled ratcheting trail from a Hull Moving Average baseline, where trend state, gradient cloud geometry, and candle coloring intensity are driven by the relationship between price and the adaptive trail rather than by fixed thresholds or static band crossovers.
Instead of relying on conventional moving average crossovers or symmetric bands, trend state is determined by a one-directional ratcheting trail that advances in the trend direction and locks in progress, only flipping when price closes through the trail level in the opposing direction. The trail distance from the Hull baseline scales with ATR, ensuring the ratchet respects current volatility conditions rather than applying a fixed distance regardless of market behavior.
This creates a trailing trend framework that combines a responsive Hull baseline with a volatility-calibrated ratchet mechanism, a radiating four-layer gradient cloud that visually maps the space between trail and price, and a configurable candle coloring system that scores each bar by distance from the trail, trail acceleration, or both, producing a chart where candle brightness communicates conviction intensity rather than merely indicating direction.
Price is therefore evaluated not just for its position relative to the trail but for how far it has extended from it and how fast the trail itself is advancing, providing a multi-dimensional conviction reading through the visual layers of the indicator.
Conceptual Framework
Volatility Trail is founded on the principle that a trailing trend system should do three things simultaneously: define trend state through a ratcheting mechanism that locks in directional progress, communicate the spatial relationship between price and the trail through a graduated visual field, and score candle conviction based on measurable characteristics of that relationship rather than applying uniform coloring regardless of momentum state.
Traditional trailing indicators provide a line that defines trend direction but offer no framework for understanding how convincingly price is separated from that line or whether the trail itself is accelerating. This framework adds those dimensions through the gradient cloud and candle scoring systems, transforming a single trail line into a complete visual conviction map that reveals both where price is relative to the trail and the dynamic quality of the separation between them.
Three core principles guide the design:
The trail should ratchet in the trend direction using ATR-scaled distance from a Hull baseline, locking in progress and only reversing when price demonstrates a genuine closing breach rather than a temporary excursion.
The space between the trail and price should be visualized as a graduated gradient field with multiple opacity layers that radiates from the trail toward price, communicating proximity and separation depth visually rather than numerically.
Candle coloring should reflect measurable conviction characteristics through configurable scoring modes, dimming bars with weak conviction and brightening bars with strong distance or acceleration readings to encode momentum quality into the candlestick display.
This shifts trailing trend analysis from single-line direction tracking into a multi-layer conviction visualization where the trail, cloud, and candles collectively communicate trend state, spatial conviction, and momentum quality simultaneously.
Theoretical Foundation
The indicator combines Hull Moving Average baseline construction, ATR-scaled ratcheting trail mechanics, four-layer gradient cloud construction using proportional gap interpolation, and a dual-mode candle scoring system based on distance normalization and trail acceleration measurement.
The Hull Moving Average provides a low-lag directional baseline that reduces the smoothing delay of standard moving averages while maintaining noise resistance. The trail ratchets by advancing the lower band as a minimum during uptrends and the upper band as a maximum during downtrends, preventing the trail from retreating against price and locking in each bar's progress. The gradient cloud divides the gap between trail and price into four proportionally spaced bands at 20, 40, 65, and 85 percent of the total gap, filling each interval with progressively increasing transparency to create a radiating visual field. Candle scoring normalizes either distance from trail or trail advancement speed against ATR, applies a power transformation to suppress weak readings, and maps the result to a gradient between a neutral dim color and the full trend color.
Four internal systems operate in tandem:
Hull ATR Trail Engine : Calculates the Hull MA baseline and derives upper and lower ATR-scaled bands, maintaining a ratcheting trail that advances with the trend and flips to the opposing band only when price closes through the current trail level.
Gradient Cloud System : Computes four proportional interpolation points between the smoothed trail and price, plots invisible bands at each point, and fills the intervals with opacity-graduated fills that intensify near the trail and fade toward price, producing a radiating cloud effect.
Candle Scoring Engine : Measures distance from trail normalized by ATR and trail advancement speed normalized by ATR fraction, applies a power exponent to crush weak scores, and maps the resulting score to a gradient from a dim neutral color to the full trend color through configurable distance, acceleration, or combined scoring modes.
Retest Detection System : Monitors price proximity to the trail after the signal buffer period, triggering retest diamonds when price approaches within an ATR-fraction zone of the trail without crossing it, with per-side cooldown enforcement between consecutive signals.
This design allows the trail to provide clean directional state through ratcheting mechanics while the cloud and candle systems layer spatial and momentum conviction context onto the same chart space.
How It Works
Volatility Trail evaluates price through a sequence of trail-aware and conviction-scoring processes:
Source Selection : The price source used for Hull calculation and trail comparison is selected from Close, HL2, HLC3, or OHLC4, allowing the baseline to be anchored to the most appropriate price representation for the target instrument.
Hull Baseline Calculation : The Hull Moving Average is calculated over the configured length from the selected source, providing a low-lag directional reference that minimises the lag penalty of standard moving averages.
ATR Band Derivation : Upper and lower bands are calculated by adding and subtracting ATR multiplied by the configured factor from the Hull baseline, producing volatility-scaled boundaries that adapt to changing market conditions.
Trail Ratcheting : During an uptrend the trail advances as the maximum of the lower band and the prior trail, preventing retreat against price. During a downtrend it advances as the minimum of the upper band and the prior trail. When price closes through the current trail the trend flips and the trail resets to the opposing band.
Trail Display Smoothing : An EMA smoothing pass over the configurable length is applied to the trail for display purposes, producing a visually cleaner line while signals continue to fire from the raw unsmoothed trail.
Gradient Cloud Construction : The gap between the smoothed trail and close is calculated and four interpolation points are derived at proportional fractions of that gap. Each interval between adjacent points is filled with a directional color at progressively increasing transparency, producing a graduated cloud that radiates from the trail outward toward price.
Distance Scoring : The absolute distance between close and the smoothed trail is divided by three times ATR to produce a normalized 0-1 distance score, measuring how far price has extended from the trail relative to recent volatility.
Acceleration Scoring : Trail advancement speed is measured as the absolute change in trail position over the acceleration lookback, normalized by a fraction of ATR, producing a 0-1 score reflecting how quickly the trail is currently advancing.
Score Combination and Power Transform : Depending on the selected candle mode, the distance score, acceleration score, or their maximum is selected, then raised to the power of 2.5 to suppress low-conviction readings and concentrate brightness at genuinely strong bars.
Candle Color Mapping : The transformed score maps from a fixed dim neutral color at zero to the full trend color at one, producing candles that are nearly invisible during low-conviction conditions and fully saturated during strong extension or acceleration events.
Retest Diamond Detection : After the signal buffer period from the most recent flip, price approaching within a fraction of ATR of the trail without crossing it triggers a directional retest diamond, with per-side cooldown enforced between consecutive signals.
Together, these elements form a continuously updating trail system where ratcheting mechanics define direction, gradient cloud layers map spatial conviction, and candle scoring communicates momentum quality across every bar of the trend.
Interpretation
Volatility Trail should be interpreted as a ratcheting trend system with radiating conviction geometry and multi-mode candle intensity scoring:
Bullish Trend State (Green) : Active when the trail has ratcheted below price and price has not closed below it, with the gradient cloud radiating upward from the trail toward the current bar.
Bearish Trend State (Red) : Active when the trail has ratcheted above price and price has not closed above it, with the gradient cloud radiating downward from the trail toward the current bar.
Trail Line : The smoothed ratcheting trail provides the primary directional boundary, advancing with the trend and serving as the structural invalidation level for the current directional state.
Gradient Cloud : Four fills between the trail and price create a radiating opacity field that intensifies near the trail and fades toward price, visually encoding the spatial relationship between the ratchet boundary and current price action. A thick, prominent cloud indicates substantial separation, while a thin cloud suggests price is close to the trail and near potential retest territory.
Distance Mode Candles : Candle brightness reflects how far price has extended from the trail relative to ATR. Bright candles indicate substantial separation, dim candles indicate proximity to the trail.
Acceleration Mode Candles : Candle brightness reflects how fast the trail itself is advancing. Bright candles indicate the trail is moving quickly with the trend, dim candles indicate the trail is stalling.
Both Mode Candles : Candle brightness reflects the maximum of distance and acceleration scores, brightening when either strong extension or strong trail advancement is present.
โฒ Buy Signals : Green triangles mark upward trail flips where trend has switched from bearish to bullish and the trail has reset to the lower ATR band.
โผ Sell Signals : Red triangles mark downward trail flips where trend has switched from bullish to bearish and the trail has reset to the upper ATR band.
โ Retest Diamonds : Small diamonds plotted below bars during bullish retests and above bars during bearish retests when price approaches within the retest zone of the trail after the signal buffer period, identifying potential continuation interaction points with the trailing boundary.
Trail position, cloud depth, candle brightness, and retest diamond placement collectively provide more conviction information than trend direction alone.
Signal Logic & Visual Cues
Volatility Trail presents two primary trail flip signals alongside continuous retest zone monitoring:
Buy Signal (โฒ) : Green triangle appears when the trail ratchet flips from bearish to bullish, indicating price has closed above the upper ATR band and the trail has reset to the lower band to begin a new bullish ratchet cycle.
Sell Signal (โผ) : Red triangle appears when the trail ratchet flips from bullish to bearish, indicating price has closed below the lower ATR band and the trail has reset to the upper band to begin a new bearish ratchet cycle.
Retest diamond detection provides continuous secondary monitoring, marking proximity to the trail after the signal buffer period with independent per-side cooldown enforcement, identifying potential continuation setups at the ratchet boundary throughout the established trend.
Alert generation covers bullish and bearish trail flips and both bullish and bearish retest events for systematic trend monitoring workflows.
Strategy Integration
Volatility Trail fits within volatility-adaptive trailing and momentum conviction approaches:
Trail Flip Entries : Use trail flip signals as primary trend initiation triggers where price has closed through the ATR-scaled boundary and the ratchet has reset in the new direction, with the newly positioned trail providing an immediate structural invalidation reference.
Candle Mode Selection for Instrument Type : Use Distance mode on instruments where price extension from the trail is the primary conviction indicator, Acceleration mode on instruments where trail advancement speed is more consistent, and Both mode for instruments where either characteristic can signal high conviction depending on market phase.
Cloud Depth Assessment : Use gradient cloud depth as a real-time spatial conviction reading. A deep cloud with multiple visible layers indicates substantial separation and trend momentum. A thin cloud with minimal fill depth indicates price is compressing toward the trail and a retest is increasingly probable.
Retest Diamond Re-entry : Use retest diamonds as lower-risk continuation entry references within established trends, entering in the trend direction when price approaches the trail boundary after the signal buffer period rather than chasing extended price action far from the trail.
ATR Factor Calibration : Adjust the ATR factor to match the instrument's typical volatility behavior at the target timeframe, using higher factors for instruments requiring more room between price and trail and lower factors for tighter ratchet tracking.
Multi-Timeframe Trail Alignment : Apply higher-timeframe trail direction as a bias filter, engaging with lower-timeframe flip signals and retest diamonds only when they align with the established higher-timeframe ratchet direction.
Technical Implementation Details
Core Engine : Hull Moving Average baseline with configurable source and ATR-scaled ratcheting trail mechanics
Trail Logic : One-directional ratchet advancing as band maximum or minimum in respective trend directions with flip on close breach
Gradient Cloud : Four proportional gap interpolation points with interval fills at graduated transparency levels radiating from trail toward price
Candle Scoring : ATR-normalized distance and acceleration scoring with power transform and gradient mapping to dim-to-trend-color range
Retest System : ATR-fraction proximity zone detection with signal buffer and independent per-side cooldown enforcement
Visualization : Smoothed trail line, four-layer gradient cloud fills, flip signal labels, retest diamond markers, and multi-mode intensity-scored candle coloring
Signal Logic : Raw trail flip detection with smoothing applied to display only, preserving signal timing accuracy
Performance Profile : Optimized for real-time execution across all timeframes with stateful trail variable maintaining ratchet progress between bars
Optimal Application Parameters
Timeframe Guidance:
1 - 5 min : Intraday trail tracking for scalping with shorter Hull length and tighter ATR factor for fast ratchet response to intraday momentum shifts
15 - 60 min : Session-level trend identification with balanced Hull length and moderate ATR factor for reliable directional framing across typical session moves
4H - Daily : Swing-level trailing with longer Hull length and higher ATR factor for sustained ratchet persistence across multi-session directional moves
Suggested Baseline Configuration:
Hull Length : 72
ATR Length : 9
ATR Factor : 1.7
Source : Close
Trail Smoothing : 4
Show Gradient Cloud : Enabled
Color Candles : Enabled
Candle Color Mode : Distance
Show Buy/Sell : Enabled
Retest Diamonds : Enabled
These suggested parameters should be used as a baseline; their effectiveness depends on the instrument's volatility characteristics, Hull responsiveness at the target timeframe, and preferred signal frequency, so fine-tuning is expected for optimal performance.
Parameter Calibration Notes
Use the following adjustments to refine behavior without altering the core logic:
Trail flips too frequently : Increase ATR Factor to widen the distance between the Hull baseline and the trail boundary, requiring more significant price displacement before a flip is registered.
Trail flips too slowly : Decrease ATR Factor toward 0.5 for a tighter trail that responds faster to directional changes, or decrease Hull Length for a more reactive baseline.
Hull baseline too laggy : Decrease Hull Length toward 20 for a faster baseline that captures directional shifts earlier, accepting increased sensitivity to short-term price fluctuations.
Hull baseline too reactive : Increase Hull Length for a smoother baseline that filters minor oscillations and produces a more stable trail ratchet with fewer noise-driven flips.
Candles too uniformly dim : Switch to Acceleration mode if the instrument's trail advancement speed is more variable than its price extension, or reduce ATR Factor so distance scores normalize against a tighter trail range.
Too many retest diamonds : Increase Retest Cooldown to enforce greater bar separation between consecutive diamond markers, or increase Signal Buffer to delay retest detection further from each flip event.
Retest diamonds not firing : The retest zone is sized as a fraction of ATR multiplied by the ATR Factor. On instruments with very consistent trail distance this zone may be narrow. Increasing ATR Factor slightly widens the retest detection zone relative to the trail boundary.
Adjustments should be incremental and evaluated across multiple session types rather than isolated market conditions.
Performance Characteristics
High Effectiveness:
Trending markets with sustained directional moves where the Hull baseline advances consistently and the trail ratchets without frequent resets, producing deep gradient clouds and bright high-conviction candles throughout the move
Instruments with consistent ATR behavior where the volatility-scaled trail distance produces reliable flip signals without excessive noise-driven reversals
Momentum continuation strategies that benefit from the retest diamond system identifying pullback interactions with the trail boundary as lower-risk continuation entry points
Multi-mode candle scoring approaches where distance or acceleration scoring provides additional conviction context that supplements the directional trail signal
Reduced Effectiveness:
Choppy, low-momentum markets where price oscillates near the Hull baseline, causing frequent trail flips and preventing the ratchet from establishing meaningful directional progress
Extremely volatile instruments where ATR spikes produce wide trail distances that delay flip detection relative to the actual structural change in price direction
Consolidation environments where the Hull baseline moves sideways and the trail ratchet stalls, producing minimal cloud depth and uniformly dim candles without directional conviction scoring
News-driven or gap-heavy markets where instantaneous price displacements trigger trail flips that immediately reverse before the ratchet can establish sustained directional progress
Mean-reversion dominant conditions where trail flips occur rapidly in alternating directions without the sustained follow-through required for gradient cloud development or sequential retest patterns
Integration Guidelines
Confluence : Combine with BOSWaves structural tools, order flow analysis, or momentum oscillators to validate trail flip signals with broader analytical context before committing to directional positions
Cloud Depth Monitoring : Track gradient cloud depth evolution throughout the trend as a spatial conviction indicator. Progressively deepening cloud layers suggest sustained separation and trend health while thinning cloud depth warns of price compression toward the trail and potential retest or flip conditions.
Candle Mode Selection : Match the candle scoring mode to the instrument's typical conviction expression. Instruments that show conviction through large extension moves favor Distance mode; instruments that show conviction through accelerating trail advancement favor Acceleration mode; instruments that express conviction through either mechanism favor Both mode.
Ratchet Progress Awareness : Recognize that the trail only advances and never retreats against price within a trend. Rapid trail advancement reflected in bright Acceleration mode candles indicates strong directional follow-through, while a stalling trail with minimal advancement suggests momentum is flattening before potential reversal.
State Discipline : Maintain directional bias aligned with the current trail trend state until a confirmed closing breach of the trail triggers a flip. Retest diamonds and cloud thinning within an established trend represent continuation context rather than reversal signals and should not override the ratchet-defined directional state.
Disclaimer
Volatility Trail is a professional-grade Hull-anchored trend trailing and conviction visualization tool. It uses ATR-scaled ratcheting trail mechanics with gradient cloud construction and multi-mode candle scoring but does not predict future price movements. Results depend on market conditions, instrument volatility characteristics, parameter selection, and disciplined execution. BOSWaves recommends deploying this indicator within a broader analytical framework that incorporates order flow context, structural analysis, and comprehensive risk management. Indicatore

Calibrated Supertrend Strength-Graded & Multi-Timeframe## Calibrated Supertrend โ Confirmed, Strength-Graded & Multi-Timeframe (ST ARC)
### What it is
A Supertrend rebuilt to fix the three things that frustrate everyone who uses the
plain version, and to tell you **how trustworthy each trend flip is** before you act
on it. A classic Supertrend uses a **fixed ATR multiplier** (an arbitrary guess that
whipsaws in volatile markets and lags in calm ones), it **flips on noise** (every
marginal poke through the band reverses it), and it gives you **no sense of quality**
(a great flip and a junk flip look identical). ST ARC addresses all three, then
scores every flip 0โ100 and โ crucially โ **calibrates that score to what actually
happened on this symbol**, so the number is accountable rather than decorative.
It runs on **any symbol, asset class, timeframe and market**. The raw data source
and every optional feed are user-selectable; nothing is hard-coded to a market.
### Why these components are combined (mashup rationale)
Each layer removes one specific, nameable failure of the plain Supertrend and feeds
the next โ none is decorative:
1. **Adaptive multiplier** โ the band width is no longer fixed. The ATR multiplier
becomes a series that scales with a **volatility rank** (how high current ATR
sits versus its own recent history): wider when volatility is high to cut
whipsaw, tighter when calm, and wider still when trend **efficiency** is low
(choppy tape). The ATR *length* can also adapt to the measured dominant cycle.
2. **Confirmation gate (de-whipsaw)** โ a raw flip is only **confirmed** when the
close breaches the prior band by a minimum fraction of ATR *and* a minimum number
of bars have passed since the last flip, evaluated on closed bars
(non-repainting). This fixes the "flips on noise" problem.
3. **Regime classifier** โ efficiency ratio + trend strength + a volatility-cluster
measure label the market Trend / Range / Volatile, so flips are trusted or
discounted by context.
4. **Multi-timeframe agreement** โ three higher-timeframe Supertrends (multiples of
your chart timeframe) are read with no repainting and counted for agreement; a
signal that all higher timeframes oppose can be vetoed.
5. **Flip-strength score + conviction with hard vetoes** โ at each flip a 0โ100
strength is built from breach depth, trend strength, efficiency, MTF agreement,
regime alignment, volume thrust and volume delta, then gated by hard vetoes
(volatility spike, higher timeframes opposed, a fresh flip inside a chop regime,
cross-asset conflict). The output is one verdict plus a strength grade.
Remove any single layer and a specific Supertrend failure returns โ that is the
justification for combining them.
### How it is original
ST ARC keeps a **self-calibrating quality engine**. It records every confirmed flip
and, a fixed window later, checks whether price actually ran a **favourable target
(measured in ATR)** in the flip's direction โ i.e. whether the trade *worked*, not
merely whether the line avoided re-flipping. From that it reports, on the dashboard
and on each flip label, the **realized win-rate of past flips at each strength tier**
on this very symbol, plus the average favourable excursion. It can even **auto-learn
the strength threshold** at which flips have historically met a target win-rate and
use that as the action filter. A stock Supertrend tells you nothing about the quality
of its own signals; this one is accountable to its own track record.
### What it plots
- A single **Supertrend line** on price, green up / red down, with the flip triangle
**colour-graded by strength** (strong = solid, weak = faded) and a small
**strength label** on each flip (score + grade).
- An optional **second, slower Supertrend** (thinner line, contrasting colour,
diamond markers) for fast/slow confluence, with a DUAL agreement readout.
- A compact **dashboard**: verdict, regime, direction, the live adaptive multiplier
and ATR length, the flip state with its strength and that tier's realized
win-rate, MTF agreement, the calibration stat, dominant cycle, a risk-based size
reference and any active veto.
### How to use it
1. Trade with the line: long bias while it is below price (green), short while above
(red). The line is a natural trailing stop.
2. Act on **confirmed flips** (the triangles), not raw touches, and weight them by
the **strength score** โ strong flips in a Trend regime with higher-timeframe
agreement are the high-quality ones; weak flips in a chop regime are the ones to
skip.
3. Use the **conviction / strength gates** and any active **veto** as a filter; the
optional **auto-learned strength cutoff** suppresses the verdict on flips weaker
than the level that has historically met your target win-rate.
4. The size shown is an ATR-based reference for journaling, not an order.
5. Alerts cover confirmed flips, the conviction verdict, raw flips and the secondary
Supertrend.
### Settings (use on any asset / market)
- **Raw data source** โ `hl2`, `hlc3`, `close`, `ohlc4`, or point it at **another
indicator's plot**. This is what lets it work on any instrument or on your own
series.
- **Supertrend core** โ ATR length (with optional dominant-cycle adaptive length)
and base multiplier.
- **Adaptive multiplier** โ volatility-rank lookback, calm/volatile scaling and an
optional chop-widening term.
- **Confirmation** โ minimum breach in ATR, minimum bars between flips, non-repaint
on close.
- **Calibration** โ the judging window and the favourable target (in ATR) that
defines a "good" flip; the auto-learn cutoff and its target win-rate.
- **Regime / MTF / conviction weights / secondary Supertrend** โ all exposed.
- **Optional feeds (blank = off):** a *volatility-index symbol* (spike veto) and a
*cross-asset symbol* (confluence). Both blank by default, so the script is fully
self-contained on any market.
### Notes
- It is a **study / indicator**, not a strategy, and it places no orders.
- Confirmed flips are evaluated on bar close to avoid intrabar repainting;
higher-timeframe reads use confirmed values.
---
### Disclaimer
This script is provided for educational and informational purposes only. It is a
technical-analysis study, not financial, investment, or trading advice, and not a
recommendation or solicitation to buy or sell any instrument. No indicator can
predict markets; past behaviour and any historical statistics shown (including the
flip win-rates) do not guarantee future results. Trading involves substantial risk of
loss. You are solely responsible for your own decisions โ do your own research and
consider consulting a licensed financial professional before trading. The author
accepts no liability for any loss arising from use of this script.
Indicatore

Trend Volatility RegimeThe Trend Volatility Regime is an all-in-one trend-following model that identifies changes in the market regime by combining moving-average crossover signals with volatility-adaptive trailing stops. It features an integrated backtesting engine that provides institutional-grade insights into historical strategy performance, along with a built-in alert system that notifies investors in real time when regime changes occur. The model integrates seamlessly into the price chart and presents backtest results in a clear, color-coded table benchmarked against buy-and-hold.
At its core, the model combines two complementary trend detection components to determine the prevailing market regime. The first component identifies the underlying structural trend using a volatility-adjusted moving-average crossover based on the spread between fast and slow moving averages. The second component identifies trend reversals using an adaptive trailing stop based on changes in price and volatility. Bullish and bearish regimes occur when both crossover and volatility signals are directionally aligned, while conflicting signals result in neutral regimes.
Bullish Crossover Signal = (Fast MA โ Slow MA) > (ATR ร Trend Margin)
Bearish Crossover Signal = (Fast MA โ Slow MA) < โ(ATR ร Trend Margin)
Bullish Volatility Signal = Price > (Highest Price โ (Volatility ร Stop Factor))
Bearish Volatility Signal = Price < (Lowest Price + (Volatility ร Stop Factor))
By default, the model applies an asymmetric regime design in which conflicting signals default to a bullish regime unless half-equity positions are enabled in the menu. This asymmetric design reflects the tendency of risk assets to deteriorate gradually while recovering more abruptly. The moving-average component captures the slower deterioration typically observed during market tops, while the trailing stop component responds more dynamically to faster reversals typically observed at market bottoms. This helps reduce overreaction to corrections during uptrends while still allowing for faster re-entry following sharp recoveries. To evaluate the performance of different parameter configurations, the model includes a built-in table with the following metrics:
CAGR = Compounded Annual Growth Rate.
Excess = CAGR in excess of buy-and-hold.
Sharpe = CAGR per unit of standard deviation.
Sortino = CAGR per unit of downside deviation.
Calmar = CAGR relative to maximum drawdown.
Max DD = Largest peak-to-trough decline in value.
Alpha (ฮฑ) = Excess annualized risk-adjusted returns.
Win Rate = Ratio of profitable trades to total trades.
Profit Factor = Total gross profit per unit of losses.
Expectancy = Average expected return per trade.
Turnover = Average annualized change in exposure.
This indicator is designed with flexibility in mind, enabling users to specify the start date of the backtesting period, the preferred trend type, volatility type, and regime visualization. Supported regime visualizations include line, candle, and shaded background. Supported moving-average types include the Exponential Moving Average (EMA), Simple Moving Average (SMA), Wilderโs Moving Average (RMA), and Weighted Moving Average (WMA). Supported volatility types include the Average True Range (ATR), Standard Deviation (SD), and Mean Absolute Deviation (MAD). Supported price sources include Close, HL2, HLC3, and OHLC4. The table follows an intuitive color-coded logic that allows for quick performance comparison against buy-and-hold (B&H):
CAGR = Green indicates above 0%, while red indicates below 0%.
Excess = Green indicates above 0%, while red indicates below 0%.
Sharpe = Green indicates better than B&H, while red indicates worse.
Sortino = Green indicates better than B&H, while red indicates worse.
Calmar = Green indicates better than B&H, while red indicates worse.
Max DD = Green indicates better than B&H, while red indicates worse.
Alpha (ฮฑ) = Green indicates above 0%, while red indicates below 0%.
Win Rate = Green indicates above 50%, while red indicates below 50%.
Profit Factor = Green indicates above 2, while red indicates below 1.
Expectancy = Green indicates above 0%, while red indicates below 0%.
In summary, the Trend Volatility Regime is a comprehensive trend-following tool designed to help investors stay on the right side of the market by identifying key changes in the market regime. By combining volatility-adjusted moving-average crossover signals with adaptive volatility-based trailing stops, the model seeks to maximise participation during uptrends while reducing exposure during sustained downtrends. While the model provides valuable historical insights, users should remain mindful that past results may not necessarily persist under future market conditions. Indicatore

Efficiency Trailing Stop LossEfficiency TSL is an adaptive trailing stop framework designed to dynamically follow market movement while continuously adjusting stop behavior based on changing price efficiency and directional conditions.
Unlike traditional trailing stop systems that rely on static ATR values or fixed structure levels, Flip TSL evaluates how effectively price is moving and uses that information to expand, tighten, or aggressively reduce risk as market behavior evolves.
The objective is not simply to trail price, but to adapt risk management according to changing market conditions beneath the surface.
By combining market efficiency analysis, directional state detection, adaptive stop expansion logic, and automatic long/short transition behavior into a unified framework, the indicator is designed to provide additional context for trade management and evolving market structure.
Features
โข Single adaptive trailing stop line
โข Automatic Long โ Short transition system
โข Dynamic stop expansion and tightening engine
โข Market efficiency analysis
โข Improvement / deterioration detection
โข Automatic direction logic modes:
โข Stop Cross
โข SMA Direction
โข Candle Direction
โข Structure Step stop logic
โข Swing High / Low fallback logic
โข Multi-timeframe calculations
โข Adjustable timeframe selection
โข Wait-until-close confirmation option
โข Dynamic ATR stop sizing
โข Real-time dashboard
โข Fully customizable colors and display settings
Dashboard Includes
โข Current direction mode
โข Auto direction method
โข Efficiency score
โข Market state
โข Stop mode
โข Active ATR multiplier
โข Current trailing stop value
Alerts Included
โข Flipped Long
โข Flipped Short
โข Efficiency crossed below threshold
โข Long Mode Activated
โข Short Mode Activated
Potential Use Cases
โข Dynamically manage open positions
โข Adapt stop placement to changing conditions
โข Reduce risk during deteriorating environments
โข Hold stronger trends longer
โข Filter lower-quality market conditions
โข Add confluence to existing systems
โข Study changing market behavior
Interpretation
Expanded
Market efficiency is elevated and conditions remain supportive of directional continuation.
The trailing stop expands and provides additional room for price movement.
Tightening
Market conditions begin slowing or losing efficiency.
The trailing stop contracts and moves closer to price action.
Cut / Take Profit
Market efficiency falls beneath the defined threshold.
The stop may aggressively tighten or move toward current price to reduce exposure and protect gains.
Direction Modes
Stop Cross
Direction flips when price crosses the active trailing stop.
SMA Direction
Direction follows price relative to moving average positioning.
Candle Direction
Direction adapts based on bullish and bearish candle behavior.
About TrendGenY Indicators
TrendGenY indicators are built from market experience, creative concepts, and a constant pursuit of unique perspectives. Rather than following conventional ideas, the focus is on uncovering alternative insights and viewing market behavior through different angles to reveal information that traditional tools may overlook and help traders build a more meaningful edge in the market. Indicatore

Extreme Reversal Channel [JOAT]Extreme Reversal Channel
Introduction
Extreme Reversal Channel is an open-source adaptive channel that tracks persistent upper and lower extremes, gradually resets stale levels, and marks confirmed reversal conditions when price rejects a fresh extreme through the channel midpoint.
The problem it solves is stale channel context. Fixed lookback channels can jump abruptly as old bars roll out. Extreme Reversal Channel uses persistent state and controlled interpolation, creating smoother structural boundaries while still adapting to current price.
Core Concepts
1. Persistent Extreme Tracking
The upper channel updates when a new high exceeds the current upper core. The lower channel updates when a new low breaks the current lower core.
2. Counter-Based Reset
If no new extreme appears after the selected reset length, the stale level interpolates toward current price using the reset alpha setting.
upperCore := upperCore * (1.0 - alpha) + high * alpha
lowerCore := lowerCore * (1.0 - alpha) + low * alpha
3. Midpoint Reversal Confirmation
A bullish reversal requires a fresh lower extreme and a confirmed close back above the midpoint. A bearish reversal requires a fresh upper extreme and a confirmed close back below the midpoint.
4. Channel vs Trail Mode
Channel mode shows the upper, lower, and midpoint. Trail mode shows a single adaptive trailing reference derived from the current trend state.
Features
Adaptive upper/lower extremes: Persistent channel boundaries that update with new highs/lows
Reset interpolation: Stale levels drift toward current price instead of disappearing abruptly
Midpoint reversal logic: Reversal labels require closed-bar confirmation
Gradient channel fills: Upper and lower channel regions are lightly shaded
Optional trail mode: Converts the channel into a single adaptive stop reference
Top-right dashboard: Trend, mode, width, price position, reset age, and signal state
Alerts: Confirmed bullish and bearish reversal events
Input Parameters
Channel:
Reset Length: Bars allowed before an untouched extreme resets
Reset Alpha: Interpolation speed toward current price
Body Filter: Minimum candle body quality for reversal labels
Trailing Mode: Switches from full channel to trail display
How to Use This Indicator
Step 1: Use the channel boundaries as adaptive structural extremes.
Step 2: Watch for midpoint rejections after fresh extremes.
Step 3: Use trail mode when you want a simpler directional reference.
Step 4: Read price position and channel width in the dashboard before interpreting a reversal.
Indicator Limitations
Reversal labels can be early in strong breakout conditions
Very narrow channels require caution because small moves can cross the midpoint easily
The channel is adaptive context, not a complete trade system
Signals are confirmed on closed bars and do not use future references
Originality Statement
Extreme Reversal Channel is original in its combination of persistent extreme tracking, reset interpolation, midpoint rejection logic, optional trail mode, and compact dashboard output. It does not copy third-party source code.
Disclaimer
This open-source indicator is provided for educational and informational purposes only. It is not financial advice. Market conditions can invalidate reversal context, and risk management remains essential.
-Made with passion by jackofalltrades
Indicatore

Adaptive Flow II | AnonycryptousAdaptive Flow II | Anonycryptous
Description & user manual
Why this indicator is different
Most trend-following indicators use a fixed moving average. A 50-period EMA moves at the same speed whether the market is trending hard or grinding sideways. It cannot distinguish between a clean directional move and noise. It gives the same weight to a volatile consolidation as it does to a strong impulse. The result is signals that arrive late in trends and fire repeatedly during chop.
Adaptive Flow v2 works differently.
At its core is a Kaufman Adaptive Moving Average โ a moving average that measures the efficiency of price movement on every single bar and adjusts its own speed accordingly. When price is moving cleanly in one direction with low noise, the flow line accelerates toward price. When price is churning sideways with high volatility and no direction, the flow line nearly stops moving. It adapts. Automatically. Without requiring any manual intervention.
V2 builds significantly on this foundation. It adds five configurable stop modes, full market structure detection through BOS and CHoCH events, three independent signal filters, dynamic extension bands, a session-anchored VWAP, and an expanded dashboard. The result is a complete adaptive trend and structure system โ not just a trend indicator, but a context-aware trading framework.
Important notice
Adaptive Flow v2 generates signals based on technical indicator alignment.
These signals are not financial advice.
They do not predict the future.
They do not guarantee profitability.
All trading decisions are made entirely by the user.
Always manage your own risk. Always apply your own judgment.
1. Overview
Adaptive Flow v2 is an adaptive trend-following indicator built around a Kaufman Adaptive Moving Average with a configurable stop engine and full market structure detection.
What it includes:
- Kaufman Adaptive Moving Average rendered as a neon glow line with four stacked plot layers
- Five stop modes: ATR Trailing, Supertrend, Chandelier, Donchian, and Volatility Pivot
- Cloud fill between the flow line and the stop line, reflecting the current trend state
- Dynamic extension bands above and below the flow line at configurable ATR distance
- BOS and CHoCH structure detection with BOS confirmation filter
- Pivot high and low target lines that change color when broken
- EMA 200 macro trend filter with higher timeframe support
- ADX filter for directional environment confirmation
- Session filter to restrict signals to a configurable trading window
- Signal cooldown to prevent repeated triggering
- Session-anchored VWAP with daily and custom session modes
- Bar coloring reflecting the current trend state
- Three presets: default, fast, and smooth
- Live dashboard with 13 data rows
- Seven alert conditions
2. The flow line โ Kaufman Adaptive Moving Average
The flow line is the visual heart of Adaptive Flow. On every bar it calculates an Efficiency Ratio โ a measure of how directionally efficient price movement is relative to total volatility over the lookback period.
When the Efficiency Ratio is high โ price is moving strongly in one direction with low noise โ the flow line accelerates toward price. When the Efficiency Ratio is low โ price is ranging with high volatility โ the flow line nearly stops moving.
This adaptive behavior means the flow line naturally stays close to price during strong trends and pulls away only during genuine transitions. It is not a lagging average that mechanically follows price at a fixed delay. It responds to market character.
The flow line is rendered with four stacked plot layers โ a sharp core at full opacity and three progressively wider, more transparent layers behind it โ creating a neon glow effect that makes it visually distinct on any chart.
The noise filter adds an additional gate: KAMA only advances when the price displacement exceeds ATR ร threshold. This prevents the flow line from reacting to insignificant micro-movements during low-momentum conditions. Disable it for maximum responsiveness in strong trending environments.
3. Stop engine โ five modes
The stop engine calculates a dynamic stop level from the flow line. All five modes use the flow line as their reference point, not raw price. This means the stop inherits KAMA's adaptive smoothing before calculating any distance.
When the flow line crosses the stop level, the trend flips and a signal fires.
3.1 ATR Trailing (default)
The stop trails the flow line at a fixed ATR distance using a ratchet mechanism โ it only moves in the direction of the trend and locks in the floor or ceiling. This produces the characteristic smooth, flowing wave that follows the flow line closely. The cloud between the flow line and the stop gives a live view of the trend zone width. Default and recommended for most users.
3.2 Supertrend
ATR band above or below the flow line with ratchet mechanism. Similar to ATR Trailing but calculated differently, producing a more angular step-like stop line. More angular appearance, fewer intermediate flips.
3.3 Chandelier
The stop trails the highest or lowest flow line value over a configurable lookback window, then subtracts or adds ATR ร multiplier. Exits when the flow line has sustained a reversal beyond the lookback range. Better for trending markets where you want to trail a historical extreme rather than the current level.
3.4 Donchian
The stop follows the highest or lowest flow line value over a rolling window with no ATR component. Purely range-based. The stop level is exactly the rolling high or low of the flow line โ clean, simple, no volatility scaling.
3.5 Volatility Pivot
The stop anchors to the last confirmed pivot high or low of the flow line plus an ATR buffer. Structurally aware โ the stop sits at a level where the flow line previously reversed, not at an arbitrary distance. Best for traders who want the stop to respect structure rather than trail at a fixed distance.
4. Extension bands
When enabled, two bands are drawn above and below the flow line at ATR ร multiplier distance. They are not stop levels โ they are extension context. When price reaches the upper band during a bullish trend, it may indicate an overextended condition. When price compresses back toward the flow line after touching a band, it may indicate a pullback area. The bands move with the flow line and adapt to current volatility.
5. Market structure โ BOS and CHoCH
Adaptive Flow v2 includes a full market structure detection engine that runs alongside the adaptive trend engine.
Pivot highs and lows are detected on price using configurable left and right bar lookbacks. When price closes beyond a confirmed swing level, the indicator classifies the event as either a Break of Structure or a Change of Character.
A BOS fires when price closes beyond a swing level in the direction of the existing structural trend โ confirming continuation. Drawn as a dashed line
A CHoCH fires when price closes beyond a swing level against the existing structural trend โ signaling a potential reversal. Drawn as a solid line.
The BOS confirmation requirement prevents false reversals. When set to 1 (default), at least one BOS must confirm the current structural trend before a CHoCH can flip it. This blocks the common false reversal where a sharp pullback briefly closes beyond a swing level before the trend reasserts.
Pivot target lines are drawn automatically at the last confirmed pivot high and low. They extend to the right and change color when price closes through them.
6. Signal filters
Three optional filters are available. All three can be combined. A signal only fires when all active filters agree.
EMA 200 โ always active as a macro filter. Bullish signals only fire above the EMA 200. Bearish signals only below. Set the EMA 200 timeframe to a higher timeframe (1H or 4H) when trading on lower timeframes โ the native EMA 200 on a 1-minute chart only covers a few hours and provides no meaningful macro context.
ADX filter โ when enabled, signals only fire when ADX is at or above the configured threshold. Below this level the market is typically ranging and directional signals carry less weight. Default threshold of 20 removes the weakest trend environments.
Session filter โ when enabled, signals only fire during the configured trading window. Defined in HHMM-HHMM format using exchange timezone. Outside the window the flow line continues calculating but no new signals are generated.
Signal cooldown โ minimum bars between two signals in the same direction. Prevents repeated triggering during choppy conditions around the stop level.
7. VWAP
The VWAP provides a volume-weighted price reference that resets at the start of each session. It represents the average price paid weighted by volume โ a key reference for intraday value and institutional order flow.
Daily mode resets every calendar day. Custom mode anchors to a specific session defined by start and end times in HHMM-HHMM format. Timezone selection ensures correct boundary alignment.
8. Presets
Three preset configurations are available. Selecting a preset overrides the core KAMA calculation parameters.
Default โ balanced for swing trading on 4H and daily charts.
Adaptive length 14 | Fast constant 2 | Slow constant 30 | Noise threshold 0.3.
Fast โ built for scalping on 1 to 15 minute charts.
Adaptive length 6 | Fast constant 2 | Slow constant 15 | Noise threshold 0.15.
Shorter lookback for faster momentum shift detection. Lower noise threshold preserves full adaptive speed.
Smooth โ designed for position trading on daily and weekly charts.
Adaptive length 21 | Fast constant 3 | Slow constant 40 | Noise threshold 0.5.
Extended lookback demands sustained momentum before accelerating. Aggressive noise filtering for high-conviction reads only.
9. Dashboard
The dashboard displays the live state of all indicator components and updates on every bar.
Rows displayed:
- Adaptive Flow โ indicator name with trend-colored header and current timeframe
- Trend โ current flow line direction: bullish or bearish
- Stop Mode โ active stop mode in use
- Structure โ current structural direction from BOS/CHoCH logic
- EMA 200 โ whether price is above or below the macro filter
- VWAP โ whether price is above or below session value
- ADX โ current ADX value with confirmation indicator
- Session โ whether the session filter is active and the current bar is inside the window
- Noise Filter โ whether the noise gate is active
- Stop Distance โ distance from current close to stop level in ATR multiples and as a percentage
- Trend Bars โ number of bars the current trend has been active
- BOS Count โ number of confirmed BOS events in the current structural direction
- Signal โ last signal fired: buy, sell, CHoCH, BOS, or none
10. Settings reference
KAMA & Calculation
- Price Source: input for the flow line calculation
- Adaptive Length: efficiency ratio lookback period
- Fast Constant: smoothing speed during trending conditions
- Slow Constant: smoothing speed during ranging conditions
- Enable Noise Filter: toggle the displacement gate
- Noise Threshold: minimum ATR multiple required to advance the flow line
- Preset: Default, Fast, or Smooth
Stop Engine
- Stop Mode: ATR Trailing, Supertrend, Chandelier, Donchian, or Volatility Pivot
- ATR Length: volatility measurement period
- ATR Multiplier: distance scaling for the stop level
- Stop Lookback: rolling window for Chandelier and Donchian modes
- Pivot Buffer: ATR buffer for Volatility Pivot mode
Market Structure
- Show BOS / CHoCH: toggle structure detection
- Pivot Left / Right Bars: swing confirmation lookback
- Max Structure Levels: maximum lines shown on chart
- BOS Required Before CHoCH Flip: false reversal filter
- Show Pivot Target Lines: toggle automatic target lines
- Target Line Color and Width
Signal Filters
- EMA 200 Timeframe: leave empty for chart timeframe
- Show EMA 200: toggle line and label visibility
- EMA 200 Color
- Enable ADX Filter: toggle directional environment gate
- ADX Length and Threshold
- Enable Session Filter: toggle session-based signal restriction
- Session Window: HHMM-HHMM format
- Signal Cooldown: bars between signals
VWAP
- Session: Daily or Custom
- Timezone: UTC, Exchange, or major financial center timezone
- Session Window: for Custom mode
- Show VWAP: toggle line and label
- VWAP Color
Visuals
- Bull Color and Bear Color
- Cloud Transparency: fill between flow line and stop
- Show Extension Bands: toggle ATR extension bands
- Extension Band Multiplier: distance from flow line
- Show Reversal Signals: toggle triangle markers
- Color Candles: toggle bar coloring
- Candle Transparency
Dashboard
- Show Dashboard
- Size: Tiny, Small, or Normal
- Position: Top Left, Top Right, Bottom Left, or Bottom Right
11. How to use
11.1 Initial setup
Select a preset matching your primary trading style. Set the EMA 200 timeframe to a higher timeframe when trading on lower timeframes โ 60 for 1H, 240 for 4H. Set the VWAP to Daily or configure a custom session matching your primary market. Choose a stop mode โ ATR Trailing is the default and works well across all timeframes. Enable the session filter and ADX filter if you want stricter signal conditions.
11.2 Reading the chart
The flow line and its glow indicate the current adaptive trend. Green indicates a bullish environment. Red indicates a bearish environment. The cloud between the flow line and the stop shows the trend zone width โ a wide cloud indicates strong momentum, a narrowing cloud indicates the flow line is slowing.
The stop line is where the trend flips. A reversal signal fires when the flow line crosses it. Triangle markers appear at the stop line at the signal bar.
Extension bands show how far price has moved from adaptive value. Price at the upper band in a bullish trend may indicate overextension. Price returning toward the flow line after touching a band may offer a pullback reference.
BOS and CHoCH lines show structural context. Use them to understand whether the trend is in a confirmation phase (BOS firing repeatedly) or approaching a potential reversal (flow line slowing while price approaches a structural level).
11.3 Timeframe guide
1 to 5 minutes โ Fast preset. EMA 200 timeframe set to 60 or 240. Session filter recommended.
15 to 30 minutes โ Fast or Default preset. EMA 200 timeframe 240 or D.
1 hour to 4 hours โ Default preset. Native EMA 200 or D timeframe.
Daily and above โ Smooth preset. Native EMA 200.
11.4 Stop mode selection guide
ATR Trailing โ best for most situations. Smooth, flowing, closely follows the flow line.
Supertrend โ fewer flips, more angular. Good for lower timeframe noise reduction.
Chandelier โ suited for trending markets where you want to trail a recent high or low.
Donchian โ clean range-based stop with no ATR influence. Simple and transparent.
Volatility Pivot โ best when you want the stop at a structurally meaningful KAMA level.
11.5 Context
Adaptive Flow v2 identifies adaptive trend direction and market structure. It does not filter by fundamental events, news, or macro calendar. A bullish signal during a risk-off macro event may fail more often than one in a clear trending environment. Always apply your own context and judgment alongside the indicator output.
12. Alerts
Seven alert conditions are available:
- Bull Trend: flow line crosses above the stop level, EMA 200 above, all active filters passed.
- Bear Trend: flow line crosses below the stop level, EMA 200 below, all active filters passed.
- Any Trend Change: fires on either bull or bear trend signal.
- Bull CHoCH: market structure flips to bullish via Change of Character.
- Bear CHoCH: market structure flips to bearish via Change of Character.
- Bull BOS: bullish Break of Structure confirms trend continuation.
- Bear BOS: bearish Break of Structure confirms trend continuation.
All alerts include exchange, ticker, and interval in the message.
13. Disclaimer
This indicator is provided for educational and informational purposes only.
All outputs are based on historical price action calculations and do not guarantee future results.
Trading financial instruments involves significant risk of loss.
Past performance does not indicate future results.
Use at your own discretion.
Indicatore

Indicatore

Liquidity-Anchored Trailing Stop [BigBeluga]Liquidity-Anchored Trailing Stop is a comprehensive volatility and structural framework designed to provide a protective "heatmap" around price action. By fusing multi-layered ATR-based trailing logic with a dynamic Volume Profile, this indicator identifies where market momentum is accelerating and where institutional liquidity is "anchored."
Instead of a single line, this tool provides a graded risk-mitigation zone that adapts to market noise, ensuring you remain in the trend during healthy pullbacks while identifying the exact structural peaks where volume was most concentrated.
๐ต THE DUAL-ENGINE FRAMEWORK
Volatility Heatmap (Trailing Stop): The indicator calculates four distinct levels of trailing protection (Stop 1 through Stop 4). These are anchored to the trendโs direction and volatility, creating a "safety buffer" that narrows or expands based on the Average True Range (ATR).
Trend-Relative Volume Profile (Right Side): Unlike static volume profiles, this engine focuses specifically on the current trend segment. It visualizes the total relative volume transacted at each price bin since the last trend flip, highlighting where the real "meat" of the move occurred.
High Volume Nodes (HVNs): The script automatically detects peaks in the volume distribution. These High Volume Nodes represent structural anchors where the market has spent significant time, serving as high-probability zones for support or resistance.
๐ต CORE ARCHITECTURE
Liquidity Anchoring: By plotting HVN levels (Structural Peaks), the indicator shows you exactly where liquidity is sitting. When a trailing stop aligns with a volume peak, it creates a "Hard Anchor"โa level that is significantly harder for price to break through.
Adaptive Stop Logic: The trailing stops (ts1-ts4) use a ratchet mechanism. In an uptrend, the stops only move up; in a downtrend, they only move down. This prevents the "stop-loss creep" that often leads to giving back profits.
Dynamic Gradient Heatmap: The space between the four trailing bands is filled with a color-coded gradient. Saturated colors represent the core trend, while the outer bands represent the "exhaustion zone" where the trend is at risk of structural failure.
๐ต FEATURES
Granular Profile Rows: Fully adjustable vertical resolution (Profile Rows) allows you to define how detailed you want the volume distribution to be, ranging from broad structural areas to precise price levels.
Peak Level Detection: Horizontal structural lines are automatically drawn across the trend range at major HVNs, providing immediate visual targets and pivot points.
Smart Trend Labels: Clean UI labels (Bull/Bear) mark the exact bar where the trend flips and the volatility bands reset, ensuring you never miss a shift in market regime.
Visual Clarity Toggle: Includes options to show or hide the Volume Profile and Peak Levels, allowing you to use the tool as a pure volatility stop or a full-scale market structure map.
๐ต STRATEGIC APPLICATION
Trailing with the Heatmap: Use the innermost band (Stop 1) for aggressive scalping or tight management, and the outermost band (Stop 4) for macro trend following. If price closes beyond Stop 4, the trend is officially considered "broken."
HVN Confluence: Look for instances where the Trailing Stop aligns with a High Volume Node. These "Anchored Stops" are the most robust areas to place your actual exchange orders, as they are backed by both volatility and historical volume.
Volatility Breakouts: When the ATR bands (Heatmap) contract significantly and then price breaks out, look to the Volume Profile to see if the breakout is supported by a surge in volume at the new price bins.
Targeting Structural Peaks: In a trending market, use the volume peaks on the right side of the chart as natural take-profit targets or areas to expect temporary price stalls.
Liquidity-Anchored Trailing Stop transforms traditional stop-loss logic into a multi-dimensional map of risk and liquidity. By understanding where volume is anchored and how volatility is breathing, you can stay in winning trades longer and exit with precision when the structure finally fails. Indicatore

Conflux 4 | AnonycryptousConflux 4 | Anonycryptous
Description & user manual
Why this indicator is different
Most signal indicators fire on one condition. Price crosses a moving average. RSI hits a level. A candle closes above a line. One condition. One trigger. And because one condition alone is never enough, the signals come constantly โ in trends, against trends, in chop, in news spikes โ with no filter for whether the setup actually makes sense.
Conflux 4 works differently.
It does not fire on one condition. It requires four independent filters to agree at the same moment, in the same direction, before anything appears on the chart. Trend, momentum, volatility structure, and trend strength. All four. If one filter disagrees, nothing is drawn. Not a reduced signal. Nothing.
The result is an indicator that is quiet most of the time โ and deliberate when it speaks.
When a signal does appear, Conflux 4 does not just mark a dot and leave you to figure out the rest. It draws a complete trade block automatically: entry, stop, and up to four take profit levels. The stop trails dynamically after the first target is reached, moving to breakeven and continuing from there. The trade is managed visually until it resolves.
The dashboard shows the live state of every filter at all times, so you always know why a signal appeared โ or why it did not.
Important notice
Conflux 4 generates signals based on technical filter alignment.
These signals are not financial advice.
They do not predict the future.
They do not guarantee profitability.
All trading decisions are made entirely by the user.
Always manage your own risk. Always apply your own judgment.
1. Overview
Conflux 4 is a four-filter confluence signal indicator. A signal only fires when all four filters align simultaneously in the same direction. When that happens, a complete trade block is drawn including entry, stop, and take profit levels.
What it includes:
- Four-filter confluence engine: trend, momentum, volatility structure, and trend strength
- Four presets: scalp, daytrader, swing, and manual
- Three stop modes: Supertrend trailing, ATR cap, and fixed percentage
- Automatic trade block with up to four take profit levels
- Dynamic trailing stop that activates after TP1 and moves to breakeven
- Live dashboard showing the state of every filter in real time
- Configurable signal cooldown, bar coloring, and background shading
- Alerts for bullish and bearish signal events
2. The four filters
A signal is only valid when all four conditions align.
2.1 Trend filter โ VWMA and EMA alignment
Price must be above the volume weighted moving average and the fast EMA must be above the slow EMA for a bullish signal. Reverse for bearish. This confirms alignment with the prevailing macro trend before anything else is evaluated.
2.2 Momentum filter โ RSI threshold
RSI must be above the configured bullish threshold (default 55) for long signals, or below the bearish threshold (default 45) for short signals. This filters out setups forming in low-momentum environments where follow-through is less reliable.
2.3 Volatility filter โ Supertrend
The Supertrend indicator must confirm the same direction as the trend filter. Because Supertrend adapts to volatility using ATR, it naturally avoids triggering during minor fluctuations and choppy price action.
2.4 Trend strength filter โ ADX
ADX must be above the configured threshold (default 25) to confirm a directional environment. Below this level, price is typically ranging and confluence signals carry less weight. The ADX filter can be disabled if you prefer to evaluate trend strength manually.
If any single filter is not in agreement, no signal is generated.
3. Presets
Conflux 4 includes four preset configurations that adjust the stop mode and risk/reward levels to suit different trading styles.
-Scalp
Designed for short timeframes and futures scalping.
Stop mode: ATR cap.
Take profit levels: 0.5R / 1.0R / 1.5R / 2.0R.
-Daytrader
Designed for mid-timeframe trading on 15 minute to 1 hour charts.
Stop mode: Supertrend trailing.
Take profit levels: 0.5R / 1.0R / 2.0R / 3.0R.
-Swing
Designed for higher timeframe trading on 4 hour and daily charts.
Stop mode: Fixed percentage.
Take profit levels: 1.0R / 1.5R / 2.5R / 3.5R.
-Manual
Full control over all parameters. No preset overrides apply.
4. Stop modes
4.1 Supertrend
The stop follows the Supertrend line dynamically for the duration of the trade. This allows the stop to trail price as long as momentum holds.
4.2 ATR cap
The stop is based on the Supertrend level but capped at a maximum distance defined by an ATR multiplier. This prevents the stop from becoming too wide in volatile conditions.
4.3 Fixed percentage
The stop is placed at a fixed percentage below the entry for long trades and above the entry for short trades. The distance does not change after entry.
5. Trade block logic
When a signal fires, the trade block is drawn automatically:
- Entry line at the signal bar close
- Stop line at the calculated level based on the active stop mode
- Up to four take profit lines at configurable risk/reward ratios
- Visual zone shading between entry and stop, and between entry and each take profit
Trailing behavior:
Before TP1 is reached, the stop holds its initial position. After TP1 is reached, the stop moves to breakeven and begins trailing dynamically. The stop only moves in the direction of the trade โ it never moves against it.
The trade block remains active until the stop is hit or the Supertrend flips direction. After resolution, the block is cleared and the indicator is ready for the next setup.
6. Dashboard
The dashboard displays the live state of every filter and the current trade situation. It updates on every bar close.
Rows displayed:
- Trend โ overall direction from VWMA and EMA alignment
- VWMA โ whether price is above or below the VWMA
- EMA โ whether the fast EMA is above or below the slow EMA
- RSI โ current RSI value and whether the momentum threshold is met
- Supertrend โ current Supertrend direction
- ADX โ current ADX value and whether the trend strength threshold is met
- Confluence โ number of filters currently in agreement
- Stop mode โ active stop mode in use
- Last signal โ how many bars since the last signal fired
- Cooldown โ whether the cooldown period is still active
- Trade โ current trade state: none, long, or short
- TP progress โ which take profit levels have been reached
The dashboard header color reflects the current trend direction.
7. Settings
Trend filters
- VWMA length: period of the volume weighted moving average used as the primary trend filter
- Fast EMA / Slow EMA: periods of the two exponential moving averages used for secondary trend confirmation
- Show EMA lines: toggle EMA visibility on the chart
- EMA colors and line width: visual styling options
Momentum
- RSI length: period for the RSI calculation
- Bullish threshold: RSI must be above this level for a long signal (default 55)
- Bearish threshold: RSI must be below this level for a short signal (default 45)
Volatility and Supertrend
- ATR length: period for the ATR calculation used by the Supertrend
- Supertrend multiplier: sensitivity of the Supertrend โ higher values produce fewer flips
- Show Supertrend line, fill, and color options
ADX
- Enable ADX filter: toggle the trend strength requirement on or off
- ADX length: period for the ADX calculation
- ADX threshold: minimum ADX value required for a signal (default 25)
Signal settings
- Signal cooldown: minimum number of bars between two signals
- Show signals, signal text, background shading, and bar coloring
Trade block
- Show trade block: toggle the full trade block visualization
- Stop mode: Supertrend, ATR cap, or fixed percentage
- ATR cap multiplier and fixed percentage stop size
- Take profit levels: four configurable RR ratios
- Visual styling for stop, entry, and take profit lines
Dashboard
- Position: top left, top right, bottom left, or bottom right
- Size: tiny, small, or normal
- Visibility toggle
8. How to use
Select a preset or switch to manual and configure the filters to match your trading style and timeframe.
Choose a stop mode. Supertrend is best for trending markets where you want the stop to follow price. ATR cap limits the maximum stop size. Fixed percentage suits swing trades where a known maximum loss matters more than trailing.
Set your risk/reward take profit levels.
Monitor the dashboard. When all four filters align, the confluence count reaches four and a signal fires. The trade block is drawn automatically.
A green marker indicates a bullish signal. A red marker indicates a bearish signal.
The trade block shows the full setup from entry to each take profit level. Decision-making remains entirely with the user.
9. Notes
Low signal frequency is intentional. Four filters aligning simultaneously is a selective condition. Signals will not appear on every bar or even every session. That is by design.
Higher timeframes generally produce more stable signals. On lower timeframes the ADX threshold may need to be lowered or disabled to account for faster price structure.
Signals are more meaningful when they form at key structural levels such as support, resistance, or liquidity zones. Conflux 4 does not evaluate those levels โ that context comes from the trader.
The ADX threshold can be adjusted for markets that tend to range. Lowering it increases signal frequency. Raising it makes the filter more selective.
10. Disclaimer
This indicator is provided for educational and informational purposes only.
All outputs are based on historical price action calculations and do not guarantee future results.
Trading financial instruments involves significant risk of loss.
Past performance does not indicate future results.
Use at your own discretion.
Indicatore

ATR Step Trailing Stop Positioning ToolThis indicator is an ATR-based trailing stop positioning tool.
It is not designed to generate buy or sell signals. Its purpose is to help traders visualize possible trailing stop levels based on volatility.
How it works:
The indicator calculates a stepped trailing level using the ATR distance from the high or low of the last closed candle.
For long-position management, the stop level can be positioned below price using the candle low and an ATR-based distance.
For short-position management, the stop level can be positioned above price using the candle high and an ATR-based distance.
Because the calculation is based on the last closed candle, the level is designed to behave like a step-style trailing reference instead of constantly moving tick by tick.
How this is different from a standard ATR trailing stop:
Many ATR stop indicators use a continuous trailing line or a single shared configuration for both long and short conditions.
This version is focused specifically on stop placement structure. It allows the trader to visualize ATR-based stop levels as stepped references from the most recent completed candle.
Another practical difference is that traders can add two instances of the indicator to the same chart. For example, one instance can be adjusted for long trailing stop management and another for short trailing stop management. By changing the visibility or transparency settings, it is possible to show only the positive or negative side of each instance and compare different ATR lengths or ATR multipliers for long and short positioning.
This makes the tool useful when a trader wants different trailing stop behavior for long and short positions instead of using one universal setting.
Possible use cases:
* Visualizing ATR-based trailing stop zones
* Managing open trades with a volatility-adjusted stop reference
* Comparing different ATR lengths or multipliers
* Separating long-side and short-side stop logic
* Studying how price behaves around volatility-based stop levels
Important limitation:
This indicator does not predict direction. It does not provide entry signals, exit signals, buy signals, or sell signals. The plotted levels are only a technical reference for trailing stop positioning based on ATR and closed candle structure.
Traders should combine this tool with their own entry logic, market structure analysis, risk management rules, and broader trading plan.
Indicatore

Prism Strategy## Prism Strategy: Multi-Dimensional Trend & Structural Flow
**Prism Strategy** is a high-precision trend-following and momentum execution engine designed to capture institutional-grade moves while providing a comprehensive structural analysis of the market. It integrates a dynamic EMA Ribbon, RSI momentum filtering, automated Fibonacci levels, and a proprietary "Structural Wall" logic to determine the most logical points for entry and risk management.
### 1. Trend Identification (The EMA Ribbon)
The strategy utilizes a 12-layer EMA Ribbon to identify trend alignment.
* **Short-Term Stack:** 3, 5, 8, 10, 12, 15 EMAs.
* **Long-Term Stack:** 30, 35, 40, 45, 50, 60 EMAs.
A signal is only considered valid when the ribbon is in a **Full Stack** configuration (perfectly ordered from fastest to slowest), ensuring the trend is established across multiple time-cycles.
### 2. Momentum Filtering
To prevent "whipsaws" in low-volatility environments, the strategy incorporates **RSI (14)**.
* **Long Positions:** Require RSI > 50.
* **Short Positions:** Require RSI < 50.
This ensures that the price is not just trending, but moving with sufficient velocity.
### 3. The "Structural Wall" Logic
One of the most advanced features of this strategy is the **Structural Wall Analysis**. The algorithm identifies the strongest confluence between:
* **Dynamic Support/Resistance:** The Base EMA (12).
* **Static Support/Resistance:** Auto-calculated Fibonacci Retracement levels (0.0 to 1.618).
The "Wall" is formed by selecting the maximum (for Longs) or minimum (for Shorts) of these two values, creating a "Hard Floor/Ceiling" that acts as the primary anchor for the trailing stop.
### 4. Dynamic Risk Management (ATR-Based)
* **Stop Loss & Take Profit:** Initial levels are calculated using **ATR (Average True Range)** multiplied by a user-defined factor (default 1.5x for stops and a 2.0 RR ratio).
* **Intelligent Trailing Stop:** The strategy tracks the "Structural Wall" and updates the stop loss in real-time. It only moves in the direction of the trade (up for long, down for short) to lock in profits while giving the price enough room to breathe based on current volatility.
### 5. Integrated Execution Dashboard
The built-in UI provides real-time data for professional monitoring:
* **System Mode:** Displays current trend bias (Bullish/Bearish/Neutral).
* **Entry Advice:** An AI-driven logic that evaluates if the current price is "Ideal," "Overextended," or if the "Risk > Reward" is currently unfavorable for new entries.
* **Fibonacci Alerts:** Warns the user when the price is approaching a major Fibonacci level (โ ๏ธ Alert) to prepare for potential reversals or pullbacks.
### 6. Exit Logic
The strategy employs a **Unified Exit Engine** based on three criteria:
1. **Hard Stop/TP:** Triggered if price hits the ATR-based levels.
2. **Structural Violation:** Triggered if the "Trailing Stop" (Structural Wall) is breached.
3. **Trend Break:** Triggered if the EMA Ribbon loses its "Full Stack" alignment, indicating a loss of trend momentum.
---
### **How to Use**
* **Timeframes:** Optimized for trend-rich environments (5m, 15m, 1h, and Daily).
* **Markets:** Effective on liquid assets including Equities, Forex, and Crypto.
* **Entry:** Look for "IDEAL ENTRY" status on the dashboard for the highest probability setups.
---
**Disclaimer:** *Trading involves significant risk. This strategy is an analytical tool and does not guarantee profits. Past performance is not indicative of future results. This is not investment advice; it is for educational purposes only.* Strategia

Haar Wavelet RSI [Jamallo]Author's Note
This is the oscillator companion to the Haar Wavelet Range Filter. Both indicators share the same MODWT Haar wavelet foundation, creating a synergistic effect when used together โ trend and momentum derived from the same mathematical decomposition of price.
Introduction
The Haar Wavelet RSI is a momentum oscillator that replaces the standard price-difference input of a traditional RSI with wavelet detail coefficients derived from a Maximal Overlap Discrete Wavelet Transform (MODWT) with a Haar basis. Instead of measuring bar-to-bar price change, it measures momentum at a specific frequency scale โ filtering out the noise above and below that scale before the RSI calculation even begins.
How It Works
MODWT Haar Wavelet Decomposition
The script decomposes hl2 through up to 5 wavelet levels using a shift-invariant Haar transform. At each level, the detail coefficients capture the local price delta at that specific scale โ Level 1 is 2-bar momentum, Level 3 is 8-bar momentum, Level 5 is 32-bar momentum. These detail coefficients become the input to the RSI in place of raw price change, meaning the oscillator is measuring directional energy at a single isolated frequency rather than the full noisy price series.
Wavelet RSI Calculation
The selected detail coefficient is split into its upward and downward components, smoothed with Wilder's RMA, and fed into the standard RSI formula. The math is identical to a conventional RSI โ the only difference is what it is measuring. Because the detail coefficients are already frequency-isolated, the resulting RSI is inherently cleaner than applying RSI to raw price.
Adaptive Deadband Step-Hold
The wavelet RSI output is then passed through an adaptive deadband filter. The threshold is self-derived from the RSI's own recent volatility โ a short rolling average of absolute RSI changes โ scaled by the deadband multiplier. The RSI only updates when it departs from its held value by more than this threshold. Below the threshold it holds flat. This eliminates the continuous micro-oscillation that makes standard RSI difficult to read on noisy bars, producing a stepped line that moves with conviction or not at all.
Closing
This is not a standard RSI with cosmetic changes. The wavelet decomposition fundamentally changes what the oscillator is measuring โ momentum at a defined frequency scale rather than raw bar-to-bar noise. The decomposition level is the most important setting: lower levels suit faster timeframes and shorter momentum cycles, higher levels filter more aggressively and are better suited to swing-level momentum reads. Indicatore

Anchored Value Distribution Oscillator (Zeiierman)โ Overview
Anchored Value Distribution Oscillator (Zeiierman) is a structure-driven oscillator that models price as a dynamic value distribution, then measures where price is positioned within that structure to reveal balance, imbalance, and shifting market conditions.
Instead of relying purely on price momentum, the indicator builds a rolling, volume-weighted distribution of price over time. From this structure, it extracts key reference levels such as the value center, high/low distribution bands, and peak activity zones. These are then used to normalize the price into a bounded oscillator.
Alongside the distribution, the script constructs an adaptive trailing anchor that reacts to structural shifts and volatility. The oscillator combines both the structural distribution and the adaptive anchor into a single positioning score, producing a contextual view of trend, extension, and balance.
The result is an oscillator that reflects not just direction, but where price sits within its evolving value landscape.
โ How It Works
โช Distribution Engine (Value Model)
The core of the indicator is a rolling value distribution built from price and volume.
Each bar contributes to a log-scaled price histogram, where:
price ranges are segmented into rows
volume is distributed across those rows
candle bodies and wicks are weighted differently
older data gradually decays over time
This produces a continuously updating view of:
Point of Control (vp)
Value High / Value Low (vh / vl)
Outer extremes (xh / xl)
Distribution center (cen)
Unlike a static volume profile, this model evolves with the market and adapts to both recent and historical activity.
โช Adaptive Anchor (Trend Engine)
On top of the distribution, the script builds an adaptive trend anchor (anc).
The anchor is derived from a structural base:
blended from the distribution center and peak activity
offset using volatility (ATR)
constrained to trail price in the active direction
The anchor flips direction when the price crosses it, and then trails using a volatility-adjusted distance.
This creates a structure-aware trend model that behaves similarly to a trailing stop, but is grounded in value distribution rather than raw price movement.
โช Normalized Positioning Model
The oscillator converts price into a normalized position within the distribution.
Two independent scores are calculated:
Position relative to the adaptive anchor (scAnc)
Position relative to the value distribution (scVp)
Each score maps price into a bounded range:
-50 โ extreme downside
-25 - 20 โ fair value
+50 โ extreme upside
These scores are then combined into a single output using a weighted blend.
A confidence factor reduces the distribution score's contribution when it disagrees with the anchor, ensuring cleaner signals in conflicting conditions.
โช Smoothed Oscillator Output
The final oscillator (outAvg) is a smoothed combination of:
trend-aware positioning (anchor)
structure-aware positioning (distribution)
โ How to Use
โช Read Position Relative to Value
Use the oscillator to understand where the price sits within its value distribution:
Above 25 โ price is positioned above fair value
Below -25 โ price is positioned below fair value
Near extremes (ยฑ50) โ price is extended relative to structure
This helps distinguish between:
continuation conditions
mean reversion zones
balanced market states
โช Follow the Adaptive Trend Anchor
The trailing anchor provides a clear trend reference:
Price above anchor โ bullish regime
Price below anchor โ bearish regime
Anchor flips โ potential regime shift
โ Settings
Lookback โ Controls how much historical data is used to build the value distribution. Higher values produce smoother structure, while lower values increase responsiveness.
Canvas Pad โ Expands the distribution range to include more extreme price levels. Increasing this captures broader moves but reduces precision.
Rebuild Drift โ Determines how much the distribution can drift before being recalculated. Lower values rebuild more frequently, higher values allow more continuity.
Signal Length โ Controls the smoothing of the signal line. Higher values reduce noise but increase lag.
Profile Center Bias โ Blends between the value distribution center and the point of control to define the structural base. Higher values anchor the trail to the broader distribution center, while lower values make it follow peak activity more closely.
Trail Acceleration โ Controls how quickly the trailing stop tightens as the price accelerates. Higher values make the trail react more aggressively to impulsive moves, reducing lag during strong trends.
Max Trail Acceleration โ Limits how much the acceleration can compress the trailing distance. Higher values allow the stop to tighten more during rapid expansion, while lower values keep behavior closer to the original, smoother trail.
-----------------
Disclaimer
The content provided in my scripts, indicators, ideas, algorithms, and systems is for educational and informational purposes only. It does not constitute financial advice, investment recommendations, or a solicitation to buy or sell any financial instruments. I will not accept liability for any loss or damage, including without limitation any loss of profit, which may arise directly or indirectly from the use of or reliance on such information.
All investments involve risk, and the past performance of a security, industry, sector, market, financial product, trading strategy, backtest, or individual's trading does not guarantee future results or returns. Investors are fully responsible for any investment decisions they make. Such decisions should be based solely on an evaluation of their financial circumstances, investment objectives, risk tolerance, and liquidity needs.
Indicatore

Chandelier Exit Reaction Zones + Fib LevelsAt its core, this script is built on a Chandelier Exit-style ATR stop-and-flip engine. The difference is that instead of stopping at a single trailing stop, it expands that framework into a full ladder: the multiplier 10 level becomes the primary anchor, the opposite-side multiplier 10 level becomes the extension anchor, and the space between them is mapped with a fib channel. Optional Chandelier Exit multipliers of 5.0 and 7.5 reaction zones add another layer of context for tracking how price behaves before it reaches the full multiplier 10 stretch.
The main idea is simple: markets often react when price gets extended, but not every extension behaves the same way. Sometimes price reaches an ATR threshold and reverses. Sometimes it reaches the same area and continues. This script is meant to organize that behavior into a structure you can read quickly. The Chandelier Exit engine provides the directional framework, while the ladder, fib channel, and reaction zones help show where price is stretched, where it is progressing through the channel, and where a reaction may be worth paying closer attention to.
At a high level, the script does three things. First, it identifies the current active ATR 10 side and the opposite ATR 10x extension. Second, it divides that space into a structured ladder using fib-based levels. Third, it can overlay ATR 5.0 and 7.5 reaction zones so you can see when price is pressing into an intermediate reaction area instead of only waiting for the full ATR 10 test.
A few examples of how to read it:
โก๏ธIn a bullish state, the active ATR 10 line acts as the lower anchor and the ATR 10x extension becomes the upper stretch line. The fib ladder shows how far price has progressed through that channel.
โก๏ธIn a bearish state, the structure flips. The active ATR 10 line becomes the upper anchor and the ATR 10x extension becomes the lower stretch line.
The optional ATR 5.0 and 7.5 reaction zones add another layer of context. They are useful when price is not yet at the full ATR 10 extreme but is already entering a part of the move where reaction risk is increasing.
โก๏ธThe reaction zones table is there to make the state logic visible. It shows the current main multiplier's direction, the latest flip state, the 5.0 / 7.5 reaction directions, and whether those reaction branches are actively contributing to the fill.
This is not meant to predict reversals by itself. The way I use it is more practical: it helps frame where price is stretched, where a move is still developing, and where a reaction may deserve closer attention. The value here is the structure, not a guaranteed signal.
The script also includes state-aware touch alerts for the active ATR 10 level and the ATR 10x extension. Those alerts are not entry signals on their own. They are meant to notify you when price has reached an area that may deserve a decision: continuation, reaction, or invalidation.
Bar Replay
Bar Replay is especially useful with this script. Stepping through price one bar at a time makes it much easier to see how the multiplier 10 ladder flips, how the fib channel reorients, and when the 5.0 / 7.5 reaction zones begin to matter. That can help traders understand the structure in motion instead of only judging it from a finished chart.
Confluence
This script is not meant to be used in isolation. It works best as a structural framework alongside other tools such as RSI, MACD, trend context, volume, and support/resistance. The ladder and reaction zones help define where price is stretched; confluence helps decide whether that stretch is more likely to lead to continuation, reaction, or reversal.
This is an open-source tool, so the goal is transparency and flexibility. Traders can keep it simple and use only the main ATR 10 ladder, or add the fib channel, reaction zones, candle coloring, alerts, and table for more context. The core idea stays the same either way: use a Chandelier Exit-style ATR framework to map stretched price conditions with a consistent structure.
Here's a few additional chart examples:
Indicatore

Sigmoid Transition Trailing Stop [LuxAlgo]The Sigmoid Transition Trailing Stop indicator provides a dynamic risk management tool that utilizes a mathematical sigmoid function to smoothly adjust stop levels when price trends become overextended. Unlike traditional trailing stops that move linearly or remain static until a new high/low is formed, this script proactively "catches up" to price during periods of high momentum using a non-linear transition.
๐ถ USAGE
The indicator functions as a trend-following stop-loss or take-profit level. When the price crosses the trailing stop, the trend direction flips, and a new stop is calculated based on the ATR-derived distance.
The unique behavior of this tool occurs during "Adjustment" phases. When the distance between the price and the trailing stop becomes too wide (exceeding the initial ATR multiplier), the script triggers a sigmoid transition. During this phase:
The trailing stop line becomes solid (0% transparency) to indicate an active adjustment.
The stop level moves towards the price following an S-curve, providing a smooth acceleration and deceleration of the stop level.
The adjustment concludes once the sigmoid duration is reached or if the stop gets too close to the price (defined by the Min Distance setting).
๐น Visual Cues
Green Line/Fill: Indicates a bullish trend where the stop is below the price.
Red Line/Fill: Indicates a bearish trend where the stop is above the price.
Solid Line: The sigmoid adjustment is currently active, moving the stop closer to price.
Transparent Line: The stop is in its standard state, maintaining its level or trailing highs/lows.
๐ถ DETAILS
The core of the script is the sigmoid function, which creates a natural-looking transition between two price levels. Mathematically, it maps a linear time input (bars passed) to an S-shaped curve between 0 and 1.
The logic ensures that the "trailing" property is never violated; even during a sigmoid transition, the stop level can only move in the direction of the trend (up for bullish, down for bearish). If the price moves against the trend during an adjustment, the stop will simply hold its level until the price moves favorably again or the adjustment period ends.
๐ถ SETTINGS
๐น General Settings
ATR Length: The lookback period used to calculate the Average True Range, which determines the volatility-based distance of the stop.
ATR Multiplier: The base distance (in ATR units) used when the trend first flips.
Sigmoid Length (Bars): The number of bars over which the sigmoid transition occurs once triggered.
Sigmoid Amplitude (ATR Units): The maximum distance the stop is allowed to travel toward the price during an adjustment phase.
Min Distance (ATR Units): A safety buffer that prevents the sigmoid adjustment from moving the stop too close to the current price, preventing premature exits.
Indicatore

Indicatore
