MLP - BTC Breakout Probability [Deep Learning] [Open Source]I trained a single Multilayer Perceptron on 13 years of Bitcoin price history and open-sourced the result. Not because it's perfect, but because the idea is worth sharing.
The concept is simple.
Most breakout strategies are rule-based. Fixed levels, static conditions. This one is different, instead of predicting direction, the model learned the distribution of Bitcoin's daily price moves. You pick a threshold, it gives you the probability. Same model, any level.
How to use it
Pick a percentage threshold , by doing that you're asking the model to evaluate. When price breaks that level and the model is showing meaningful confidence, a label is shown on the chart.. Daily only. BTC only.
Under the hood
A lightweight Multilayer Perceptron (MLP) trained on ~4,700 daily candles of raw OHLC data from May 2009 to May 2022 . The architecture is two hidden layers (16→8), ReLU activations throughout, and a sigmoid output that squashes the result into a clean 0–1 probability score. ReLU keeps the internal representations sparse and non-linear, sigmoid makes the output as a probability.
What makes this interesting is that the model didn't just learn a raw number, it learned the underlying distribution of Bitcoin's daily price moves. That's what allows a single model to answer probability questions across different thresholds rather than being hardcoded to one fixed level.
The output isn't a prediction, it's a calibrated belief about where price is likely to go, derived from 13 years of market structure.
Honest limitations
Fat tails eat this model alive. The features are correlated and the model has no concept of liquidity. It underestimates the extremes.
Daily timeframe only. Bitcoin only. Long only.
This was built as a personal project, mostly for fun and to serve as a working example of how ML concepts can be applied to market data.
Disclaimer
This indicator is provided for educational and informational purposes only. It does not constitute financial advice, trading recommendations, or a guarantee of future results. Past performance does not predict future returns. You alone are responsible for your trading decisions. Always test thoroughly in a simulated environment before trading with real capital. Indicator

Fractal Exhaustion Band [QuantAlgo]🟢 Overview
The Fractal Exhaustion Band is a trend-following indicator that replaces the fixed ATR multiplier common to most adaptive bands with the Fractal Dimension Index, scaling the buffer width in real time based on how efficiently price is consuming its recent range. Additionally, an extremum tracker accumulates swing highs and lows since the last confirmed flip to form an outer Band Edge, giving traders a structured range to position within the trend, identify exhaustion near its boundaries, and treat extensions beyond the edge as potential deviation signals ahead of a directional flip across any instrument or timeframe.
🟢 How It Works
The core methodology is built around three sequential stages: a fractal dimension calculation that quantifies the structural quality of recent price movement, a dynamic buffer derived from that measurement, and a ratcheting trend line that advances only when market conditions justify it.
First, the Fractal Dimension Index (FDI) is calculated by comparing the total path length price has travelled over the lookback window against the straight-line distance between its highest and lowest point. A value near 1 indicates clean, efficient trending. A value near 2 indicates erratic, space-filling movement. The ratio is log-normalised by the window size to keep it comparable across different FDI Period settings:
fdi = high_ - low_ > 0 ? (math.log(len) - math.log(high_ - low_)) / math.log(power) : 0
Next, the FDI is fed directly into the buffer calculation as a scaling factor on top of the Band Width Multiplier and a 10-period ATR. This means the buffer is never fixed; it inflates when price behaviour is erratic and compresses when price is trending with conviction:
dynamic_mult = sensitivity * (1 + fdi)
buffer = atr * dynamic_mult
The trend line then ratchets in the direction of the current trend, but only on bars where the FDI is below 1.5. This gate prevents the line from being dragged by price during high-fractal-dimension conditions, even if price has not yet breached the buffer threshold. A trend flip is only registered when price closes beyond the buffer on the opposite side:
if fdi < 1.5
trend_line := math.max(trend_line, close - buffer)
Finally, an extremum tracker accumulates the running high or low since the last confirmed flip, forming the outer Band Edge. A midline is derived as the average between this extremum and the trend line, creating a three-layer structure that encodes both the structural anchor of recent price extremes and the adaptive trend line beneath it:
ex := trend_dir != trend_dir ? (trend_dir == 1 ? high : low)
: trend_dir == 1 ? math.max(nz(ex , high), high)
: math.min(nz(ex , low), low)
mid = math.avg(ex, trend_line)
🟢 Signal Interpretation
▶ Bullish Trend (Band Rising with Bullish Colour): When price moves upward with sufficient efficiency to produce a low FDI reading and close above the trend line's buffer threshold, the trend direction flips to bullish and the entire band shifts to the bullish colour. From that point, the Fractal Line ratchets upward on each bar where the FDI remains below 1.5, while the extremum tracker accumulates successive highs to form the outer Band Edge above. The flat segments visible in the band reflect bars where the FDI gate suppressed movement, while upward steps reflect bars where trending conditions were confirmed.
Within the bullish band, the Fractal Line and Band Edge define a structured trading range. Price oscillating between the two represents normal trend continuation behaviour, and pullbacks toward the Fractal Line can be treated as higher-probability long entries with the trend, using the Fractal Line itself as the logical invalidation level. The Band Mid serves as a directional gauge within that range; price holding above it reflects stronger momentum, while price drifting below it signals weakening conviction worth monitoring. When price pushes into the Band Edge zone and begins interacting with the accumulated swing highs, treat that as an exhaustion area rather than a continuation signal. Longs initiated near the Band Edge carry elevated risk of a short-term mean reversion back toward the Fractal Line. If price then extends meaningfully beyond the Band Edge, treat the extension as a deviation from the established structure. A deviation of this kind, particularly when accompanied by a rising FDI indicating deteriorating trend quality, is a preparatory signal to begin tightening long exposure and watching for the Fractal Line to be breached on the downside, which would confirm the bias flip to bearish.
▶ Bearish Trend (Band Declining with Bearish Colour): When price moves downward with sufficient efficiency to produce a low FDI reading and close below the trend line's buffer threshold, the trend direction flips to bearish and the band shifts to the bearish colour. The Fractal Line ratchets lower on each bar where the FDI gate permits, while the extremum tracker accumulates successive lows to form the outer Band Edge below. As with the bullish state, the filter holds its last value on bars where fractal dimension is elevated, and the direction state remains unchanged on those bars.
Within the bearish band, the same structural logic applies in reverse. Price oscillating between the Fractal Line above and the Band Edge below represents normal bearish continuation, and bounces toward the Fractal Line can be treated as higher-probability short entries with the trend, using the Fractal Line as the invalidation level. The Band Mid again acts as a momentum gauge; price holding below it indicates sustained selling pressure, while recovery above it suggests the downtrend is losing conviction. When price pushes into the Band Edge zone and interacts with the accumulated swing lows, treat that region as exhaustion rather than confirmation of further downside. Shorts initiated near the Band Edge carry elevated mean-reversion risk back toward the Fractal Line. If price extends beyond the Band Edge to the downside, treat that extension as a structural deviation. A deviation paired with a rising FDI is a signal to begin reducing short exposure and watching for an upward breach of the Fractal Line, which would confirm the directional flip back to bullish.
🟢 Features
▶ Preconfigured Presets: Three parameter sets cover a range of trading styles and timeframes. "Default" delivers balanced noise filtering suited to swing trading on 4-hour and daily charts. "Fast Response" tightens the buffer and shortens the fractal measurement window for intraday and scalping use on 1-minute to 1-hour charts, producing earlier trend flips in response to smaller directional moves. "Smooth Trend" widens the buffer and extends the measurement window for position trading on daily and weekly charts, requiring a more sustained and efficient directional move before a trend flip is registered.
▶ Built-in Alerts: Three alert conditions support automated monitoring of trend transitions. Bullish Trend fires on the first bar where trend direction flips from bearish to bullish. Bearish Trend fires on the first bar where trend direction flips from bullish to bearish. Any Signal Change triggers on either transition for traders who want a single unified alert regardless of direction. All alerts include the exchange, ticker, and timeframe in the message for immediate context.
▶ Visual Customisation: Six colour presets (Classic, Aqua, Cosmic, Cyber, Neon, and Custom) provide coordinated bullish and bearish colour pairings suited to different chart themes and personal preferences. Selecting Custom exposes independent colour pickers for full manual control over both states. The three-layer band fill uses graduated transparency across the outer edge, midline, and trend line zones to clearly distinguish structural from adaptive components at a glance. Optional bar colouring tints price candles with the active trend colour using a configurable transparency level, and optional background colouring extends the trend state tint across the full chart pane at a separately configurable transparency.
Indicator

Indicator

Asymmetric Volatility Trend Line [QuantAlgo]🟢 Overview
Asymmetric Volatility Trend Line is a trend-following indicator built on adaptive standard deviation thresholds rather than fixed bands or moving average crossovers. It quantifies the statistical volatility of recent price movement to determine asymmetric conditions for trend continuation versus trend reversal, then uses those conditions to anchor a dynamic trend line that adjusts position in response to confirmed directional moves, helping traders distinguish between genuine breakouts and noise-driven fluctuations across every timeframe and market.
🟢 How It Works
The foundation of the indicator is a rolling standard deviation applied to the selected price source over a configurable lookback window, scaled by a threshold multiplier to produce the volatility boundary used in all trend logic:
vol_threshold = ta.stdev(src, lookback) * threshold_mult
This threshold is intentionally asymmetric in application. When the trend line is in a bullish state, a smaller fraction of the threshold (0.5x) is required for price to confirm continuation, while a full threshold breach in the opposite direction is needed to trigger a reversal. The same asymmetry applies in reverse during bearish states:
if trend_dir >= 0
if src > trend_line + vol_threshold * 0.5
trend_line := math.max(trend_line, src - vol_threshold * 0.25)
trend_dir := 1
else if src < trend_line - vol_threshold
trend_line := src + vol_threshold * 0.25
trend_dir := -1
This design means continuation requires less evidence than reversal. A directional move only needs to exceed half the volatility threshold to sustain the current trend, but must overcome the full threshold to flip it. The 0.25x offset applied when repositioning the trend line keeps it anchored within the volatility envelope rather than jumping directly to price, producing a smoother line that does not overreact to a single bar.
When a reversal is confirmed, the trend line is placed on the opposite side of price at a quarter-threshold distance, giving it room to develop without immediately triggering another flip:
trend_line := src + vol_threshold * 0.25 // repositioned on bearish flip
trend_dir := -1
Direction state is tracked through two integer variables, with reversal conditions derived from comparing the current and prior bar states:
turned_bullish = trend_dir == 1 and trend_dir == -1
turned_bearish = trend_dir == -1 and trend_dir == 1
is_reversal = trend_dir != prev_dir and bar_index > 0
🟢 Signal Interpretation
▶ Bullish Trend (Green): When price closes above the trend line by more than half the volatility threshold, the indicator enters bullish mode with green colouring applied across the trend line, gradient fill, and reversal marker (⦿). This state persists until price closes below the trend line by the full volatility threshold, allowing normal pullbacks to occur without triggering a direction change.
▶ Bearish Trend (Red): When price closes below the trend line by more than half the volatility threshold, the indicator enters bearish mode with red colouring across all visual elements. A full threshold breach to the upside is required to exit this bearish state.
🟢 Features
▶ Preconfigured Presets: Three parameter sets cover different trading approaches. "Default" targets swing trading on 4-hour and daily charts with moderate threshold sensitivity. "Fast Response" reduces the volatility barrier and shortens the lookback for intraday charts where the indicator needs to adapt to shorter-duration moves. "Smooth Trend" raises the reversal threshold substantially for position trading on daily and weekly timeframes, where the cost of a false flip is higher than the cost of a delayed one. Selecting a preset overrides the individual multiplier and lookback inputs.
▶ Built-in Alerts: Three alert conditions cover all directional states. "Bullish Trend Signal" fires on the bar where the trend direction flips from bearish to bullish. "Bearish Trend Signal" fires on the bar where it flips from bullish to bearish. "Any Trend Change" combines both into a single condition for traders who want a unified notification regardless of direction.
▶ Visual Customisation: Six colour presets (Classic, Aqua, Cosmic, Cyber, Neon, and Custom) apply coordinated bullish and bearish colour schemes across the trend line, gradient fill, reversal markers, and optional bar and background colouring. Bar colouring tints price candles with the active trend colour at a configurable transparency level, and background colouring extends the directional tint across the full chart pane. Both are disabled by default and controlled independently.
Indicator

Adaptive Friction Filter (AFF) [QuantAlgo]🟢 Overview
The Adaptive Friction Filter (AFF) identifies trending market conditions by applying a physics-inspired friction model to price movement. Rather than smoothing price through fixed averaging, it introduces a dynamic noise threshold derived from recent market volatility, which means price must generate enough force to overcome this threshold before the filter moves at all. Once breached, the filter closes the gap at a configurable rate, producing a step-like trend line that holds steady through noise and responds decisively to genuine directional moves. This allows traders to distinguish between meaningful trend continuation and low-conviction chop across any instrument or timeframe.
🟢 How It Works
The AFF's core methodology is built around a two-stage mechanism: a volatility-derived friction threshold that gates filter movement, and a catch-up scalar that governs how much of the gap the filter closes on each bar once that threshold is exceeded.
First, the friction threshold is computed as the simple moving average of absolute bar-to-bar price changes over the configured lookback window, scaled by the friction coefficient. This makes the threshold inherently self-adjusting; it widens during volatile conditions and contracts during quiet ones, without requiring any manual recalibration:
friction = ta.sma(math.abs(src - src ), lookback) * friction_mult
Next, the raw displacement between current price and the filter's last position is evaluated as force. The filter only advances if this force exceeds the friction threshold. When it does, the filter moves toward price by a fraction of the gap governed by the catch-up scalar, rather than closing the full distance immediately, producing a controlled and progressive response:
force = src - aff_line
aff_line := math.abs(force) > friction ? aff_line + force * catchup_scalar : aff_line
Trend direction is then resolved by comparing the current filter value to its prior bar value. The direction state persists when the filter is flat, so no transition is registered on bars where the filter does not move:
trend_dir := aff_line > aff_line ? 1 : aff_line < aff_line ? -1 : trend_dir
Finally, the filter is rendered as two overlapping plots at the same value: a step-line that traces the filter's path and a circle overlay positioned at each bar's filter value. The circles serve a visual purpose, reinforcing the current filter level at each step and making it easier to read the filter's position at a glance, particularly during flat periods where the step-line alone can be harder to track. Together they produce a dotted step appearance that improves legibility across different chart zoom levels and timeframes.
🟢 Signal Interpretation
▶ Bullish Trend (AFF Line Rising with Bullish Colour): When price generates enough upward force to exceed the friction threshold, the filter begins stepping higher and the line shifts to the bullish colour. The step-line rendering makes the transition visually clear; flat segments indicate bars where force was insufficient to move the filter, while upward steps reflect bars where it was. The bullish trend state persists until force in the downward direction is large enough to push the filter lower, at which point trend direction flips and the line shifts to the bearish colour.
▶ Bearish Trend (AFF Line Declining with Bearish Colour): When price generates enough downward force to exceed the friction threshold, the filter begins stepping lower and shifts to the bearish colour. As with the bullish state, the filter holds its last value on bars where force is insufficient to breach the threshold, and the direction state remains unchanged on those bars. A full reversal back to bullish requires upward force to exceed the friction threshold and push the filter higher, at which point trend direction flips and the colour transitions accordingly.
🟢 Features
▶ Preconfigured Presets: Three parameter sets cover a range of trading styles and timeframes. "Default" delivers balanced noise filtering for swing trading on 4-hour and daily charts. "Fast Response" lowers the friction threshold and accelerates the catch-up rate for intraday and scalping use on 5-minute to 1-hour charts, producing earlier filter movement in response to smaller price displacements. "Smooth Trend" raises the threshold and slows the catch-up rate for position trading on daily and weekly charts, requiring larger price displacements relative to the average noise level before the filter advances.
▶ Built-in Alerts: Three alert conditions support automated monitoring of trend transitions. "Bullish Trend Signal" fires on the first bar trend direction flips from bearish to bullish. "Bearish Trend Signal" fires on the first bar trend direction flips from bullish to bearish. "Any Trend Change" triggers on either transition for traders who want a single unified alert regardless of direction. All alerts include the exchange, ticker, and timeframe in the message for immediate context.
▶ Visual Customisation: Six colour presets, Classic, Aqua, Cosmic, Cyber, Neon, and Custom, provide coordinated bullish and bearish colour pairings suited to different chart themes and personal preferences. Selecting Custom exposes independent colour pickers for full manual control over both states. Optional bar colouring tints price candles with the active trend colour using a configurable transparency level, and optional background colouring extends the trend state tint across the full chart pane at a separately configurable transparency.
Indicator

Indicator

Strategy

Hyperbolic Hull Moving Average (HHMA) [QuantAlgo]🟢 Overview
Hyperbolic Hull Moving Average is a trend-following indicator that replaces the linear weighting kernel inside a Hull Moving Average with a hyperbolic sine function, producing a moving average that concentrates weight on recent bars in a non-linear, exponentially accelerating curve rather than a straight ramp. Where a standard WMA assigns weight proportionally across the lookback, the sinh kernel creates a steep recency gradient that responds meaningfully to genuine momentum shifts while remaining more resistant to brief noise spikes, because distant bars lose influence at a compounding rate rather than a constant one. The result is a Hull-style construction with faster directional detection and smoother curvature than its conventional counterpart.
🟢 How It Works
The indicator is built across three passes of the same sinh weighting function. The core kernel computes a weighted average where each bar's weight is determined by the hyperbolic sine of its normalized position within the lookback, scaled by a tension parameter:
float _x = (_len - i) / _len * _t
float _w = (math.exp(_x) - math.exp(-_x)) / 2
Higher tension values push more of the total weight toward the most recent bars. At the default tension of 2.0 across a 24-period window, the most recent bar carries roughly 44 times the weight of the oldest bar. A standard WMA across the same window would assign the newest bar only 24 times the weight of the oldest, so the sinh kernel naturally produces a steeper bias toward recent price action at any equivalent length setting.
The Hull construction then runs two sinh-weighted averages at different periods, a fast pass at half the length and a slow pass at the full length, before combining them in the same denoising formula Alan Hull originally described:
fastSinh = f_sinh_weight(src, halfLen, tension)
slowSinh = f_sinh_weight(src, length, tension)
rawHull = 2 * fastSinh - slowSinh
hhma = f_sinh_weight(rawHull, sqrtLen, tension)
The raw Hull output is then passed through a final sinh-weighted smoothing pass at the square root of the full length, which removes the lagging noise the doubling step introduces.
Trend direction is determined by a simple slope check on the final output. This keeps state detection clean and unambiguous, with direction changes triggering alerts and visual updates the bar they occur.
🟢 Signal Interpretation
▶ Bullish Trend (Rising HHMA, Green): When the HHMA turns upward, all visual elements switch to the bullish colour, indicating a confirmed uptrend. Because the sinh kernel front-loads weight on recent bars, the line responds quickly to genuine upside momentum without needing price to sustain a move for many bars before registering a directional shift. Trend state remains bullish on each subsequent bar the HHMA continues to rise, allowing traders to hold positions through normal intra-trend oscillation without being shaken out by minor hesitations in the line.
▶ Bearish Trend (Falling HHMA, Red): When the HHMA turns downward, all visual elements switch to the bearish colour, confirming a downtrend or a breakdown from a prior uptrend. The same recency weighting that accelerates bullish detection also means the line will respond relatively quickly to sustained selling pressure, reducing the lag that causes conventional Hull variants to stay bullish well into a reversal. The trend remains bearish on each bar the HHMA continues to fall.
🟢 Features
▶ Preconfigured Presets: Three optimised parameter sets cover different trading approaches. "Default" is calibrated for swing trading on 4-hour and daily charts, balancing responsiveness with noise rejection. "Fast Response" shortens the lookback and increases recency bias for intraday and scalping use on 5-minute to 1-hour charts. "Smooth Trend" extends the period and flattens the weighting curve for position trading on daily and weekly charts where fewer, higher-conviction direction changes are preferred.
▶ Built-in Alerts: Three alert conditions support automated monitoring without requiring constant chart supervision. "Bullish Trend Signal" fires on the bar the HHMA slope turns upward. "Bearish Trend Signal" fires on the bar it turns downward. "Trend Direction Changed" covers both transitions with a single alert for traders who want a unified notification regardless of direction.
▶ Visual Customization: Six colour presets (Classic, Aqua, Cosmic, Cyber, Neon, and Custom) provide coordinated bullish and bearish colour pairs suited to different chart themes and backgrounds. Optional bar colouring tints price bars with the active trend colour at an adjustable transparency level, offering immediate visual confirmation of trend state across all open chart timeframes without requiring the indicator line itself to be in view.
Indicator

Liquidity Sweep Detector [QuantAlgo]🟢 Overview
The Liquidity Sweep Detector is a swing-based liquidity tracking tool that identifies moments when price wicks beyond a confirmed swing high or low and closes back inside, then tracks the remaining unswept levels as forward-projecting lines and zones on your chart. It classifies each event by direction (Bullish or Bearish) and maintains a running registry of swing levels that have not yet been visited by price, giving you a live map of where resting stop clusters may still be sitting across any timeframe and market.
🟢 How It Works
The indicator identifies swing highs and lows using a pivot detection window that requires a configurable number of bars to the left and right to confirm a valid structural point. The active pivot length and minimum wick penetration are resolved from the selected preset before any detection runs:
active_len = preset_config == 'Scalp' ? 5 : preset_config == 'Swing' ? 20 : pivot_len
active_min_pct = preset_config == 'Scalp' ? 0.0 : preset_config == 'Swing' ? 0.05 : min_wick_pct
A bearish sweep is confirmed when price wicks above the most recent swing high by at least the minimum penetration percentage and closes back below it. A bullish sweep mirrors this on the downside:
bearSweep = not na(lastSwingHigh) and high > lastSwingHigh * (1 + active_min_pct / 100) and close < lastSwingHigh
bullSweep = not na(lastSwingLow) and low < lastSwingLow * (1 - active_min_pct / 100) and close > lastSwingLow
Every confirmed swing point is simultaneously stored in an unswept level registry. Levels are removed when the full candle closes beyond them, or immediately when a sweep is confirmed on that level, so the chart only shows levels price has not yet visited:
if bearSweep and array.size(unsweptHighs) > 0
for i = array.size(unsweptHighs) - 1 to 0
if array.get(unsweptHighs, i) == lastSwingHigh
array.remove(unsweptHighs, i)
array.remove(unsweptHighBars, i)
break
The indicator also detects when price enters the zone around an unswept level without yet confirming a full sweep. Edge detection ensures the alert fires once on entry rather than on every bar price remains inside the zone:
buySideEntry = enteredBuySide and not enteredBuySide
sellSideEntry = enteredSellSide and not enteredSellSide
🟢 Key Features
▶ Three Preset Configurations: The indicator includes three presets that override the manual pivot length and minimum wick penetration settings.
1. Default/Custom: A general-purpose configuration suited to swing trading on 4H and daily charts. Confirms swing points that require a reasonable structural context before a sweep is flagged.
2. Scalp: A faster configuration for intraday charts from 1 minute to 15 minutes. Shorter pivot windows capture local swing points that form and get swept within a single session.
3. Swing: A more conservative configuration for daily and weekly charts that requires a more deliberate wick extension before confirming a sweep, filtering out shallow tags at swing levels.
▶ Built-in Alert System: Pre-configured alert conditions cover bearish sweeps, bullish sweeps, any sweep, price entering a buy-side zone, price entering a sell-side zone, and price entering any unswept zone.
▶ Visual Customisation: Choose from five colour presets (Classic, Aqua, Cosmic, Cyber, Neon) or set your own custom colours. Optional candle background highlighting marks sweep bars directly on the chart, and label text size is configurable across four options to suit different chart layouts.
🟢 Important Considerations
▶ Sweep detection references only the most recently confirmed swing high or low at the time each bar closes. On lower timeframes with frequent swing formation, raising the pivot length focuses detection on more structurally significant levels and reduces signal frequency on choppy charts.
▶ The indicator works best as a contextual layer within an existing trading framework. Sweep signals indicate that price has moved beyond a swing level and closed back inside, which is a useful data point, but should be read alongside your system and market context rather than used as a standalone trigger. Indicator

Indicator

BTC Power Law Regime SuiteShort Description, TLDR
BTC Power Law Regime Suite models Bitcoin’s long-term growth as a power law anchored to major bear market lows, then classifies price action into three macro regimes: Expansion, Distribution, and Blow-off. It is designed to show when BTC is behaving normally relative to its long-term adoption curve, when momentum is strengthening, and when price is becoming dangerously extended.
Long Descript
BTC Power Law Regime Suite is a macro Bitcoin indicator built around a simple idea:
Bitcoin does not move in a straight line. Over long periods, it appears to grow along a curved adoption path, while shorter-term price action oscillates above and below that path in cycles of fear, expansion, euphoria, and exhaustion.
This script models that long-term path as a power law curve, then measures how far price has moved away from it and whether that move is still accelerating or beginning to fade.
Core idea
The script uses a two-anchor power law model based on major BTC bear market lows. Instead of forcing arbitrary coefficients, the curve is derived from two historical anchor points. This creates a more practical “gravity line” that represents Bitcoin’s long-run structural trend.
From there, the indicator evaluates three things:
1. Distance from the power law
This tells us how stretched price is relative to the long-term curve.
2. Relative slope
This measures whether BTC is gaining or losing momentum relative to that curve.
3. Relative acceleration
This helps distinguish normal trend expansion from truly parabolic behavior.
By combining those three factors, the script identifies the market’s current macro regime.
Regimes
Expansion
BTC is above its structural trend and momentum is still improving. This is the healthy bullish phase where price is rising faster than the baseline without yet showing obvious exhaustion.
Distribution
BTC remains elevated relative to the power law, but momentum and acceleration are fading. This is the “high but weakening” condition often seen near slow or choppy tops.
Blow-off
BTC is far above the long-term curve and has recently experienced strong acceleration. This is the classic mania or parabolic exhaustion phase.
Visual design
The script is intentionally minimal:
A power law baseline shows the long-term BTC path.
Optional outer orbit bands provide a macro envelope around that path.
A background regime overlay highlights Expansion, Distribution, and Blow-off conditions.
Small markers can optionally mark the beginning of new regime transitions.
A compact status label summarizes current state without cluttering the chart.
The goal is not to create a noisy signal generator, but a clean macro framework for reading Bitcoin’s cycle structure.
How to use it
This indicator works best on:
BTCUSD / BTCUSDT
Weekly timeframe
Log scale enabled
It is designed for macro cycle analysis, not short-term trading entries.
A common way to interpret it:
Near or below the power law: BTC is closer to long-term value or compression
Expansion regime: bullish momentum is building above the baseline
Distribution regime: price remains elevated, but internal strength is deteriorating
Blow-off regime: risk of euphoric exhaustion is rising
Important notes
This script is heuristic, not predictive. It does not forecast tops or bottoms with certainty, and it should not be treated as a standalone trading system.
Its purpose is to provide a structured way to think about:
Bitcoin’s long-term growth path
cyclical overextension
the difference between healthy expansion and late-stage exhaustion
The model is especially useful because it separates being high from still accelerating. That distinction matters. Not every top is a blow-off, and not every overextended market is still in active mania.
Why this script exists
Most Bitcoin models focus on only one dimension:
valuation relative to trend
or momentum
or cycle bands
or parabolic blow-offs
This script tries to combine those into one clean framework:
Power law = structural gravity
Distance = over/underextension
Acceleration = cycle intensity
Regime = market state
That makes it useful for identifying whether BTC is:
trending normally
expanding aggressively
distributing at elevated levels
or entering true blow-off behavior Indicator

Volume Bubbles [QuantAlgo]🟢 Overview
The Volume Bubbles indicator is a multi-layered volume cluster detection system that identifies statistically significant volume events directly on your price chart, classifying them by magnitude (Small, Medium, Big) and direction (Buy, Sell, Mixed). By combining adaptive percentile thresholds across multiple lookback windows with optional volume delta analysis, this indicator highlights moments of elevated trading activity that often signal institutional participation, trend acceleration, or potential reversals across every timeframe and market.
🟢 How It Works
The indicator begins by establishing a lower timeframe for volume delta calculation. When auto-select is enabled, it picks a granular timeframe based on your chart period, using 1-second bars for sub-minute charts, 1-minute bars for intraday charts, 5-minute bars for daily charts, and 60-minute bars for higher timeframes. This allows the indicator to estimate net buying and selling pressure within each chart bar:
= taLib.requestVolumeDelta(lowerTimeframe)
float netDelta = nz(lastDelta)
float absDelta = math.abs(netDelta)
The core detection engine then calculates percentile thresholds for both volume and absolute delta across three independent lookback windows (Short, Medium, Long). Each window computes its own threshold for each cluster tier using linear interpolation:
float vSmallShort = ta.percentile_linear_interpolation(volume, shortLen, smallPct)
float vSmallMid = ta.percentile_linear_interpolation(volume, midLen, smallPct)
float vSmallLong = ta.percentile_linear_interpolation(volume, longLen, smallPct)
This means a bar's volume is not compared against a single average but ranked against the full distribution of recent volume history from multiple perspectives. A Small cluster must exceed the 75th percentile (top 25%), a Medium cluster the 90th percentile (top 10%), and a Big cluster the 97th percentile (top 3%) by default.
To filter noise, a consensus system requires agreement across the lookback windows before confirming a cluster:
f_consensus(bool pS, bool pM, bool pL, string mode) =>
int hits = (pS ? 1 : 0) + (pM ? 1 : 0) + (pL ? 1 : 0)
switch mode
"Any Window" => hits >= 1
"Majority (2 of 3)" => hits >= 2
"All Windows (strictest)" => hits >= 3
In Majority mode, for example, at least two of the three windows must agree that volume exceeds the threshold before a cluster is plotted. This prevents false signals from temporary spikes that look significant in one context but not another.
Once a cluster is confirmed, it is classified as Buy, Sell, or Mixed based on the selected method. Candle Direction uses the bar's open/close relationship, Delta Direction uses the sign of net volume delta, and Both requires agreement between the two, labeling any conflict as Mixed.
🟢 Key Features
▶ The indicator offers four detection methods, each designed to balance sensitivity and precision depending on data availability and trading style.
1. Volume Only: Uses raw bar volume as the sole input for cluster detection. This is the simplest and most universal mode, working on any symbol that provides volume data. It identifies all statistically elevated volume events regardless of whether buying or selling dominated, making it useful for spotting general activity surges around key levels, news events, or session opens.
2. Delta Only: Uses the absolute value of net volume delta instead of total volume. This mode triggers only when directional pressure (not just raw activity) is statistically elevated. It filters out high-volume bars where buying and selling were roughly balanced, focusing instead on bars where one side clearly dominated. Requires lower timeframe data availability.
3. Volume + Delta: Both volume and delta must independently exceed their respective percentile thresholds. This is the strictest detection mode. A cluster only appears when there is both unusually high total activity and unusually strong directional flow, filtering out ambiguous bars where volume was high but evenly split between buyers and sellers.
4. Volume OR Delta: Either elevated volume or elevated directional delta triggers a cluster. This is the most inclusive mode, capturing both pure volume events (such as index rebalancing or option expiration activity) and strong directional surges that may occur on relatively normal total volume. Best suited for traders who prefer broader coverage and are comfortable filtering signals with additional context.
▶ Detailed Tooltip Overlay: Hovering over any bubble reveals a comprehensive diagnostic panel summarizing the full context behind that cluster. The tooltip displays the cluster tier and direction label (e.g., BIG BUY or MEDIUM SELL), the formatted volume value, net delta value (or "n/a" if delta data is unavailable), the volume-to-average ratio expressed as a multiple, the active detection method (with a fallback note if delta was unavailable and the method defaulted to Volume Only), the individual window confirmations for both volume and delta shown as a compact S M L grid indicating which of the short, medium, and long lookback windows passed their threshold, and the classification mode used to determine the buy/sell label. This gives full transparency into exactly why each cluster was detected and how it was classified, without cluttering the chart itself.
▶ Built-in Alert System: Pre-configured alert conditions for Big clusters, Medium-or-larger clusters, and any cluster detection, allowing you to receive notifications for the volume events that matter most to your strategy.
▶ Visual Customization: Choose from 5 color presets (Classic, Aqua, Cosmic, Cyber, Neon) or define your own custom color scheme. Optional in-bubble text displays volume, delta, ratio, or combinations, while the tooltip diagnostic panel remains accessible on hover regardless of whether bubble labels are enabled or disabled.
🟢 Important Notes
1. This indicator requires volume data to function. Make sure you are using a ticker from an exchange that provides volume data. Symbols that do not report volume (such as certain forex pairs on specific brokers or custom-built indices) will trigger a warning message on the chart and produce no signals. If you see the "No Volume Data" warning, switch to a symbol or exchange that supports volume reporting.
2. Whether you are scalping on lower timeframes or swing trading on daily and weekly charts, Volume Bubbles is designed to complement your existing setup rather than replace it. Use it as a confirmation layer alongside your preferred strategy to identify when statistically significant volume activity aligns with your trade thesis, adding a data-driven edge to entries, exits, and key level analysis across any timeframe and market. Indicator

Moon Boys BTC Production Cost Daily137
═════════════════════════════════════════════════════════════
Moon Boys BTC PRODUCTION COST DAILY
═════════════════════════════════════════════════════════════
Track Bitcoin's real-time production cost using comprehensive electricity consumption data and mining economics to identify macro support/resistance zones.
═══ OVERVIEW ═══
This indicator calculates Bitcoin's actual cost of production by combining Cambridge Bitcoin Electricity Consumption Index (CBECI) data with electricity pricing models across different mining eras. It reveals where miners are profitable or underwater, providing crucial macro-level support zones that have historically acted as psychological and economic floors.
Perfect for:
• Identifying long-term accumulation zones
• Understanding miner profitability and capitulation risk
• Spotting macro support levels during bear markets
• Gauging healthy vs. overheated price levels
• Planning dollar-cost averaging strategies
═══ KEY FEATURES ═══
📊 COMPREHENSIVE HISTORICAL DATA
└─ 378 data points spanning 2011-2026
└─ Complete CBECI electricity consumption dataset
└─ Verified accuracy: all dates and values cross-checked
└─ Updates every ~14 days with new CBECI releases
⚡ ELECTRICITY COST MODELING
└─ Pre-June 2019: $0.05/kWh (Early mining era)
└─ Pre-April 2021: $0.04/kWh (China dominance period)
└─ Post-May 2021: $0.05/kWh (China exodus, Western migration)
└─ Post-April 2024: $0.05/kWh (Post-4th halving era)
└─ Fully customizable for scenario analysis
🎯 DUAL COST CURVES
└─ Red line: Pure electricity cost per BTC
└─ Purple line: Total production cost (electricity + operations)
└─ Green line: Miner price (spot + transaction fee revenue)
└─ Pink fill: Zones where miners are losing money
📈 AUTOMATIC HALVING ADJUSTMENTS
└─ Integrates all Bitcoin halvings (2012, 2016, 2020, 2024)
└─ Block reward automatically adjusts: 50 → 25 → 12.5 → 6.25 → 3.125
└─ Accurate per-day BTC production calculations
💰 PROFIT MARGIN TRACKING
└─ Annual profit margin labels (optional)
└─ Shows miner profitability percentage
└─ Appears on chart at electricity cost level
└─ Calculated using 365-day moving average
═══ HOW TO READ IT ═══
┌─────────────────────────────────────────────────────────┐
│ INDICATOR │ MEANING │
├─────────────────────────────────────────────────────────┤
│ 🟢 Green Line │ Miner Price (BTC price + fee revenue)│
│ (above purple) │ → Miners profitable, healthy market │
├─────────────────────────────────────────────────────────┤
│ 🟢 Green Line │ Price below production cost │
│ (below purple) │ → Miner capitulation zone │
│ │ → Strong historical buy signal │
├─────────────────────────────────────────────────────────┤
│ 🔴 Red Line │ Pure electricity cost per BTC │
│ │ → Absolute minimum mining cost │
├─────────────────────────────────────────────────────────┤
│ 🟣 Purple Line │ Total production cost │
│ │ → Break-even for miners (60% elec) │
├─────────────────────────────────────────────────────────┤
│ 🌸 Pink Fill │ Below-cost territory │
│ │ → Miners selling at a loss │
│ │ → Historical accumulation zone │
└─────────────────────────────────────────────────────────┘
═══ TRADING APPLICATIONS ═══
🐻 BEAR MARKET BOTTOMS
→ Price touching or breaking below production cost = high probability bottom
→ Extended periods below cost = miner capitulation
→ Historical bottoms: Nov 2011, Jan 2015, Dec 2018, Nov 2022
→ Strongest buy signal in macro Bitcoin investing
📈 BULL MARKET HEALTH CHECKS
→ Distance above production cost = market heat level
→ 100-200% above cost = healthy bull market
→ 500%+ above cost = euphoric/bubble territory
→ Use as take-profit reference points
💎 ACCUMULATION STRATEGY
→ DCA when price approaches production cost
→ Increase buy size when price drops below cost
→ Maximum allocation when 10-20% below cost
→ Layer entry as margin shows negative percentages
⚖️ SUPPORT/RESISTANCE ZONES
→ Production cost acts as macro support in downtrends
→ Often becomes resistance after prolonged bear markets
→ Price reclaiming cost = bullish structural shift
→ Failed reclaims = continued weakness
🔄 HALVING CYCLE ANALYSIS
→ Cost doubles after each halving (supply cut)
→ Price typically consolidates near new cost basis
→ Historic pattern: break above cost = new bull cycle
→ Track 6-12 months post-halving for trend confirmation
═══ SETTINGS GUIDE ═══
⚡ ELECTRICITY COST ASSUMPTIONS (USD/kWh)
├─ Pre-June 2019 (0.05): Early mining era, hobby miners
├─ Pre-China Exodus 2021 (0.04): Cheap Chinese hydropower
├─ Post-May 2021 (0.05): Western migration, higher costs
└─ Post-April 2024 (0.05): Current era post-4th halving
💡 Adjust these for "what if" scenarios or local costs
💰 ELECTRICITY PERCENTAGE (Default: 60%)
└─ Electricity as % of total mining costs
└─ Remaining 40% = hardware, labor, rent, maintenance
└─ Lower % = higher total cost (more conservative)
└─ Typical range: 50-70%
🎨 VISUAL TOGGLES
├─ Plot BTC Miner Price: Show/hide green line
│ └─ Includes transaction fee revenue per BTC
├─ Plot Production Cost Curves: Show/hide red & purple lines
└─ Plot Annual Profit Margin Labels: Show/hide margin %
└─ Appears annually (Jan 1st) and on last bar
═══ HOW IT WORKS ═══
1. ELECTRICITY CONSUMPTION DATA
• Cambridge Bitcoin Electricity Consumption Index (CBECI)
• Actual network-wide energy usage in TWh (terawatt-hours)
• Updated bi-weekly with real hash rate data
• 378 historical data points (Aug 2011 - Jan 2026)
2. COST CALCULATION FORMULA
Electricity Cost per BTC =
(TWh per year / 365.25 days) ×
(10^9 to convert to kWh) /
(BTC mined per day) ×
(Electricity price per kWh)
Total Cost per BTC =
Electricity Cost / (Electricity % of total costs)
3. BTC MINED PER DAY
Blocks per day (144) × Block reward
• 2009-2012: 50 BTC/block = 7,200 BTC/day
• 2012-2016: 25 BTC/block = 3,600 BTC/day
• 2016-2020: 12.5 BTC/block = 1,800 BTC/day
• 2020-2024: 6.25 BTC/block = 900 BTC/day
• 2024+: 3.125 BTC/block = 450 BTC/day
4. MINER PRICE METRIC
Spot close price + (Transaction fees per day / BTC mined per day)
• Currently simplified with fees = 0
• Shows true revenue per BTC for miners
5. PROFIT MARGIN CALCULATION
((Miner Price / Total Cost) - 1) × 100
• Smoothed with 365-day SMA
• Shows sustainable annual profitability
═══ BEST PRACTICES ═══
✅ DO:
• Use on DAILY timeframe for accuracy (designed for daily data)
• Combine with on-chain metrics (SOPR, MVRV, Puell Multiple)
• Layer with traditional TA for entry/exit timing
• Understand this is AVERAGE global cost (varies by miner)
• Use as macro filter, not short-term trading signal
• Check profit margins during capitulation events
❌ DON'T:
• Use as sole indicator for short-term trades
• Ignore that efficient miners have much lower costs
• Forget that cost is constantly rising (hash rate + difficulty)
• Assume price can't go below cost (it can temporarily)
• Trade based only on cost - liquidity events can wick lower
• Expect instant reversals at cost levels
═══ HISTORICAL PERFORMANCE ═══
Major Bitcoin bottoms near/below production cost:
📅 November 2011
Price: ~$2 | Cost: ~$5
→ 60% below cost, -95% drawdown
→ Bottom signal ✓
📅 January 2015
Price: ~$150 | Cost: ~$180
→ 17% below cost, -85% drawdown
→ Bottom signal ✓
📅 December 2018
Price: ~$3,200 | Cost: ~$3,500
→ 9% below cost, -84% drawdown
→ Bottom signal ✓
📅 November 2022
Price: ~$15,500 | Cost: ~$17,000
→ 9% below cost, -77% drawdown
→ Bottom signal ✓
Pattern: When price trades below production cost, accumulation zone.
═══ TECHNICAL NOTES ═══
• Built with Pine Script v5
• Data source: Cambridge Centre for Alternative Finance (CBECI) Updated Quaterly by Request
• All dates/values verified against official CSV dataset
• Electricity price adjusts based on major mining regime shifts
• Uses series variables for proper historical calculation
• Forward-fills data between CBECI update periods
• Accounts for all 4 halvings in BTC history
═══ DATA PERIODS EXPLAINED ═══
🏭 PRE-JUNE 2019 ($0.05/kWh)
Early mining era, distributed hobby miners, average global cost
🇨🇳 JUNE 2019 - APRIL 2021 ($0.04/kWh)
China dominance period, cheap hydropower in Sichuan/Yunnan
🌍 MAY 2021 - APRIL 2024 ($0.05/kWh)
China ban, Western migration, renewable energy transition
🔮 POST-APRIL 2024 ($0.05/kWh)
4th halving, institutional mining, current era
═══ UNDERSTANDING MINING ECONOMICS ═══
⚡ ELECTRICITY = 60% OF COST (Default)
└─ Largest variable expense for miners
└─ Directly tied to hash rate and difficulty
🔧 OTHER COSTS = 40%
├─ ASIC hardware (depreciation)
├─ Facility rent and cooling
├─ Labor and maintenance
├─ Internet and infrastructure
└─ Insurance and legal
💰 REVENUE SOURCES
├─ Block subsidy (newly minted BTC)
└─ Transaction fees (variable, usually 2-10% of revenue)
📉 MINER BEHAVIOR
• Profitable: Accumulate BTC, expand operations
• Break-even: Hold BTC, maintain operations
• Unprofitable: Forced selling, potential capitulation
═══ ADVANCED USE CASES ═══
🔬 SCENARIO ANALYSIS
→ Adjust electricity costs to model different regions
→ US miners: $0.05-0.07/kWh
→ Nordic miners: $0.02-0.04/kWh
→ Middle East: $0.01-0.03/kWh
📊 COMBINE WITH ON-CHAIN DATA
→ Miner Net Position Change (selling pressure)
→ Hash Ribbons (miner capitulation indicator)
→ Difficulty Ribbon (hash rate compression)
→ Puell Multiple (miner revenue extremes)
🎯 MULTI-TIMEFRAME CONFLUENCE
→ Weekly chart: macro trend and cost support
→ Daily chart: precise entry/exit near cost
→ 4H chart: short-term reactions at cost levels
🌐 CORRELATION TRADING
→ Miner stocks (MARA, RIOT, CLSK) vs BTC cost
→ When BTC < cost, miner stocks typically -30-50%
→ Energy prices (oil, nat gas) affect mining costs
═══ LIMITATIONS & CONSIDERATIONS ═══
⚠️ AVERAGE COST, NOT ACTUAL
• Large miners with PPAs have costs as low as $0.02-0.03/kWh
• Inefficient miners may have costs 2-3x the average
• This shows network-wide average for reference
⚠️ ELECTRICITY PRICE ASSUMPTIONS
• Static periods vs. dynamic energy markets
• Renewable energy % growing = lower average cost over time
• Geographic distribution matters (Texas vs. Kazakhstan)
⚠️ DOESN'T INCLUDE
• ASIC efficiency improvements (more hash/watt)
• Stranded energy and flare gas mining
• Government subsidies or penalties
• Seasonal variations (wet/dry seasons)
⚠️ LAGGING INDICATOR
• CBECI data updates every ~14 days
• Historical data, not forward-looking
• Cost always rises, but at variable rate
═══ DISCLAIMER ═══
This indicator visualizes Bitcoin's estimated global average production cost based on publicly available electricity consumption data and modeled pricing assumptions. It does NOT:
• Guarantee future price movements or bottoms
• Account for individual miner profitability variations
• Include all operational costs (simplified to electricity %)
• Predict miner capitulation or selling pressure
• Constitute financial advice or buy/sell signals
Production cost is A REFERENCE POINT, not a hard floor. Price can and has traded below cost during extreme capitulation events. Market liquidity, macro conditions, and sentiment often override cost-basis logic in the short term.
Always conduct your own research and use proper risk management.
📚 EDUCATIONAL USE ONLY | NOT FINANCIAL ADVICE
═══ RESOURCES ═══
Cambridge Bitcoin Electricity Consumption Index (CBECI)
→ ccaf.io/cbnsi/cbeci
Bitcoin Mining Economics
→ insights.braiins.com/en/
Block Reward Halving Schedule
→ bitcoinblockhalf.com/
Difficulty & Hash Rate Charts
→ blockchain.com/charts/difficulty
Understanding ASIC Mining
→ academy.binance.com/en/articles/what-is-an-asic-miner
Mining Profitability Calculator
→ coinwarz.com/mining/bitcoin/calculator
On-Chain Miner Metrics
→ cryptoquant.com/
Energy & Mining Data
→ hashrateindex.com/
═══════════════════════════════════════════════════════════
Built for the Bitcoin community 🚀
Because understanding the cost of production is fundamental analysis 💎
═══════════════════════════════════════════════════════════ Indicator

Indicator

Adaptive SuperTrend Oscillator [QuantAlgo]🟢 Overview
The Adaptive SuperTrend Oscillator transforms the classic SuperTrend indicator into a normalized momentum score that adapts to changing market conditions. Instead of displaying a simple above/below signal on the price chart, it measures how far price has moved from the SuperTrend line and scales that distance against an Efficiency Ratio-driven ATR that automatically adjusts between trending and ranging environments. The result is a centered oscillator with dynamically calculated overbought and oversold thresholds, helping traders read the strength behind a trend rather than just its direction, across different markets and timeframes.
🟢 How It Works
The foundation of the indicator is the distance between the closing price and the SuperTrend line:
= ta.supertrend(active_multiplier, active_atr_length)
price_distance = close - supertrend_line
A positive distance means price is above the SuperTrend line, indicating a bullish condition. A negative distance indicates price is below it, reflecting a bearish condition. The raw distance alone is not directly comparable across instruments or timeframes, so the indicator normalizes it using an adaptive ATR.
The normalization layer is driven by an Efficiency Ratio, which measures how directionally efficient recent price movement has been. It compares the net price change over the lookback window against the total path length traveled:
price_change = math.abs(close - close )
path_length = math.sum(math.abs(close - close ), active_er_length)
efficiency_ratio = path_length != 0 ? price_change / path_length : 0.0
A high Efficiency Ratio means price is moving in a consistent direction with little back-and-forth. A low ratio indicates choppy, non-directional movement. This reading is then used to blend between a fast and slow ATR period:
adaptive_atr = efficiency_ratio * ta.atr(active_norm_fast) + (1.0 - efficiency_ratio) * ta.atr(active_norm_slow)
score = adaptive_atr != 0 ? price_distance / adaptive_atr * 100 : 0.0
During trending conditions the fast ATR period is weighted more heavily, allowing the score to move more freely. During choppy conditions the slow ATR period dominates, dampening the score and reducing low-conviction readings. The final score is expressed as a percentage of the adaptive ATR, making it directly comparable across different instruments and volatility environments.
Overbought and oversold levels are derived dynamically from the rolling standard deviation of the score itself rather than fixed values:
score_deviation = ta.stdev(score, 100)
ob_extreme = score_deviation * 3
ob_level = score_deviation * 2
os_level = -score_deviation * 2
os_extreme = -score_deviation * 3
This means the threshold levels expand during volatile periods and contract during quiet ones, keeping the overbought and oversold zones statistically consistent relative to recent score behavior.
🟢 Signal Interpretation
▶ Bullish Trend (Score Above Zero, Outside Neutral Zone, Green): When the score is positive and exceeds the neutral threshold, the oscillator confirms that price is above the SuperTrend line and momentum is directionally efficient enough to register. The score's gradient intensity reflects how far momentum has extended relative to the adaptive ATR baseline. The trend remains bullish until the score crosses back below zero or into the neutral zone.
▶ Bearish Trend (Score Below Zero, Outside Neutral Zone, Red): When the score is negative and falls below the neutral threshold, the oscillator confirms that price is below the SuperTrend line. A deeper negative score indicates stronger downside momentum relative to the normalization baseline. The trend remains bearish until the score crosses back above zero or into the neutral zone.
▶ Neutral Zone (Score Within Threshold, Grey): When the absolute score value is within the neutral threshold, the oscillator treats the reading as non-directional regardless of which side of zero it sits on. This filters out low-conviction conditions where the SuperTrend distance is small relative to the adaptive ATR, preventing the indicator from registering trend signals during consolidation or choppy price action.
▶ Overbought and Oversold Levels (2σ and 3σ Bands): When the score reaches the 2σ or 3σ bands, it indicates that momentum has extended significantly relative to its own recent history. These are not reversal signals by themselves, but they mark zones where the trend is stretched and worth monitoring for potential exhaustion.
🟢 Features
▶ Preconfigured Presets: Three parameter sets cover different trading approaches. "Default" uses moderate SuperTrend sensitivity for swing trading on 4-hour and daily charts. "Fast Response" tightens the SuperTrend bands and shortens normalization windows for intraday use on 5-minute to 1-hour charts. "Smooth Trend" widens the SuperTrend bands and extends normalization windows for position trading on daily and weekly timeframes.
▶ Built-in Alerts: Seven alert conditions cover the full range of oscillator states. Trend transition alerts fire when the score crosses into bullish, bearish, or neutral territory. Separate alerts trigger when the score reaches the 2σ overbought or oversold levels and again when it reaches the more extreme 3σ levels, enabling graduated monitoring without requiring constant chart observation.
▶ Visual Customization: Six color presets (Classic, Aqua, Cosmic, Cyber, Neon, plus Custom) coordinate colors across the score line, ribbon fills, overbought/oversold bands, and optional bar coloring. The ribbon uses three fill layers between the score line and zero, each at increasing transparency, creating a gradient that visually represents the weight of momentum behind the current reading. Optional bar coloring applies trend state colors directly to price bars for quick multi-timeframe reference.
Indicator

APEX ELITE . 2━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
◈ APEX ELITE . 2
Open Source Pine Script v6 · Panel-Only Edition · Zero Chart Clutter
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⚠️ NOT FINANCIAL ADVICE — See full disclaimer at the bottom.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
WHAT IS APEX ELITE?
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
APEX ELITE is a single, unified intraday dashboard that replaces what would otherwise require 8 or more separate indicators. Everything runs internally and surfaces through one clean, color-coded panel. Your chart stays completely uncluttered — no extra lines, no overlapping boxes, no noise.
Built specifically for intraday traders who need instant situational awareness:
→ Is there a signal right now?
→ What is the trend across multiple timeframes?
→ Where are the key levels?
→ How strong is the current edge?
All of that — answered in a single glance at the panel.
🔑 Key principles:
• All signals fire on confirmed bars only — zero repainting
• 12+ factors combine into one composite score before any signal fires
• Session clock tracks 8 intraday phases so you always know the market context
• Compact Mode available for smaller screens
• 22 configurable alert conditions built in
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
THE 12 MODULES — COMPLETE BREAKDOWN
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
▸ BLOCK A — SIGNAL COMMAND
───────────────────────────
The top block of the panel. Shows the current signal state in large text — ▲ CALL SIGNAL, ▼ PUT SIGNAL, or ● WATCHING — along with the live composite edge score and directional bias.
• Signal State: CALL / PUT / WATCHING — updates every confirmed bar
• Edge Direction: BULL / BEAR / NEUT with score out of 100 (e.g. "BULL 82/100")
• Edge Bar: 10-block visual bar showing edge % (████████░░)
• Bull / Bear pts: Raw scores shown side-by-side for comparison
The background color of this row changes: green for CALL, red for PUT, neutral for watching.
▸ BLOCK B — INTRADAY LEVELS
────────────────────────────
Every key price level an intraday trader needs, all in one place.
• VWAP Zone: Which of 6 zones price is in — Above +2σ / +1→+2σ / VWAP→+1σ / -1→VWAP / -2→-1σ / Below -2σ
• VWAP Distance: Real-time % distance of close from VWAP (e.g. +0.42% dist)
• PMH / PML: Pre-Market High and Low — the most important intraday reference levels. A break of PMH or PML triggers the maximum +20 trigger points.
• FCH / FCL: First Candle High and Low (configurable: 1/2/3/5/15 min). Also shows the first candle's range as a %.
• Supply / Demand: Nearest unmitigated supply zone above price and demand zone below price — with total active zone count.
• Level Break: Live readout when PMH, PML, FCH, or FCL is broken on the current bar.
▸ BLOCK C — MOMENTUM STACK
───────────────────────────
A complete multi-timeframe picture of trend alignment.
• SMA 9 (cyan): Short-term momentum MA. Above = bullish micro trend.
• SMA 21 (gold): Medium momentum MA. The primary intraday trend filter.
• SMA 50 (orange): Intermediate trend. Pullback entries reference this level.
• SMA 200 (red): Long-term macro trend. Above = bull market context.
• MA Alignment: Count of MAs on each side (e.g. 4/4 bull). Full stack = strongest signal.
• MA Stack Order: Full Bull Stack confirmed when 9 > 21 > 50 > 200 all correctly ordered.
• EMA Ribbon: EMA 8 vs EMA 21 — ribbon direction shows short-term momentum.
• MTF Alignment: Per-timeframe arrows (▲5m ▲15m ▼1h) — instantly see each TF at a glance.
• Daily Context: Daily EMA 9 vs EMA 21 — trade with the daily trend for the highest quality setups.
Tip: MTF 3/3 aligned + MA 4/4 bull + daily EMA bull = the highest conviction entries.
▸ BLOCK D — MARKET STRUCTURE
──────────────────────────────
The highest-conviction trigger events in the system.
• Liquidity Sweep: Price briefly violates a 20-bar extreme before reversing — a classic stop hunt. Tracks age in bars (e.g. "▲ Bull (3b ago)").
• Structure Break (MSB): Close crosses a confirmed 10-bar pivot high or low. The strongest directional confirmation. Also tracks age.
• Squeeze: Bollinger Bands contracting inside Keltner Channels = coiling volatility. Shows bars coiling. Fires on expansion.
• Squeeze Momentum: Rising / Falling / Flat direction of momentum during the squeeze.
• ADX: Average Directional Index — Strong (>30) / Trending (20-30) / Choppy (<20).
• DI+ / DI-: Split readout showing directional pressure.
Both Sweeps and MSBs add the maximum trigger bonus (+20 pts) to the score.
▸ BLOCK E — RISK ENGINE
────────────────────────
Everything needed to size and manage a trade the moment a signal appears.
• ATR 14: 14-period Average True Range — raw volatility in price points.
• Stop 1× / 1.5× / 2×: Three stop-loss distances pre-calculated simultaneously. Choose based on your risk tolerance.
• Volume Ratio: Current volume as a multiple of the 20-bar average (e.g. 1.8× avg).
• Volume: "▲ SPIKE" label when volume clears your configured threshold. "Normal" otherwise.
• RSI 14: 14-period RSI with contextual labels — OB (>70), OS (<30), Elevated, Depressed, Neutral.
▸ BLOCK F — LIQUIDITY HEATMAP
( Inspired by BigBeluga — Dynamic Liquidity HeatMap Profile )
──────────────────────────────────────────────────────────────
This module is inspired by the methodology from BigBeluga's excellent Dynamic Liquidity HeatMap Profile indicator. It uses ATR-normalized, volume-weighted pivot analysis over a configurable lookback (default 300 bars) to determine whether buy-side or sell-side liquidity is dominant.
• Liq Bias: Buy-Side / Sell-Side / Balanced — with dominant side percentage (e.g. "Buy-Side 73%")
• Vol Intensity: Graphical bar (▓▓▓░░) showing current volume activity as % of the 300-bar max
• Score Impact: +5 bull score when buy-side > 60% · +5 bear score when sell-side > 60%
Full credit to BigBeluga for the original concept. Please visit and support their work.
▸ BLOCK G — REVERSAL PROBABILITY ZONE
( Inspired by LuxAlgo — Reversal Probability Zone & Levels )
──────────────────────────────────────────────────────────────
This module ports the exact algorithmic core of LuxAlgo's Reversal Probability Zone & Levels indicator. It builds two separate databases of historical swing moves — one bullish, one bearish — tracking both the price magnitude and bar duration of every confirmed pivot. From these it calculates statistical percentile targets for the most likely next move.
• Forecast Bias: ▲ Bull or ▼ Bear — direction expected after the last pivot
• 25th / 50th Percentile: Conservative and median price targets (e.g. 518.40 / 521.20)
• 75th / 90th Percentile: Aggressive and maximum targets (e.g. 524.80 / 528.50)
• Duration: Expected bar count to reach each target (e.g. "8 bars / 22 bars")
• Pivot Count: Total swings tracked — more pivots = more statistically reliable readings
Full credit to LuxAlgo for the original algorithm. Licensed under CC BY-NC-SA 4.0.
▸ BLOCK H — STANDARD DEVIATION CHANNEL
────────────────────────────────────────
A linear regression channel fitted to the last N bars (default 128). Shows where price sits statistically within the current trend.
• Channel Zone: One of 6 zones — Above +2σ / +1→+2σ / Mid→+1σ / -1→Mid / -2→-1σ / Below -2σ
• Trend Direction: Rising / Falling / Flat based on the regression slope
• Pearson R: Correlation coefficient. Above 0.8 = very clean trend. Below 0.5 = noisy/ranging.
• Midline Distance: % distance of close from the regression center line
Best CALL zone: "Mid → +1σ" on a rising channel.
Best PUT zone: "Mid → -1σ" on a falling channel.
Avoid entries when zone shows "Above +2σ" or "Below -2σ" — price is statistically extended.
▸ BLOCK I — RSI DIVERGENCE
( Libertus Method )
─────────────────────────────────────────────
Detects bull and bear RSI divergences by comparing price swing extremes against RSI swing extremes over a configurable lookback window (default 90 bars).
• Bull Divergence: Price makes lower low but RSI makes higher low — hidden strength, potential reversal up
• Bear Divergence: Price makes higher high but RSI makes lower high — hidden weakness, potential reversal down
• Age Tracking: "Bull Div (3b ago)" or "Bull Div ✦ NOW" — shows exactly how fresh the divergence is
• RSI Value: Current reading with OB / OS labels
• Score Bonus: +5 bull score on bull divergence · +5 bear score on bear divergence
Credit to Libertus for the divergence detection methodology.
▸ BLOCK J — SESSION CLOCK
──────────────────────────
Intraday trading is entirely timing-dependent. This block tracks 8 distinct market phases, each color-coded by typical volatility profile.
PRE-MKT → 4:00 – 9:30 AM ET (PMH/PML building)
OPEN (HOD/LOD) → 9:30 – 10:00 AM ET (highest volatility, initial direction)
AM SESSION → 10:00 – 11:30 AM ET (best signal quality window)
LUNCH APPROACH → 11:30 – 12:00 PM ET (momentum slowing)
LUNCH CHOP → 12:00 – 1:30 PM ET (avoid new entries)
PM SESSION → 1:30 – 2:30 PM ET (trend continuation or reversal)
POWER HOUR NEAR → 2:30 – 3:00 PM ET (institutional activity increasing)
POWER HOUR → 3:00 – 4:00 PM ET (highest volume, strongest moves)
Also shows time remaining in RTH. Turns gold when less than 60 minutes remain.
▸ BLOCK K — COMPOSITE EDGE SCORE
───────────────────────────────────
Instead of just showing one number, this block breaks the score into individual factor bars — each showing exactly how much it is contributing. You can see not just THAT the score is high, but WHY.
VWAP → ████░ (max 15 pts)
MTF → █████ (max 15 pts)
MA → ████░ (max 12 pts)
Momentum → ███░░ (max 5 pts)
Volume → ██░░░ (max 10 pts)
Trigger → █████ (max 20 pts ← most important)
ADX → ████░ (max 8 pts)
Edge → ████░ (overall 0-100)
A high score driven purely by momentum without a trigger event is weaker than one with everything aligned.
▸ BLOCK L — FRACTAL BASE
( Inspired by LuxAlgo — Fractal Base Indicator )
──────────────────────────────────────────────────
This module ports the core logic from LuxAlgo's Fractal Base Indicator. A fractal is a confirmed swing pivot where price has N bars of context on both sides — these represent the most significant recent support and resistance levels because they show where price genuinely reversed.
• Fractal Res: Last confirmed fractal HIGH — price + bars since + % distance from close
• Fractal Sup: Last confirmed fractal LOW — price + bars since + % distance from close
• Price Bias: "Above Res" (price broke resistance) / "Below Sup" (broke support) / "In Range" (between levels)
• Fractal Event: "New High Fractal" or "New Low Fractal" when a new fractal confirms this bar
• Score Bonus: +4 pts near fractal support/resistance · +3 pts when level is broken
• Configurable: Fractal Periods input — 2 = 5-bar fractal (default), 1 = 3-bar, 3 = 7-bar
Full credit to LuxAlgo for the original indicator concept.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
THE SCORING ENGINE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Bull and bear scores are calculated independently on every confirmed bar. A signal only fires when the score clears the threshold AND key filters are simultaneously met.
COMPONENT MAX PTS CONDITION
────────────────────────────────────────────────────────────
VWAP Zone 15 / 8 15 inside ±1σ · 8 correct side outside band
MTF Alignment 15 / 8 15 all 3 TFs aligned · 8 for 2 of 3
MA Alignment 12/7/3 12 for 4/4 · 7 for 3/4 · 3 for 2/4
EMA Ribbon 5 EMA 8 vs 21 direction
Volume Spike 10 Volume > mult × 20-bar avg AND correct direction
Trigger Event 20 ★ PMH/PML/FCH/FCL break · Sweep · MSB
ADX Strength 8 / 5 8 if ADX >30 · 5 if ADX 20-30
Squeeze Fire 5 Squeeze fires in signal direction
ABC Harmonic 5 Active harmonic pattern aligned
RSI Zone 5 RSI 50-70 for bull · 30-50 for bear
RSI Divergence 5 Bull/bear divergence active
Liq HeatMap Bias 5 Buy/sell-side >60%
Std Dev Channel 4 Price in sweet zone on correct trend
Daily EMA Trend 4 Daily chart EMA alignment
S/D Zone Proximity 3 Within 0.3% of demand (bull) or supply (bear)
Fractal Proximity 4 / 3 Within 0.25% of fractal level / level broken
────────────────────────────────────────────────────────────
★ Trigger Event carries the most weight. A signal without a trigger is unlikely to fire.
DEFAULT THRESHOLD: 65 pts
Raise to 75+ for fewer but higher-quality signals.
Lower to 55 on very active trending days.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SIGNAL CONDITIONS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
A CALL signal requires ALL of the following simultaneously:
✅ Bull score ≥ threshold
✅ Close above VWAP (hard filter)
✅ MTF alignment 2/3 or better
✅ Active trigger event (PMH break / FCH break / Bull Sweep / MSB ▲ / Squeeze bull)
✅ barstate.isconfirmed — never fires mid-bar, zero repainting
✅ RTH session active (if RTH Only setting is on)
A PUT signal requires ALL of the following simultaneously:
✅ Bear score ≥ threshold
✅ Close below VWAP (hard filter)
✅ MTF alignment 2/3 or better (bearish)
✅ Active trigger event (PML break / FCL break / Bear Sweep / MSB ▼ / Squeeze bear)
✅ barstate.isconfirmed
✅ RTH session active (if RTH Only setting is on)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
22 ALERT CONDITIONS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
To set up: Right-click the indicator → Add Alert → Select condition.
All alerts include: ticker · close price · timestamp.
SIGNAL ALERTS
▲ CALL Signal — Full CALL criteria met
▼ PUT Signal — Full PUT criteria met
◆ Any Signal — Either CALL or PUT
LEVEL BREAK ALERTS
→ PMH Breakout — Close crosses pre-market high
→ PML Breakdown — Close crosses pre-market low
→ FCH Break — Close crosses first candle high
→ FCL Break — Close crosses first candle low
STRUCTURE ALERTS
→ Sweep CALL — Bull sweep + above VWAP
→ Sweep PUT — Bear sweep + below VWAP
→ MSB Bull — Market structure break upward
→ MSB Bear — Market structure break downward
MOMENTUM ALERTS
→ Squeeze Bull Fire — Squeeze fires with bullish close
→ Squeeze Bear Fire — Squeeze fires with bearish close
→ MA Full Bull Stack — All 4 MAs correctly ordered up
→ MA Full Bear Stack — All 4 MAs correctly ordered down
DIVERGENCE & LIQUIDITY
→ RSI Bull Divergence — Bull div detected
→ RSI Bear Divergence — Bear div detected
→ Liq Buy Bias — HeatMap buy-side > 60%
→ Liq Sell Bias — HeatMap sell-side > 60%
PREMIUM ALERTS
★ High Edge (80+) — Composite edge score reaches 80 — premium setup
→ New High Fractal — New confirmed fractal high (LuxAlgo logic)
→ New Low Fractal — New confirmed fractal low (LuxAlgo logic)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SETTINGS QUICK REFERENCE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SESSION & TIME
Pre-Market Session → 0400-0930 ET (adjust for your exchange)
RTH Session → 0930-1600 ET
First Candle Length → 1 / 2 / 3 / 5 / 15 minutes
RTH Signals Only → On by default (recommended)
SIGNAL ENGINE
Min Score to Signal → 65 (raise for fewer signals, lower for more)
Volume Spike Mult → 1.4× (volume must be this × the 20-bar average)
MOVING AVERAGES
MA Type → SMA / EMA / WMA (switches all 4 simultaneously)
MA Lengths → 9 / 21 / 50 / 200 (individually configurable)
REVERSAL PROB ZONE (LuxAlgo)
Swing Length → 20 (pivot sensitivity)
Max Reversals → 1000 (database cap)
Percentiles → 25 / 50 / 75 / 90 (target levels to display)
FRACTAL BASE (LuxAlgo)
Fractal Periods → 2 = 5-bar fractal | 1 = 3-bar | 3 = 7-bar
STD DEV CHANNEL
Regression Length → 128 bars (shorter = more reactive)
RSI DIVERGENCE
RSI Length → 14
OB / OS Levels → 70 / 30
Divergence Lookback → 90 bars
DISPLAY
Panel Position → Top Right / Top Left / Bottom Right / Bottom Left
Compact Mode → Hides sub-rows to shrink panel height
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HOW TO READ THE PANEL — QUICK CHECKLIST
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Before entering any trade, run through these 9 checks:
① Signal showing CALL or PUT? (not just Watching)
② Score at or above your threshold?
③ On the correct side of VWAP?
④ MTF at least 2/3 aligned?
⑤ Channel zone in a reasonable position? (avoid Above +2σ for CALLs)
⑥ Fractal Bias showing "Above Res" (CALL) or "Below Sup" (PUT)?
⑦ RPZ showing a clear price target with enough room for your R:R?
⑧ What was the trigger event? (MSB and Sweep are strongest)
⑨ Can you fit your stop within the 1.5× ATR distance?
If you can answer yes to most of these — the setup has strong confluence.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
CREDITS & ACKNOWLEDGEMENTS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
APEX ELITE was built with deep respect for the Pine Script community. Several modules are directly inspired by the outstanding published work of:
🏆 LuxAlgo
Two modules in APEX ELITE are inspired by LuxAlgo's indicators:
→ Block G (Reversal Probability Zone) ports the core algorithmic logic
from LuxAlgo's "Reversal Probability Zone & Levels" — including the
exact pivot detection method, price/bar delta database, and percentile
target calculation. Licensed under CC BY-NC-SA 4.0.
→ Block L (Fractal Base) implements the fractal high/low detection and
support/resistance logic from LuxAlgo's "Fractal Base Indicator".
LuxAlgo's original indicators are published at:
pulsewire.com/u/LuxAlgo/
All credit for these algorithmic approaches belongs entirely to LuxAlgo.
🏆 BigBeluga
→ Block F (Liquidity HeatMap) is inspired by BigBeluga's
"Dynamic Liquidity HeatMap Profile" indicator. The volume-normalized,
pivot-based liquidity bias methodology is adapted from their approach.
BigBeluga's work can be found at:
pulsewire.com/u/BigBeluga/
Please visit and support their original publications directly.
🏆 Libertus
→ Block I (RSI Divergence) implements the divergence detection method
from Libertus's "RSI Divergences" indicator.
Thank you to all three creators for sharing their knowledge with the community.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⚠️ DISCLAIMER — PLEASE READ IN FULL
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
APEX ELITE is a technical analysis tool published for EDUCATIONAL and INFORMATIONAL purposes only.
❌ It does NOT constitute financial advice.
❌ It does NOT constitute investment advice.
❌ It does NOT constitute trading recommendations.
❌ It is NOT a solicitation to buy or sell any financial instrument.
All information displayed by this indicator is derived from historical price data and mathematical calculations. Past signal performance does NOT guarantee or predict future results. Financial markets are inherently unpredictable and all trading involves significant risk, including the potential loss of your entire invested capital.
The author of APEX ELITE is not a licensed financial advisor, broker, dealer, or investment professional. Nothing in this indicator or its documentation should be interpreted as personalized investment advice tailored to your individual financial situation, risk tolerance, or investment objectives.
YOU are solely responsible for all trading decisions you make.
Always conduct your own independent research and due diligence.
Always use proper risk management — including position sizing and stop-loss orders.
Never trade with money you cannot afford to lose.
If you are uncertain about any aspect of trading or investing, consult a licensed financial professional in your jurisdiction.
By adding this indicator to your chart, you acknowledge that you have read and understood this disclaimer, and that any trading decisions you make based on or influenced by this indicator are entirely your own responsibility.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Pine Script v6 · Not Financial Advice · Educational Use Only
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
EOF Indicator

Bot Webhook v8.4 [BTC]Bot Webhook v8.4 - Optimized Multi-Timeframe Signal Generator
========================================
ENGLISH (EN)
========================================
Data-driven signal generation for BTC/USD with timeframe-specific filters (30S-20m), Keltner Squeeze Detection and Volatility Regime Recognition. Optimized from 136 signals + 9406 1m candles.
OVERVIEW
This script is the BTC/USD-specific version of Bot Webhook v8.4. It generates Long and Short signals with a confidence score and sends them as JSON alerts to a webhook endpoint. The symbol "BTCUSD" is hardcoded in the alert - ideal for use with an automated trading bot.
Base: v7.3 TF-specific filters (proven) + v8.0 Keltner/Regime (Squeeze SHORT only)
SIGNAL LOGIC
LONG Signals (v7.3 Base):
- RSI < TF-specific threshold (Oversold)
- Stochastic K < TF-specific threshold
- RSI Slope > TF-specific threshold (Momentum reversal)
- ADX < TF-specific threshold (no excessive counter-trend)
- Proven performance: 68.2% $20-rate, R/R 1.48x
SHORT Signals (v7.3 Base + Keltner Squeeze):
- RSI > TF-specific threshold (Overbought)
- Stochastic K > TF-specific threshold
- RSI Slope < TF-specific threshold (Momentum reversal)
- Squeeze SHORT: Bollinger inside Keltner + bearish momentum
- Proven performance: 53.8% $20-rate, R/R 1.39x (Squeeze)
INDICATORS
- EMA 20/50/200 (Trend detection + filter)
- RSI 14 + RSI Slope (Momentum + direction change)
- Stochastic RSI (Overbought/Oversold conditions)
- MACD 12/26/9 (Momentum confirmation)
- Bollinger Bands 20/2.0 (Volatility + Squeeze Detection)
- Keltner Channel 20/1.5 (Squeeze Detection)
- ADX 14 (Trend strength)
- ATR 14 (Stop Loss / Take Profit calculation)
- Volume SMA 20 (Volume confirmation)
REGIME DETECTION
Trend Regime (EMA-based):
- STRONG_TREND_UP / STRONG_TREND_DOWN
- WEAK_TREND_UP (BLOCKED - 0% success rate!)
- WEAK_TREND_DOWN / NEUTRAL
Volatility Regime (ADX + ATR Percentile):
- TRENDING_HIGH_VOL / TRENDING_LOW_VOL
- SQUEEZE_BUILDING / BREAKOUT_IMMINENT
- RANGING_HIGH_VOL / RANGING_LOW_VOL
- TRANSITIONAL
CONFIDENCE CALCULATION
Base confidence from verified win rates per timeframe (0.72-0.92)
Modifiers:
+ Extreme RSI/StochK values (+0.03 to +0.05)
+ Trending High Vol Regime (+0.04)
- Ranging High Vol Regime (-0.08)
- Squeeze Building (-0.03)
- Counter-trend (-0.10)
- Low Volume (-0.05)
Min. confidence for alert: 70% (adjustable)
STOP LOSS / TAKE PROFIT
Base trades: ATR x 1.5 (SL) / ATR x 2.5 (TP) = R/R 1:1.67
Squeeze trades: ATR x 1.2 (SL) / ATR x 3.0 (TP) = R/R 1:2.5
TIMEFRAMES
Supported: 30S, 45S, 1m-20m (each with individually optimized thresholds)
Best TFs: 30S (47.1%), 45S (34.8%), 12m+ (33%+)
4m: LONG + SHORT disabled (no data)
WEBHOOK ALERT FORMAT (JSON)
{"signal":"long/short", "symbol":"BTCUSD", "timeframe":"...", "price":..., "source":"Bot_Webhook_v84", "confidence":..., "metadata":{"entry":..., "stop_loss":..., "take_profit":..., "atr":..., "adx":..., "rsi":..., "rsi_slope":..., "stoch_k":..., "signal_type":"...", "strategy":"...", "regime":"...", "vol_regime":"...", "expected_wr":"..."}}
SETUP
1. Apply script to BTCUSDT/BTCUSD chart
2. Select desired timeframe (30S-20m)
3. Create alert and enter webhook URL
4. Create a separate alert for each timeframe
Other versions available: ETH, SOL
AUTOMATED TRADING BOT
Want to automate these signals? A fully automated trading bot is available that processes the webhook alerts from this script and executes trades automatically - including risk management, position sizing, regime filtering and smart signal validation.
- Full bot with live trading or paper trading mode
- Processes all signals from this indicator automatically
- Built-in risk management with ATR-based SL/TP
- Multi-timeframe support (30S-20m)
More info: futuresbot.de
Or send me a direct message here on PulseWire!
DISCLAIMER: This strategy is for educational purposes only. Past performance does not guarantee future results. Always use proper risk management.
========================================
DEUTSCH (DE)
========================================
Datengetriebene Signalgenerierung fuer BTC/USD mit TF-spezifischen Filtern (30S-20m), Keltner-Squeeze-Detection und Volatility-Regime-Erkennung. Optimiert aus 136 Signalen + 9406 1m-Candles.
UEBERBLICK
Dieses Script ist die BTC/USD-spezifische Version des Bot Webhook v8.4. Es generiert Long- und Short-Signale mit Confidence-Score und sendet diese als JSON-Alert an einen Webhook-Endpunkt. Das Symbol "BTCUSD" ist fest im Alert eingebettet - ideal fuer den Einsatz mit einem automatisierten Trading-Bot.
Basis: v7.3 TF-spezifische Filter (bewaehrt) + v8.0 Keltner/Regime (nur Squeeze SHORT)
SETUP
1. Script auf BTCUSDT/BTCUSD Chart anwenden
2. Gewuenschten Timeframe waehlen (30S-20m)
3. Alert erstellen und Webhook-URL eintragen
4. Fuer jeden Timeframe einen separaten Alert erstellen
Weitere Versionen verfuegbar: ETH, SOL
AUTOMATISIERTER TRADING-BOT
Du moechtest diese Signale automatisieren? Es gibt einen vollautomatischen Trading-Bot, der die Webhook-Alerts dieses Scripts verarbeitet und Trades automatisch ausfuehrt - inklusive Risikomanagement, Positionsgroesse, Regime-Filterung und smarter Signal-Validierung.
- Kompletter Bot mit Live-Trading oder Paper-Trading-Modus
- Verarbeitet alle Signale dieses Indikators automatisch
- Integriertes Risikomanagement mit ATR-basiertem SL/TP
- Multi-Timeframe-Unterstuetzung (30S-20m)
Mehr Infos: futuresbot.de
Oder schreib mir eine persoenliche Nachricht hier auf PulseWire!
HAFTUNGSAUSSCHLUSS: Diese Strategie dient zu Bildungszwecken. Vergangene Performance garantiert keine zukuenftigen Ergebnisse. Nutze stets ein angemessenes Risikomanagement.
Indicator

Indicator

ABC Pattern - Buy & Sell Zones IT'S OPEN SOURCE FOR YOU
📊 ABC Pattern — Mathematical Price Target Formula
What is the ABC Pattern?
The ABC pattern is a price structure that identifies high-probability buy and sell zones using three pivot points: A, B, and C. Instead of relying on subjective analysis, this indicator uses a simple mathematical formula to calculate an exact price target — removing guesswork from your trading.
🧠 The Logic Behind It
Price never moves in a straight line. It swings up and down, creating a series of highs and lows. The ABC pattern captures one complete swing cycle and uses the relationship between those three points to project where price is likely to go next.
📐 The Formula
Target = (B × C) ÷ A
That's it. Three prices. One calculation. One target.
📈 Bullish ABC — Buy Zone Setup
Structure:
A (Low) → B (High) → C (Higher Low)
Rules:
A is the starting low
B is the peak above A
C is a pullback that holds above A (higher low = bullish structure)
The formula projects where price should reach after C
Example:
A = 100 (first low)
B = 150 (peak)
C = 120 (higher low pullback)
Target = (150 × 120) ÷ 100 = 180
Why does this work?
When C holds above A, it tells us buyers are stepping in at higher prices. The market structure is healthy. The formula uses the proportional relationship between the three pivots to project a mathematically derived target — not a random level.
Invalidation:
❌ A candle closes below C → pattern is cancelled. The higher low structure is broken, meaning sellers have taken control.
📉 Bearish ABC — Sell Zone Setup
Structure:
A (High) → B (Low) → C (Lower High)
Rules:
A is the starting high
B is the trough below A
C is a bounce that fails below A (lower high = bearish structure)
The formula projects the downside target from C
Example:
A = 200 (first high)
B = 150 (trough)
C = 180 (lower high bounce)
Target = (150 × 180) ÷ 200 = 135
Why does this work?
When C fails to reach A, it tells us sellers are entering at lower prices. The market is making lower highs — a classic bearish sign. The formula captures this momentum and projects the next logical price level.
Invalidation:
❌ A candle closes above C → pattern is cancelled. The lower high structure is broken, meaning buyers have reclaimed control.
⚙️ How the Indicator Works
Pivot Detection
The script automatically detects swing highs and lows using a configurable lookback period. A larger lookback finds bigger, more significant patterns. A smaller lookback finds more frequent, shorter-term setups.
Pattern Validation
Before drawing anything, the script checks three conditions:
Time sequence is correct (A → B → C in order)
Structure is valid (C is higher than A for bulls / lower for bears)
B is the extreme between A and C
What gets drawn on the chart:
A, B, C labels at each pivot with the price
Entry line at C level (where you look to trade)
Target line calculated by the formula
Colored zone between C and Target (your reward area)
Failure level — the line that invalidates the setup
% labels showing the move size of each leg
📋 Trading Guidelines
BullishBearishEntryNear C (higher low)Near C (lower high)Target(B × C) ÷ A(B × C) ÷ AInvalidationClose below CClose above CBiasUptrend structureDowntrend structure
⚠️ Important Notes
This is not a signal indicator. It identifies a mathematical structure. Always combine with your own analysis, volume, and market context.
Works on all timeframes and all assets (stocks, crypto, forex, commodities).
Adjust the Pivot Lookback setting based on your timeframe:
Scalping (1m–5m): Lookback 5–8
Intraday (15m–1H): Lookback 10–15
Swing (4H–Daily): Lookback 15–25
🔔 Alerts Included
✅ Bullish ABC pattern detected
✅ Bearish ABC pattern detected
⚠️ Bullish pattern failed (close below C)
⚠️ Bearish pattern failed (close above C)
The formula is simple. The discipline to follow it is what separates consistent traders from the rest. Indicator

Volatility-Adjusted Rate of Change [QuantAlgo]🟢 Overview
The Volatility-Adjusted Rate of Change (VA-ROC) is a momentum oscillator that normalizes price changes against current market volatility, helping traders identify meaningful momentum shifts, spot overbought/oversold extremes, and filter out noise caused by changing volatility regimes. By measuring how large a price move is relative to what's normal for the instrument, this indicator reveals genuine directional pressure that raw momentum readings often obscure.
🟢 How It Works
The indicator begins by calculating the single-bar price change and dividing it by the Average True Range over a configurable lookback period. This normalization step ensures that the same oscillator reading carries equal significance whether applied to a low-volatility blue chip or a highly volatile cryptocurrency, a concept absent from traditional rate of change indicators.
price_momentum = ta.change(close) / ta.atr(atr_length)
When price rises by an amount that is large relative to recent volatility, the normalized momentum produces a strong positive reading. Conversely, a decline that is modest in absolute terms but significant relative to the current ATR environment will register appropriately. This volatility-adjustment prevents the oscillator from generating inflated signals during high-volatility regimes or muted signals during quiet markets.
A sensitivity multiplier then scales the normalized value, allowing traders to compress or amplify the oscillator's range to suit their instrument and timeframe:
va_roc = calc_ma(price_momentum * sensitivity, ma_length, ma_type)
The scaled momentum is then smoothed using a configurable moving average (supporting SMA, EMA, WMA, RMA, HMA, VWMA, DEMA, and TEMA), which filters bar-to-bar noise while preserving the shape of genuine momentum waves. The smoothed output is the final VA-ROC value, plotted against a system of four threshold levels that define bullish, bearish, neutral, and extreme zones.
Momentum state is determined by the oscillator's position relative to these thresholds:
is_bullish = va_roc > upper_threshold
is_bearish = va_roc < lower_threshold
Crossings into bullish or bearish territory, zero-line crosses, and entries into extreme zones each generate distinct signals and corresponding alerts.
🟢 Key Features
The indicator is built around a threshold-based momentum framework with gradient-colored visualization, preset configurations, and a full alert system, all designed to give traders immediate clarity on momentum conditions without manual tuning.
1. Volatility Normalization: Unlike traditional ROC or momentum oscillators that produce raw price differences, VA-ROC divides every price change by the ATR, creating a dimensionless reading that remains consistent across instruments, timeframes, and volatility regimes. A reading of +1.0 always means "price moved one ATR's worth in a single bar", whether you're trading forex, equities, or crypto. This eliminates the need to recalibrate threshold levels when switching between assets.
2. Adaptive Threshold Zones: Four configurable levels (Upper Extreme, Upper Threshold, Lower Threshold, and Lower Extreme) divide the oscillator into five distinct momentum zones. The neutral zone between the upper and lower thresholds represents normal market fluctuation. Crossings above the upper threshold confirm bullish momentum, while crossings below the lower threshold confirm bearish momentum. The extreme levels mark climactic conditions where momentum is unusually powerful, often coinciding with exhaustion points or the early stages of a strong trend continuation.
3. Preset Configurations: Three built-in presets automatically optimize the sensitivity, ATR lookback, MA type, and smoothing length for different trading styles. Default provides balanced readings suited for swing trading on 4H and daily charts. Fast Response amplifies small moves with minimal smoothing for intraday scalping. Smooth Trend compresses the oscillator and applies heavier smoothing to highlight only significant directional moves for position trading.
4. Built-in Alert System: Comprehensive alerts covering all key momentum events, including bullish and bearish momentum confirmation, zero-line crossovers in both directions, and entries into upper and lower extreme zones. A combined momentum direction change alert is also included. All alerts carry exchange, ticker, and interval placeholders for seamless integration with notification workflows.
5. Visual Customization: Choose from 5 color presets (Classic, Aqua, Cosmic, Cyber, Neon) or create a fully custom color scheme using individual bullish, bearish, and neutral color pickers. Optional price bar coloring overlays the oscillator's momentum colors directly onto your main chart candles, tinting bars bullish or bearish based on the current threshold state while leaving neutral bars uncolored, providing instant trend confirmation without switching panels.
Indicator

Volatility-Gated Trend Oscillator [QuantAlgo]🟢 Overview
The Volatility-Gated Trend Oscillator identifies statistically significant trend conditions by measuring price deviation from a dynamic baseline and filtering out normal market noise through an adaptive volatility floor. It calculates a moving average of the chosen type as a baseline, then measures how far price has deviated from it relative to average absolute deviation to define a noise threshold. Only when price breaks decisively beyond this threshold is a trend state confirmed, helping traders distinguish genuine momentum from random noise across different timeframes and markets.
🟢 How It Works
The indicator's core methodology lies in its dual-layer approach combining deviation measurement with volatility-gated filtering, where trend confirmation requires price movement to exceed statistically meaningful thresholds.
First, a configurable moving average is calculated to establish a dynamic baseline reflecting the underlying trend at the chosen sensitivity level:
baseline = get_ma(src, sensitivity, ma_type)
raw_diff = src - baseline
Then, the average absolute deviation from the baseline is measured over the same period and scaled by a user-defined multiplier to construct an adaptive noise floor, which is the minimum price deviation required to confirm a trend signal:
noise_floor = ta.sma(math.abs(raw_diff), sensitivity) * noise_mult
The trend state is then determined by comparing raw deviation against this noise floor, with a decay mechanism applied when price re-enters the neutral zone to avoid abrupt reversals:
if raw_diff > noise_floor
trend_state := 1
locked_val := raw_diff
else if raw_diff < -noise_floor
trend_state := -1
locked_val := raw_diff
else
locked_val := locked_val * 0.9
The locked deviation value is then normalized by ATR to make the oscillator comparable across instruments and volatility regimes, and smoothed with a short WMA to reduce micro-fluctuations in the final output:
normalized_val = locked_val / ta.atr(sensitivity)
final_osc = ta.wma(normalized_val, 5)
This creates a robust momentum oscillator that only registers trend conditions when price makes structurally significant moves beyond typical noise, while the ATR normalization ensures readings remain meaningful and consistent regardless of the underlying instrument's price scale or volatility level.
🟢 Signal Interpretation
▶ Bullish Trend (Oscillator Rising Above Zero with Bullish Color): When price deviation breaks above the positive noise floor, the oscillator enters bullish mode with green/bullish coloring across all visual elements = Confirmed upward momentum signal for trend-following long positions. The trend remains bullish until price deviation falls below the negative noise floor, allowing traders to stay positioned through normal consolidations without premature exits on minor pullbacks that remain within the noise boundary.
▶ Bearish Trend (Oscillator Falling Below Zero with Bearish Color): When price deviation breaks below the negative noise floor, the oscillator enters bearish mode with red/bearish coloring across all visual elements = Confirmed downward momentum signal for short positions or long exit signals. The trend remains bearish until deviation exceeds the positive noise floor, enabling traders to maintain directional bias through corrective bounces that stay within the threshold boundaries.
🟢 Features
▶ Preconfigured Presets: Three optimized parameter sets tailored for different trading styles and timeframes. "Default" delivers balanced trend detection for swing trading on 4-hour and daily charts, filtering minor noise while remaining responsive to meaningful momentum shifts. "Fast Response" uses a reactive EMA baseline with a tighter noise floor for intraday and scalping timeframes, generating earlier signals suited to active traders on 5-minute to 1-hour charts. "Smooth Trend" applies a smooth, lag-reduced HMA baseline with a demanding noise threshold for position trading on daily and weekly charts, confirming only major directional shifts with minimal false positives.
▶ Built-in Alerts: Three alert conditions enable automated monitoring of trend transitions without constant chart observation. "Bullish Trend Signal" triggers when the oscillator first enters a confirmed bullish state, alerting for potential long entries. "Bearish Trend Signal" activates when the oscillator first enters a confirmed bearish state, signaling potential short entries or long exits. "Trend Direction Changed" provides a combined alert for any trend transition regardless of direction, allowing traders to monitor both bullish and bearish opportunities through a single alert setup.
▶ Visual Customization: Six color presets (Classic, Aqua, Cosmic, Cyber, Neon, plus Custom) accommodate different chart themes and aesthetic preferences, with coordinated bullish and bearish color schemes applied consistently across all indicator elements. A layered luminance fill system creates graduated visual depth around the main oscillator line using four fill zones at progressively increasing transparency, making trend strength and direction immediately readable at a glance. Optional bar coloring tints price bars with the active trend color during confirmed bullish and bearish periods, providing instant overhead visual confirmation of trend state without requiring direct reference to the oscillator panel below.
Indicator

Price Percentile Heatmap [QuantAlgo]🟢 Overview
This indicator visualizes where price currently stands within its recent historical distribution, displayed as a dynamic gradient heatmap directly on the chart. It is built on the concept of percentile ranking: rather than using lagging momentum oscillators or fixed overbought/oversold thresholds, it measures price relative to every bar within a user-defined lookback window and expresses that position as a smooth, continuous gradient. The result is an at-a-glance read of whether price is historically cheap, historically expensive, or somewhere in between, all without leaving the main chart.
The defining visual feature is the thermal color gradient applied to the price bars, background, and source line. Bullish colors represent price trading near the top of its recent range, signaling historically elevated conditions. Bearish colors represent price trading near the bottom of its range, signaling historically depressed conditions. A built-in Heat Thermometer reinforces this reading by showing exactly where the current percentile rank falls along the full spectrum in real time.
🟢 How It Works
The foundation of the indicator is a per-bar percentile rank calculated over a rolling lookback window. For each bar, the selected price source is compared against every value within the lookback period to determine what percentage of historical bars traded below the current price:
percentile_rank = ta.percentrank(price_source, lookback_length)
A rank of 100 means the current price is higher than every bar in the lookback sample. A rank of 0 means it is lower than all of them. A rank of 50 places price exactly at the median of its recent distribution. This single value drives every visual output in the indicator.
The raw rank is then mapped directly into a continuous color gradient, transitioning smoothly from the bearish color at rank 0 to the bullish color at rank 100:
gradient_color = color.from_gradient(percentile_rank, 0, 100, bearish_color, bullish_color)
Because the rank is recalculated on every bar using a rolling window, the gradient never relies on fixed thresholds or static levels. It adapts continuously to the most recent price history, meaning the same absolute price level can read bullish in one market environment and bearish in another depending on what has happened within the lookback period.
The lookback length is the primary tuning parameter. Short periods (10 to 30) make the rank reactive to recent moves and suit scalping and intraday setups. Medium periods (50 to 100) provide a balanced read suitable for swing trading. Long periods (150 to 500) produce a slow-moving, macro-level view best suited for position trading and identifying historically extreme conditions.
🟢 Key Features
1. Thermal Color Gradient
Every visual element on the chart, including the source line, the bar colors, and the background tint, reflects the current percentile rank through a smooth color transition.
▶ Bullish Color: Applied when price ranks high within its recent distribution, drawing attention to historically elevated price levels.
▶ Bearish Color: Applied when price ranks low, highlighting historically depressed conditions and potential mean-reversion or continuation setups.
▶ Bar Coloring: Each individual candlestick is colored according to the current rank, giving instant bar-by-bar feedback without requiring a separate panel.
▶ Background Coloring: The full chart canvas receives a semi-transparent tint that reinforces the heatmap reading across the entire visible price area. Transparency is fully adjustable so price action is never obscured.
▶ Color Presets: Six pre-configured schemes, Classic, Aqua, Cosmic, Cyber, Neon, and Custom, allow you to match the heatmap to any chart theme or personal preference.
2. Heat Thermometer
An optional thermometer panel displays the full bearish-to-bullish color spectrum and marks exactly where the current percentile rank sits along that spectrum with a real-time arrow indicator.
▶ Real-Time Positioning: The arrow updates on every bar, giving an immediate visual anchor for the current rank without needing to read a number.
▶ Resolution: The number of gradient segments in the thermometer is adjustable from 5 to 20, letting you choose between a clean simplified display or a finer, smoother gradient.
▶ Position and Size: The thermometer can be placed in any of nine chart positions and its text size is independently adjustable, making it easy to integrate into dense multi-indicator layouts or standalone setups.
🟢 Practical Applications
▶ Mean Reversion Setups: When price reaches an extreme low percentile rank, it is historically cheap relative to recent bars, a potential entry signal for mean reversion strategies. The opposite applies at high ranks.
▶ Trend Confirmation: In a strong trend, the percentile rank will persistently hue toward one color. A sustained bullish gradient confirms trend strength; a persistent bearish gradient confirms sustained selling pressure.
▶ Multi-Timeframe Alignment: Apply the indicator across multiple timeframes and look for gradient agreement. When both a higher and lower timeframe show the same extreme color, the percentile signal carries significantly more weight. Indicator

Adaptive Entropy Trend [QuantAlgo]🟢 Overview
Adaptive Entropy Trend is a trend-following indicator built on Shannon information theory rather than conventional price averaging. It quantifies the statistical disorder of recent log returns to determine whether the market is in a directional regime or a random one, then feeds this entropy reading into every layer of the system simultaneously, helping traders identify directional shifts that are validated by both low-entropy momentum conditions and genuine volatility expansion across different timeframes and markets.
🟢 How It Works
The foundation of the indicator is a per-bar entropy calculation built from the distribution of log returns over the lookback window. Log returns are computed and their range is divided into equal-width histogram bins:
logReturn = math.log(close / close )
minReturn = ta.lowest(logReturn, lookbackLen)
maxReturn = ta.highest(logReturn, lookbackLen)
returnRange = maxReturn - minReturn
Each historical return within the lookback is assigned to a bin, building a frequency distribution. Shannon entropy is then calculated from the probability of each bin, measuring how uniformly returns are spread across the range:
probability = array.get(binCounts, i) / lookbackLen
if probability > 0
entropy := entropy - probability * math.log(probability) / math.log(2)
A uniform distribution produces maximum entropy, reflecting a chaotic, non-directional market. A concentrated distribution produces low entropy, reflecting a market where returns are clustering in a consistent direction. The raw entropy is normalized against the theoretical maximum for the bin count to produce a stable 0-1 score:
normalizedEntropy = maxEntropy > 0 ? entropy / maxEntropy : 0.5
This score is then wired directly into the EMA smoothing factor. Higher entropy lengthens the effective period of the EMA, insulating it from noise. Lower entropy shortens it, allowing the EMA to track price closely during genuine trends:
adaptiveAlpha = 2.0 / (lookbackLen * (0.3 + normalizedEntropy * 1.4) + 1.0)
adaptiveEma := na(adaptiveEma) ? close : adaptiveEma + adaptiveAlpha * (close - adaptiveEma)
The same entropy reading drives band width through an inverted trend strength factor. Unlike volatility-based bands that widen during noise, these bands widen specifically during trending conditions and tighten during choppy ones:
trendStrength = 1.0 - normalizedEntropy
fastBandWidth = atr * fastMultiplier * (0.5 + trendStrength)
slowBandWidth = atr * slowMultiplier * (0.5 + trendStrength)
Finally, trend state is determined when price breaks beyond the inner bands, and transitions are tracked for alert conditions:
if close > innerUpper
trendDirection := 1
else if close < innerLower
trendDirection := -1
trendTurnedBullish = trendDirection == 1 and trendDirection != 1
trendTurnedBearish = trendDirection == -1 and trendDirection != -1
This creates a self-regulating trend system where the EMA baseline, the trigger threshold, and the visual envelope all adapt together from the same entropy source, rather than using a fixed center with adaptive edges or vice versa.
🟢 Signal Interpretation
▶ Bullish Trend (Price Above Inner Upper Band, Green): When price closes above the inner upper band, the indicator switches to bullish mode with bullish coloring across all visual elements = Confirmed uptrend signal for trend-following long positions. Because the inner band expands in low-entropy trending conditions, a bullish confirmation in a genuinely directional market requires a more meaningful breakout than in a noisy one. The trend remains bullish until price breaks below the inner lower band, allowing traders to stay positioned through normal pullbacks that remain within the band range.
▶ Bearish Trend (Price Below Inner Lower Band, Red): When price closes below the inner lower band, the indicator switches to bearish mode with bearish coloring throughout all visual elements = Confirmed downtrend signal for short positions or long exit signals. The adaptive band floor ensures the trigger threshold in choppy, high-entropy markets is tighter, reducing the risk of false breakdowns on thin directional moves. The trend remains bearish until price breaks above the inner upper band.
▶ Neutral Zone (Price Between Inner Bands): When price trades between the inner upper and lower bands, the indicator holds its previous trend direction = Continuation of existing trend during consolidation or normal volatility retracements. This prevents whipsaws during sideways action by requiring price to make a statistically meaningful move beyond the entropy-scaled band boundaries rather than reacting to minor crosses of the adaptive EMA centerline.
🟢 Features
▶ Preconfigured Presets: Three optimized parameter sets for different trading approaches and timeframes. "Default" provides balanced trend detection for swing trading on 4-hour and daily charts, "Fast Response" delivers quicker trend signals for intraday trading on 1-minute to 1-hour charts, and "Smooth Trend" focuses on major trend changes for position trading on daily to weekly timeframes.
▶ Built-in Alerts: Three alert conditions enable automated monitoring of trend changes without constant chart watching. "Bullish Trend Signal" triggers when the indicator switches to bullish mode after price breaks above the inner upper band, alerting for potential long entries. "Bearish Trend Signal" activates when the indicator switches to bearish mode after price breaks below the inner lower band, signaling potential short entries or long exits. "Trend Direction Changed" provides a combined alert for any trend transition regardless of direction, allowing traders to monitor both bullish and bearish opportunities with a single alert setup.
▶ Visual Customization: Six color presets (Classic, Aqua, Cosmic, Cyber, Neon, plus Custom) accommodate different chart backgrounds and aesthetic preferences, with coordinated bullish, bearish, and neutral color schemes applied across all indicator elements. Inner and outer band fills create a two-layer gradient envelope around the adaptive EMA, with the inner zone between the two bands rendered slightly more transparent than the outer zone to preserve natural depth, both controlled by a single fill transparency input (0-100%) so the visual weight of the envelope can be adjusted without disrupting the gradient relationship. Optional bar coloring tints price bars with trend-appropriate colors during bullish and bearish periods, enabling instant visual confirmation of trend state across multiple timeframes without switching between chart and indicator panels.
Indicator
