Quantum Imbalance Trap [MarkitTick]💡 This advanced analytical tool is a comprehensive market structure and momentum suite designed to identify high-probability institutional-style footprints through structural price imbalances, relative volume anomalies, and dynamic volatility tracking. By integrating a sophisticated multi-layered filtering engine, it provides traders with a complete visual and statistical ecosystem, featuring dynamic risk-to-reward mapping, session-specific filters, advanced RSI divergence checks, and automated JSON webhook alerts for seamless algorithmic integration.
✨ Originality and Utility
What sets this tool apart from conventional momentum oscillators is its holistic, data-driven approach to signal validation. It does not merely detect large candles; it synthesizes the candlestick's body-to-range ratio, compares localized volume to a historical moving average, and optionally requires structural liquidity sweeps and RSI divergences before flagging an event. Furthermore, the inclusion of fully formatted, localized JSON alerts containing precise targets and confidence scores makes this indicator highly utilitarian for traders utilizing automated execution bots. The real-time, non-invasive dashboard completely eliminates the need for manual risk-to-reward drawing tools, drastically reducing cognitive load.
🔬 Methodology and Concepts
The core engine operates on a strict, multi-variable confluence matrix:
Imbalance & Volume Detection: Evaluates the specific relationship between a candle's real body and its total range (high-to-low). A signal triggers only if this ratio exceeds a user-defined threshold simultaneously with a volume surge that breaches a defined multiplier of the historical volume SMA.
Momentum & Trend Alignment: Utilizes a fast versus slow Simple Moving Average crossover to dictate the immediate micro-trend, ensuring signals fire in the direction of the active order flow.
RSI Divergence: An optional mechanical filter that compares recent price action against a 14-period RSI to locate classic bullish or bearish divergences, adding a layer of exhaustion-reversal logic.
Liquidity Sweeps: Analyzes recent price nodes to determine if local swing highs or lows were structurally breached (swept) prior to the imbalance, indicating potential trap mechanics.
MTF Validation: Safely references a non-repainting higher timeframe (HTF) 20-period SMA. It dynamically penalizes the mathematical "Confidence Score" if the micro-signal contradicts the macro trend.
🎨 Visual Guide
• Chart Elements
Entry Zone Boxes: Semi-transparent cyan boxes indicating the optimal dynamic re-entry area based on a 0.35x ATR modifier.
Signal Labels: Upward (cyan) or downward (orange) triangles marking the exact trigger candle with localized text.
Risk-to-Reward Lines: Solid colored lines for the Entry point, dashed deep pink lines for the Stop Loss (SL), and dotted lines for Take Profit (TP) levels 1, 2, and 3.
Price Labels: Text annotations extending rightward from the action, detailing the exact price coordinate and R-multiple for each respective TP level.
• On-Chart Dashboard
Positioned in the top-right corner with a sleek, dark-themed background and custom-colored text mappings.
Row-by-Row Metrics: Displays the asset ticker, localized Micro Trend, HTF Macro Trend, Imbalance Percentage, Volume Spike Percentage, and an aggregated Confidence Score using active visual block meters (█/░).
Live Tracking: Monitors the active trade state (Long/Short/Idle), current ATR value, dynamically tracked Entry/SL/TP prices, and a live tracking of the floating Risk-to-Reward (R) metric.
📖 How to Use
Wait for a definitive signal label to plot on the chart, confirming that the baseline imbalance, volume, and enabled filters have aligned.
Consult the on-chart dashboard to review the "Confidence Score." A higher percentage (closer to 100%), supported by solid block meters and HTF alignment, indicates a structurally superior setup.
Utilize the automatically generated Entry, Stop Loss, and TP lines to establish risk parameters before executing a position. The shaded zone box identifies an optimal area to scale in.
For algorithmic setups, configure your external bot to parse the automated JSON alert strings to execute trades completely hands-free based on the indicator's defined R-multiples.
⚙️ Inputs and Settings
Every aspect of the logic and visual output is fully customizable through categorized input groups:
• Signal Detection
Imbalance Lookback (Bars): Dictates the lookback window for volume averages, momentum SMAs, and localized swing structures.
ATR Period: The lookback length for the Average True Range calculation, governing dynamic SL distances.
Body-to-Range Threshold: The minimum percentage the solid candle body must occupy relative to its entire wick-to-wick range.
Volume Spike Multiplier: The exact threshold multiplier by which current volume must exceed the volume SMA.
RSI Divergence Confirmation: A toggle to mandate an active RSI divergence for signal validation.
• Smart Money Concepts
Require Liquidity Sweep: When toggled, the engine mandates a structural sweep of the recent highest high or lowest low before plotting a signal.
• Order Flow
Higher Timeframe Alignment: Mandates that the localized signal matches the structural bias of a higher timeframe.
Higher Timeframe: A dropdown selection to dictate the exact MTF resolution referenced (e.g., 60 minutes).
Dynamic Re-entry Zone: Toggles the persistent forward extension of the Entry Zone boxes for continued visual reference.
• Risk Management
Stop Loss ATR Multiplier: Defines the precise mathematical distance of the stop loss line, scaling automatically with asset volatility.
Take Profit 1, 2, and 3 (R-Multiple): Exact floating-point settings to define the distances of targets based strictly on Risk-Reward multiples.
• Alerts & Sessions
Bullish / Bearish Signal Alert: Toggles for activating the fully structured JSON alert webhooks.
Enable Session Filter: Activates strict time-based operational windows.
London / New York Open: Specific boolean toggles to restrict signal detection exclusively to the London (07:00–10:30 UTC) and/or New York (12:30–15:00 UTC) trading sessions.
• Dashboard & Visual Style
Show Entry Zone / Show Price Labels: Toggles to hide or display specific on-chart visual elements to manage chart clutter.
Background / Text Colors: Dedicated color pickers for the dashboard table aesthetics.
Bullish / Bearish / Target Colors: Complete hex/RGB customization for trend alignments, signal labels, and every dynamically drawn Risk-to-Reward line.
🔍 Deconstruction of the Underlying Scientific and Academic Framework
The algorithmic foundation of this indicator heavily relies on volume-weighted price kinematics and statistical normalization. By isolating the body-to-range differential, the code mathematically abstracts the concept of aggressive, one-sided market participation, filtering out symmetric volatility (dojis) in favor of asymmetric momentum. The integration of relative volume acts as an independent confirming variable, a critical tenet in auction market theory, which postulates that true price discovery requires heavy transactional density.
The "Confidence Score" utilizes a multivariate linear normalization technique. It aggregates disparate data arrays—imbalance depth, volume intensity, and momentum velocity—into a bounded 0-100 percentage scale. Crucially, it applies a deterministic penalty if the micro-trend contradicts the macro-trend, rooted in the fractal nature of time-series analysis where higher-degree trends exhibit stronger gravitational pull on price action. Finally, the risk mechanics are anchored in dynamic expectancy models; by utilizing the Average True Range (ATR) multiplied by user-defined R-variables, the script ensures that standard deviation and local variance are constantly factored into target projection, honoring the mathematical realities of market heteroskedasticity.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. We expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Indicator

Bitcoin Statistical Forecaster + Power Law [Gabremoku]Bitcoin Statistical Forecaster + Power Law combines two analytical layers into a single BTC-focused overlay.
The first layer is a statistical analog forecaster. It scans historical Bitcoin data and searches for the closest matches to the most recent pattern using a weighted multi-feature distance model based on candle structure, volatility, momentum, trend distance, and structural position relative to the Bitcoin power-law range.
The second layer is a long-term Bitcoin power-law framework built from three structural curves: Floor, Mid-Stair, and Fair Value. These curves are plotted directly from the power-law formula and are not altered by the forecasting engine.
The script is not a simple mashup of two unrelated tools. The power-law layer is used as structural context inside the forecaster itself: it contributes to analog selection, regime comparison, optional forecast anchoring, and optional probability adjustment. The goal is to make historical pattern matching more aware of where price is located inside Bitcoin’s broader long-term structure.
How the forecast works:
The script compares the latest pattern against historical BTC windows.
It keeps the best analogs according to the selected similarity method.
These analogs are separated into Bull, Central, and Bear groups using the final return at the selected forecast horizon.
For each step in the projection, each scenario path is built from the weighted average of its own analog group, so the paths remain internally coherent instead of mixing bullish and bearish trajectories.
An optional structural bias can softly pull projected prices toward the power-law range over time. This effect fades in progressively across the forecast horizon, so near-term projections are not abruptly distorted.
Scenario probabilities are derived from the same percentile thresholds used to build the Bull, Central, and Bear paths. This keeps the displayed percentages aligned with the projected paths shown on the chart.
The script is designed for daily Bitcoin charts and works best when enough historical data is available. It is a probabilistic context tool, not a prediction guarantee, and it should be used together with risk management and independent market analysis.
Suggested usage:
Use the power-law curves to identify long-term structural position.
Use the forecast paths to estimate how similar historical BTC conditions evolved.
Compare current price location, structural regime, and scenario probabilities before forming a directional bias.
Treat the output as a contextual model, not as a standalone trading signal. Indicator

Market Structure & LiquidityMARKET STRUCTURE & LIQUIDITY — Calibrated Zones, Premium/Discount & Setup Grade
================================================================================
WHAT THIS SCRIPT IS
A single price-action framework that maps the structural read of a chart and
then measures it. It plots market structure (break of structure and change of
character), supply/demand order blocks, fair value gaps, resting liquidity
(equal highs and lows) and the sweeps that take it, premium/discount with an
optimal-entry band, a higher-timeframe bias, and a rolling volume profile. On
top of those objects it does three things most structure tools do not: it
validates every structure break, it scores each zone by confluence and quality,
and it reports — using past data on the current symbol only — how often each
zone type has actually been respected, with statistical confidence intervals.
The levels are the raw material; the framework adds a measured read of which
ones to trust.
WHY THE COMPONENTS ARE COMBINED (how the parts work together)
These are not independent indicators bolted together. They describe one process
— how large participants build positions: rest liquidity, take it, displace
price, and leave an inefficiency behind — and each layer covers a blind spot of
the others, feeding one combined decision:
- Market structure (swing and internal) gives trend context and the moment it
shifts. Because raw break detection is noisy, a break is only counted when it
shows real displacement (range expansion with body, or a volatility
compression followed by a release), closes beyond the level with body rather
than leaving a rejection wick, and breaks a tight, recent (quality) pivot.
This removes most false breaks before anything else is drawn.
- Regime context (efficiency ratio + ADX + volatility clustering + a whipsaw
score) conditions how far to trust a read: continuation breaks are reliable in
a trending regime, reversals are more reliable in a range, and a choppy regime
weights everything down. Structure on its own cannot tell you this.
- Liquidity (equal highs/lows, sweeps, and inducement) marks where stops rest
and the moment they are taken — the trigger that typically precedes a real
move, and the event that validates a nearby zone.
- Order blocks and fair value gaps mark the origin of the displacement and the
inefficiency price tends to revisit. A zone that forms on a sweep, on a
high-volume node, in the correct half of the range scores highest — which is
exactly why liquidity, the volume profile and premium/discount all feed the
zone score rather than living in separate panes.
- Volume profile (point of control, high- and low-volume nodes, and untested
"naked" points of control) tells you whether a zone sits on acceptance (tends
to hold) or on a thin gap (tends to slice), and marks magnet levels price is
drawn back toward.
- Premium/discount and the OTE band frame every zone as expensive or cheap
relative to the current dealing range, so a long in discount and a short in
premium are favoured.
- The confluence engine and setup grade fuse structure direction, a recent
sweep, zone quality, node type, premium/discount alignment, higher-timeframe
bias and a momentum-divergence confirmation into one A/B/C read per zone, so
the chart self-prioritises instead of leaving you to weigh eight things by eye.
- Calibration measures, on past bars only, how often each zone type produced a
meaningful reaction on the current symbol, and reports it with Wilson
confidence intervals — so reliability is earned per instrument, not assumed.
In one sentence: structure says direction, regime says whether to believe it,
liquidity says when, the zones say where, premium/discount says whether it is
worth it, the grade fuses them, and the calibration keeps the whole thing honest.
HOW IT WORKS (mechanics, briefly)
Pivots use the standard left/right confirmation, so structure is non-repainting:
a break is only labelled after the pivot is confirmed and the close validates it.
Order blocks anchor to the last opposing candle before a validated break, are
scored on formation, and are re-scored for confluence on the most recent bar.
Calibration records, the first time a zone is tagged, whether price then travels
a chosen ATR multiple in the zone's direction within a fixed horizon, and
aggregates that into the respect rate shown on the dashboard. All thresholds are
ATR-relative, so nothing is tied to a particular price scale.
HOW TO USE IT
1. Read the dashboard headline: the SETUP grade and the structure bias.
2. Favour higher-grade setups — a validated structure direction, a recent sweep,
a fresh high-quality zone sitting on a volume node, in discount for longs or
premium for shorts, with higher-timeframe agreement.
3. Use the OTE band for entry context and an opposing fair value gap as a
logical target.
4. Check the respect rows. If order blocks or fair value gaps rarely hold on this
symbol, weight the read down accordingly.
5. Treat everything as descriptive context, not a signal to act on.
USE ON ANY MARKET
The High / Low / Close source inputs let you drive structure, liquidity and
premium/discount from any series (standard candles, Heikin-Ashi, or another
source), so the framework applies to stocks, indices, futures, forex and crypto.
A volume-borrow input supplies volume for symbols that report none.
WHAT MAKES IT ORIGINAL
The contribution is the closed loop, not the individual objects, which are
common to price-action analysis. Here, validated structure and liquidity feed a
per-zone confluence and quality score and a single setup grade, and a past-only
calibration tracker reports each zone type's actual respect rate on the current
symbol with confidence intervals. That turns a set of drawing tools into a
measured, self-prioritising read.
SETTINGS WORTH KNOWING
- Break Validation: turn displacement, anti-wick and pivot-quality gates on/off
and tune their strictness to make structure more or less selective.
- Volume Profile / Nodes: bins, window and HVN/LVN percentiles control node
tagging; naked POC tracking is session-based and turns itself off when the
chart is not intraday.
- Confluence & Setup Grade: cluster tolerance controls how close levels must be
to count as confluent.
- Calibration: horizon and minimum reaction define what counts as a "respected"
zone.
- Visuals: theme is auto/dark/light; grade-weighted opacity makes strong zones
bold and weak ones faint; the identity strip shows the script name, symbol and
timeframe.
LIMITATIONS
Pivots confirm after the right-bars lag, so forming structure is not drawn until
confirmed. Volume layers require real or borrowed volume. Calibration describes
past behaviour only — it is not a backtest and not a probability of future
results. Every read is probabilistic context, never a certainty.
DISCLAIMER
This is a study/indicator for chart analysis and education only. It is not a
strategy, not a recommendation, and not financial advice. It places no orders
and guarantees no outcome. Markets carry risk, and the past behaviour of a level
does not assure its future behaviour. Do your own research and manage your own
risk.
Indicator

Inducement Engine Liquidity Targets [MarkitTick]💡 The financial markets operate as a continuous auction process, constantly seeking liquidity to facilitate large transactions. We have developed a comprehensive analytical tool designed to systematically map these liquidity zones, specifically focusing on the concept of inducement (IDM). This tool tracks market structure in real-time, identifying areas where market participants are structurally trapped, and highlights the subsequent liquidity sweeps that often precede significant directional moves. By mapping these pivot points and applying stringent confluence filters, we provide a structured approach to analyzing price action without relying on lagging, derivative-based oscillators.
✨ Originality and Utility
Standard structural tools often map higher highs and lower lows but fail to categorize the internal liquidity that resides between these structural bounds. Our tool distinguishes itself by isolating inducement points—short-term swing highs or lows that form within an active leg of market structure.
Instead of treating all pivots equally, we categorize them based on their relationship to the overarching trend. Furthermore, this tool does not simply plot historical data; it actively tracks pending liquidity pools and waits for their invalidation to derive actionable zones.
This utility is enhanced by a built-in risk management engine that dynamically calculates entry, stop loss, and multiple take profit voids based on market volatility, offering a complete, end-to-end framework directly on the chart. The integration of volume volatility, exhaustion profiling, and structural imbalances creates a unified, logical system rather than an arbitrary assembly of unrelated indicators.
🔬 Methodology and Concepts
● The Mechanics of Inducement
Market Structure Tracking: We utilize an advanced, non-repainting pivot identification algorithm that maps confirmed structural highs and lows. This establishes the primary directional bias and prevents the plotting of unconfirmed future data.
Pending Liquidity Generation: When an internal pivot forms within the established structural range, it is categorized as a pending inducement point. These represent areas where early market participants place stop losses, creating pools of concentrated liquidity.
The Liquidity Sweep: The core engine monitors price action for the precise moment these inducement points are breached. A sweep indicates that the pending liquidity has been consumed, providing the fuel required for a potential reversal or trend continuation.
Multi-Layered Confluence: A sweep alone is insufficient for validation. We evaluate the trigger against several strict conditions. We require alignment with a higher timeframe trend, ensuring we trade with the dominant macro flow. We also measure volatility against a moving baseline to filter out low-momentum chop.
Exhaustion and Imbalance: Finally, we assess the structural integrity of the move by checking for price exhaustion through rejection wicks and the presence of underlying fair value gaps (FVGs) that validate the momentum.
🎨 Visual Guide
● Chart Elements
Pending IDM Lines: Dotted lines projecting horizontally from internal pivots. These represent untouched liquidity pools waiting to be swept.
IDM Sweep Labels: Distinct visual markers displaying "IDM ↑" and "IDM ↓". These appear exactly when price sweeps a pending liquidity level, signaling a potential reaction.
Entry Zones (Black Boxes): A solid, dark zone originating at the trigger point, highlighting the exact entry threshold for the setup.
Stop Loss Zones (Red Boxes): A colored zone delineating the maximum risk threshold, visually adapting to the current structural invalidation point and volatility padding.
Take Profit Voids (Blue/Cyan Boxes): A series of progressively lighter colored zones representing Take Profit 1, 2, and 3. These voids illustrate the projected risk-to-reward extensions based on the initial risk profile.
Target Lines: Horizontal dashed and dotted lines projecting the exact price levels for the entry, stop loss, and multiple take profit targets.
● The Live Dashboard
Header: Displays the active ticker and timeframe configuration.
Bias: Indicates the overarching structural trend (Bullish, Bearish, or Neutral).
Last IDM: Shows the direction of the most recently swept liquidity pool.
Coordinates: Displays the exact numerical price levels for Entry, TP1, TP2, TP3, and SL.
Duration Tracking: Tracks the exact number of bars since the last confirmed Bull or Bear IDM sweep, offering a measure of setup maturity.
Pending Count: A live counter of the currently active, untouched inducement points on the chart.
📖 How to Use
Observe the dashboard to determine the active market bias and monitor the creation of pending IDM levels.
Wait for price action to sweep a pending IDM line. The appearance of an IDM sweep label serves as the primary catalyst.
Verify that the dashboard registers the setup, meaning all selected smart filters (Time, HTF, Volatility, FVG) are aligned.
Utilize the dynamically plotted Entry, Stop Loss, and Take Profit boxes to structure your position sizing and risk profile.
The projected target voids can be used to manage risk or scale out of positions sequentially as price moves into higher extensions.
Avoid using this indicator in sideways market conditions to prevent false entries.
⚙️ Inputs and Settings
● Core Configuration
Swing Length: Adjusts the sensitivity of the pivot detection. Higher values filter noise, identifying more significant structural points.
ATR Length: Modifies the lookback period for volatility calculations used in risk mapping.
Max IDM Memory: Controls the historical limit for tracking untouched liquidity pools.
● Entry and Risk Parameters
ATR-Adaptive SL: When enabled, we pad the structural stop loss with an average true range multiplier to account for market noise.
ATR SL Mult: Defines the precise multiplier used for the adaptive padding.
Target Multipliers (TP1, TP2, TP3): Defines the precise risk-to-reward ratios for the sequential take-profit voids.
Line Toggles: Independent toggles to show or hide the Entry, Stop Loss, and Target lines to keep the chart clean.
● Smart Filters
Session Time Filter: Restricts signal generation to specific trading windows, avoiding low-liquidity periods.
HTF Trend Alignment: Enforces agreement with a moving average calculated on a higher timeframe.
HTF Timeframe & Length: Configures the resolution and period for the higher timeframe trend filter.
FVG Confluence: Requires a recent fair value gap to validate the momentum behind the setup.
Rejection Quality: Filters setups ensuring the trigger bar closes with distinct rejection characteristics.
Volatility Chop Filter: Suppresses setups when current volatility is below its historical average.
● Visuals and Alerts
Color Configurations: Extensive user-defined color inputs for Bull/Bear markers, Entry Fills, Target zones, and text elements.
Webhook Actions: Dedicated string inputs to format dynamic alert payloads, allowing seamless integration with third-party execution platforms.
🔍 Deconstruction of the Underlying Scientific and Academic Framework
Auction Market Theory: Our architecture is deeply rooted in Auction Market Theory, which postulates that price discovery relies on the continuous search for liquidity. By mapping inducement, we are effectively modeling the algorithmic search for counter-party volume. Markets move from areas of high liquidity to low liquidity, and tracking these pools provides a probabilistic edge.
Mean Reversion within Structural Bounds: The identification of internal sweeps relies on statistical mean reversion. When price deviates aggressively to sweep a pivot, it creates a temporary state of overextension. The subsequent reaction is a reversion to the mean of the macro structure, propelled by the trapped liquidity that was just consumed.
Volatility-Adjusted Risk Modeling: The integration of the Average True Range (ATR) for stop-loss padding utilizes basic heteroskedasticity principles. Financial time series exhibit volatility clustering; by padding risk dynamically, the model adapts to the current state of market variance rather than relying on static, arbitrary tick values that fail in highly volatile environments.
Volume Spread and Exhaustion: The rejection filter incorporates elements of Volume Spread Analysis. A sweep accompanied by price rejection signifies absorption—a scenario where the effort to push price beyond a level is met with overwhelming counter-force, statistically validating the structural trap.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. I expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Indicator

Impulse Waves & Reversal Zones [MQLSoftware]Impulse Waves & Reversal Zones is a structural overlay that reads price as a chain of impulse and correction legs, then projects the zone where the dominant trend is expected to resume. Instead of auto-drawing a Fibonacci grid on the latest swing, it first decides whether a leg is a genuine impulse, frames the counter-trend pullback against it, and builds a managed reversal zone with targets, a stop, and a live status that retires the setup once it plays out. A compact right-side panel adds higher-timeframe bias, trend-conviction strength, an alignment score, and a plain-language plan.
This is a visual analytical tool intended for chart reading and structure mapping. It does not execute trades and does not provide financial advice.
Key Features
Impulse legs qualified by a self-calibrating quality score and drawn as bold trend channels; weaker legs stay as a faint wave skeleton
Active correction framed as an amber box labelled with its retracement depth versus the impulse it is correcting (an overrun beyond 100% is flagged as a deep retrace / structure break, not a clean correction)
Reversal zone built on the 0.382-0.618 retracement of the qualified impulse, with TP1 (x1.272) and TP2 (x1.618) extension targets and a stop with its R:R
Live setup status that moves through wait, in-zone, target hit, and stopped, and greys the zone out once it is resolved so a played-out setup never lingers as a live opportunity
Multi-timeframe panel: bias plus trend-conviction (ADX) strength for the chart and the next higher timeframes, an alignment score, and a plain-language plan
Higher timeframes selected automatically from the standard timeframe ladder based on the chart, with fewer rows near the top of the ladder (Daily, Weekly)
A plan that softens to "low conviction" when the bias is backed only by ranging higher timeframes, with the active setup flagged the same way so the panel never states two opposite things at once
Core Concept
Most reversal-zone and Fibonacci tools on PulseWire take one of two approaches. They either auto-draw a retracement grid on the most recent swing pair (no quality filter, and the grid jumps every time the latest swing redraws), or they label market structure (swings, breaks of structure) without projecting a managed, self-invalidating trade zone. Both leave the reader to decide by hand whether the leg even mattered and where the level should sit.
This indicator builds on a different base: classify structure first, then project a zone only from legs that qualify, and track that zone until it resolves. It adds three specific algorithmic elements on top of that base.
1. Protected-Swing Structure Classification. Trend direction is tracked by a change-of-character state machine with protected swings: the trend only flips when price breaks the swing low or high that launched the prior impulse. Shallow pullbacks therefore stay classified as corrections instead of constantly flipping the trend, which is the common failure mode of naive zigzag and two-pivot tools.
2. Self-Calibrating Impulse Quality Score. Every leg is scored 0-100 as one half Efficiency Ratio (net move divided by the path travelled, i.e. how straight the leg is) and one half Displacement Percentile (the leg's size in ATR units, ranked against the recent distribution of legs). A leg is drawn as an impulse only if it is with-trend and clears the score threshold. Because the size component is ranked against recent legs rather than compared to a fixed pip or point value, the filter self-calibrates across instruments and timeframes with no magic numbers.
3. Conviction-Aware Bias and Reversal Zone. The reversal zone is anchored to the dominant-direction qualified impulse and managed with targets, a stop, and a live state. Higher-timeframe context uses ADX strength rather than a path-efficiency ratio, so a strong trend still reads as strong mid-pullback. When the bias is supported only by ranging higher timeframes, the panel reports the bias but softens the plan to "low conviction" and marks any active setup the same way, so the structural read and the suggested action stay consistent.
Anatomy of the Display
Trend channels are bold green or coral channels drawn only for legs that qualify as impulses. The wave skeleton is a faint thin backbone drawn under every leg, so the raw swing structure stays visible; where a leg qualifies as an impulse, the bold channel sits on top of it.
The correction box is an amber dashed outline on the active counter-trend pullback, labelled with the retracement depth as a percentage of the impulse it is correcting. A retracement beyond 100% is relabelled as a deep retrace because the structure that the zone relied on is now at risk.
The reversal (entry) zone is the filled box spanning the 0.382-0.618 retracement of the qualified impulse, with a dotted mid-line and a label carrying the R:R of the resulting setup. TP1 and TP2 are the 1.272 and 1.618 extensions; the stop sits beyond the impulse origin.
The status chip reads the live state of the setup: waiting for the zone, in the zone, target hit, or stopped. Once the zone is hit or the setup is stopped, the zone and its levels grey out and the chip says so, so a resolved setup is visually retired rather than left looking active.
The right-side panel lists, per row, the timeframe, its bias (Bull / Bear / Flat), and a trend-conviction strength bar. The chart's own row is marked "pullback" when its direction opposes the trading bias, so a green chart row inside a bearish plan reads as the rally you are selling, not as a long signal. Below the rows: an ALIGN score (filled dots for how many higher timeframes vote each way, with the side that has no votes greyed), a verdict (ALIGNED, BULLISH/BEARISH BIAS, or MIXED), and the plan line.
Multi-Timeframe Panel
The higher-timeframe rows are selected automatically from the standard timeframe ladder based on the chart timeframe. For example, a 5m chart reads 15m / 30m / 1H; a 1H chart reads 4H / 1D / 1W; a 4H chart reads 1D / 1W / 1M. Near the top of the ladder fewer than three higher timeframes exist, so the panel simply shows fewer rows (a Daily chart shows Weekly and Monthly; a Weekly chart shows Monthly only). A manual mode lets you pin three timeframes of your choice instead. Higher-timeframe values are read with `lookahead=barmerge.lookahead_off` and a one-bar offset, which is the standard non-repainting pattern for higher-timeframe context.
Notes on Repainting
Historical impulses and corrections do not repaint. They are built from confirmed pivots (`ta.pivothigh` and `ta.pivotlow` with a right-bars parameter), so once a leg is committed it stays anchored in place.
The active forming leg is explicitly labelled "forming" and updates as new bars print; the reversal zone itself is anchored to the confirmed pivots of the qualified impulse.
The setup state is latched. Once price tags the stop or a target, that resolution is recorded against the setup's anchor and does not revert if price later trades back into the zone. A stopped or completed setup cannot revive itself.
Pivot detection has an inherent delay equal to the right-bars parameter (default 3 bars). A pivot becomes visible only after that many bars close past it. This is a property of all pivot-based indicators, not specific to this script.
Multi-timeframe panel data uses `lookahead=barmerge.lookahead_off` with a one-bar offset, the canonical non-repainting pattern for higher-timeframe context.
Alerts are gated by `barstate.isconfirmed` and fire once per closed bar, never intra-bar.
Typical Analysis Workflow
A common analytical workflow may include:
Reading the panel verdict and plan line to anchor an overall directional view, and noting the conviction (a "low conviction" plan means the bias is real but the higher timeframes are only ranging)
Checking the ALIGN row and the per-timeframe rows to see whether higher timeframes agree or conflict
Waiting for the status chip to read in-zone in the direction of the plan (sell rallies into the zone in a down-bias, buy pullbacks in an up-bias)
Reading the zone label R:R and the TP1 / TP2 / stop levels to frame the trade, then managing it with other forms of analysis and risk management
Treating the deep-retrace flag and the greyed-out (stopped / target-hit) state as structural context that a setup has changed or ended
Configuration
ATR Length - lookback for the ATR used in the swing filter, channel width, and stop placement.
Swing Filter (ATR) - the main noise lever. Higher values keep fewer, larger swings; lower values keep more, smaller swings.
Pivot Left Bars / Pivot Right Bars - the pivot lookback. Right Bars also sets the confirmation delay (a pivot is confirmed this many bars after it forms).
Impulse Strength Min - the minimum quality score (0-100) a with-trend leg must reach to be drawn as an impulse rather than skeleton.
Channel Width (ATR) - the half-width of the impulse channels, in ATR.
Visuals - colors for impulse up/down, correction, entry zone, targets, and stop; toggles for the wave skeleton, entry zone, targets, stop / R:R, and labels.
Multi-Timeframe HUD - show / hide the panel; Auto (next higher timeframes) versus Manual (three chosen timeframes); the three manual timeframes; and panel position (any corner).
Markets and Timeframes
The indicator can be applied across multiple markets and timeframes:
Forex
Stocks and Indices
Commodities
Cryptocurrencies
Because the swing filter, channel width, and impulse-size ranking are all ATR-based, the visual behavior stays consistent across instruments and timeframes. The Swing Filter and pivot settings can be tuned per chart for the cleanest read on a given symbol and timeframe.
Alerts
Price entered entry zone - fires when price first closes inside the reversal zone
New Swing High - fires when a high pivot is confirmed
New Swing Low - fires when a low pivot is confirmed
All higher TFs bullish - fires when every higher-timeframe row is bullish
All higher TFs bearish - fires when every higher-timeframe row is bearish
All alerts evaluate on confirmed bars to avoid intra-bar oscillation. Indicator

Gabremoku CloudsGabremoku Clouds is a volume-driven equilibrium cloud built to highlight fair-value zones, directional acceptance, and compression/expansion phases in a cleaner and more forward-looking way than traditional cloud indicators. Instead of using classic Ichimoku spans or standard deviation bands, this script builds its structure around a custom volume-weighted equilibrium line and a surrounding cloud whose width is based on Volume-Weighted Average Spread (VWAS). The result is a cloud that reacts not only to price movement, but also to how price is distributed under volume, making it useful for reading consensus, imbalance, and market acceptance.
A key idea behind this indicator is that not all price movement has the same meaning. When volume concentrates inside a tighter range, the cloud compresses and signals balance or consensus. When price expands with broader spread and weaker concentration, the cloud widens and reflects uncertainty or directional transition. This gives the indicator a different purpose from standard volatility envelopes: it is designed less as a generic overbought/oversold tool and more as a market structure and equilibrium map.
The script also includes a 26-period forward projection of the equilibrium cloud. This projected area is calculated from current and historical information only, then shifted forward visually to provide a future reference zone without using lookahead logic. Its purpose is not to predict price in an absolute sense, but to suggest where balance may migrate next if the current slope and cloud conditions remain consistent.
What it helps identify
Trend acceptance when price holds above or below the cloud with supporting volume.
Fair-value reclaims when price rotates back into equilibrium after displacement.
Squeeze-to-expansion transitions when the cloud compresses and then releases into directional movement.
Exhaustion when price reaches a fresh extreme while volume momentum decelerates.
How to use it
Use the current cloud to judge whether price is trading in balance, in directional acceptance, or in transition.
Use the projected cloud as a forward reference area for continuation, reversion, or future balance.
Treat the signals as contextual tools, not standalone trade instructions. They work best when combined with price structure, market context, and risk management.
What is new
Gabremoku Clouds is not a mashup of existing tools. Its core logic is built around a custom equilibrium model that combines volume-weighted price location with volume-weighted spread behavior, then extends that structure into a forward cloud projection. The goal is to give traders a more informative cloud: one that reflects where value is forming now, how stable that value is, and where it may shift next. Indicator

Market Structure (BOS / CHOCH), Advanced & ImprovedMarket Structure (BOS / CHOCH)
A clean, dual-layer market structure tool that labels Break of Structure and Change of Character from a single, internally consistent trend engine, then projects the resting liquidity those swings leave behind.
The core idea
BOS and CHOCH are the same break. What separates them is direction relative to the current trend, so this script tracks one trend state and derives the label from it:
BOS (Break of Structure) : price breaks a swing level in the direction of the trend. Continuation.
CHOCH (Change of Character) : price breaks a swing level against the trend. Reversal, and it flips the trend state.
Because both signals come from one state machine, you never get contradictory labels: a break with the trend is always BOS, a break against it is always CHOCH.
Dual-layer structure
The engine runs twice at the same time:
Swing structure (longer pivot length) : the major skeleton, drawn bold, with trailing watched-level lines and HH / HL / LH / LL swing labels.
Internal structure (shorter pivot length) : the minor continuation breaks inside each swing leg, drawn thin and faded so they read as secondary.
This lets you see a minor bullish BOS unfolding inside a major downtrend, which is the context most single-length tools miss.
Liquidity pools
Every unbroken swing high (buy-side) and swing low (sell-side) is projected to the right as a resting liquidity line, and removed the moment price wicks through it. What stays on screen is only live, untaken liquidity, the levels most likely to be targeted next.
Features
BOS / CHOCH detection with a single coherent trend state
Dual-layer swing and internal structure
Trailing lines marking the exact levels currently being watched
HH / HL / LH / LL swing labels, color coded by structural meaning
Buy-side and sell-side liquidity pools with auto removal on sweep
Top-right trend table showing the swing and internal trend state
Close or Wick break confirmation
Eight alert conditions: swing and internal, BOS and CHOCH, bullish and bearish
Inputs
Swing length and Internal length : pivot lookback for each layer. Lower values catch more structure, higher values show only major moves.
Break confirmation : Close requires a close beyond the level, Wick accepts any wick beyond it.
Toggles for BOS, CHOCH, active levels, swing labels, liquidity, internal layer and the trend table.
How to use
Trade with the swing trend, use internal CHOCH for early reversal warnings and internal BOS for continuation entries.
Watch the liquidity pools as targets, a sweep of one followed by a CHOCH in the opposite direction is a classic reversal setup.
Tune the swing length to your timeframe so the major structure matches the moves you actually trade.
Notes
Swing pivots confirm a fixed number of bars after they print, which is inherent to all structure tools and not repainting. On the live, unclosed bar a break can update until the bar closes, so set alerts to "Once Per Bar Close" for confirmed signals.
This script is a market analysis tool, not financial advice. Always do your own research and manage risk. Indicator

Structure Bias [FlowForge]Know the structural direction on two timeframes before you trade.
Structure Bias monitors market structure simultaneously on a higher and a lower timeframe, classifies each structural event in real time, and combines both readings into a single directional verdict. It answers the question most traders try to resolve by eye: are both timeframes pointing the same way?
───────────────────
DUAL-TIMEFRAME STRUCTURE DETECTION
The indicator evaluates confirmed swings on both configured timeframes independently. Each time price clears a prior confirmed swing, the event is classified by whether it aligns with the existing directional trend or breaks against it. A Break of Structure signals that the prevailing trend is continuing: price has extended beyond a prior swing in the same direction. A Change of Character signals a potential bias shift: price has broken a prior swing against the existing trend for the first time, indicating the directional bias may be reversing. Both readings update independently per timeframe so you always have a clear picture of where each one stands.
───────────────────
ALIGNED BIAS SUMMARY
The bottom row of the dashboard synthesizes both timeframe readings into a single verdict. When the higher and lower timeframe both report the same structural direction, the row shows a confirmed aligned bias. When they conflict, it shows Mixed, flagging a structurally undecided market where lower-conviction conditions apply. The most recently updated dashboard row is highlighted automatically so you can see at a glance which event is freshest.
───────────────────
LIVE DASHBOARD
A compact two-column table delivers the complete structural picture without adding clutter to the chart.
✥ Higher timeframe CHoCH: current Change of Character reading and direction
✥ Higher timeframe BOS: current Break of Structure reading and direction
✥ Lower timeframe CHoCH: same for your trading timeframe
✥ Lower timeframe BOS: same for your trading timeframe
✥ Overall Bias: aligned directional read, or Mixed when timeframes conflict
✥ Most recent structural event highlighted automatically
───────────────────
HOW TO USE
Add the indicator to your chart and configure the two timeframes to match your setup. A common starting point is your trading timeframe as the lower and one step above it as the higher. Read the four structure rows to understand what each timeframe is doing independently. Then look at the Overall Bias row as your directional filter: a confirmed aligned reading means both timeframes agree, which is the condition most traders treat as higher-conviction. A Mixed reading means the two timeframes disagree and the structural context is less clear. Use the CHoCH alerts to be notified when the lower timeframe bias flips; use the BOS alerts when a continuation move is confirmed. Use the Aligned variants when you only want signals under full dual-timeframe agreement.
───────────────────
ALERTS
Seven alert conditions, all firing on confirmed closed bars only.
✥ Bullish CHoCH: lower timeframe bias flipped to long
✥ Bearish CHoCH: lower timeframe bias flipped to short
✥ Bullish BOS: lower timeframe uptrend continuation confirmed
✥ Bearish BOS: lower timeframe downtrend continuation confirmed
✥ Aligned BOS Bullish: both timeframes aligned, bullish continuation
✥ Aligned BOS Bearish: both timeframes aligned, bearish continuation
✥ Aligned CHoCH: both timeframes aligned, high-confluence bias flip
───────────────────
CUSTOMIZATION
✥ Higher and lower timeframes: configurable independently
✥ Swing sensitivity: adjustable lookback depth for coarser or finer structure
✥ Dashboard position: four corner options
✥ Text size: four sizes
✥ Twenty color themes
───────────────────
THEMES
Twenty palettes are available. Four samples are shown below covering the default and three contrasting options. All twenty are accessible from the Theme input in the script settings.
Colorful (default)
Vivid
Copper
Ember
Indicator

Micro Harmonic Swing Rhythm Meter + Structure PanelMicro Harmonic Swing Rhythm Meter
Overview
Inspired by the observation that markets often oscillate in recurring harmonic swings of both price and time.
The Micro Harmonic Swing Rhythm Meter is a market structure and rhythm analysis tool designed to identify recurring swing behavior in price action.
Rather than focusing on traditional indicators such as momentum, trend, or overbought/oversold conditions, this indicator measures the repeating "heartbeat" of the market by tracking swing size, swing duration, and the evolving rhythm between successive price pivots.
The objective is not to predict price, but to monitor whether the current auction process remains stable, is compressing, expanding, or becoming exhausted.
Core Concepts
Every market exhibits recurring oscillations.
These oscillations often develop with similar:
* Price amplitude
* Swing duration
* Expansion and contraction cycles
The indicator automatically detects swing pivots and measures:
* Swing Size
* Swing Duration
* Average Swing Size
* Average Swing Duration
* Swing Efficiency
* Market Rhythm State
By comparing the current swing against recent averages, the indicator evaluates whether price action remains in harmony with its established rhythm.
Rhythm States
NORMAL
Current swing size and duration remain close to recent averages.
Interpretation:
* Stable auction
* Balanced market conditions
* Established rhythm remains intact
COMPRESSED
Current swing size and duration are smaller than average.
Interpretation:
* Energy accumulation
* Contracting auction
* Potential precursor to expansion
STRETCHED
Current swing size and duration exceed recent averages.
Interpretation:
* Expansion phase
* Strong directional movement
* Possible acceleration or exhaustion
MIXED
Price amplitude and swing duration are no longer synchronized.
Interpretation:
* Transitional market behavior
* Changing auction structure
* Reduced rhythm consistency
Market Structure Assessment
The indicator automatically classifies recent swing behavior into higher-order structure states.
Possible structure classifications include:
Balanced Rotation
Stable oscillatory conditions.
Trade Mode:
Range Mode
Compression / Coiling
Multiple compressed swings indicate energy accumulation.
Trade Mode:
Breakout Watch
Expansion Attempt
Expansion emerges following a period of compression.
Trade Mode:
Confirm Breakout
Exhaustion Risk
Repeated stretched swings suggest mature directional movement.
Trade Mode:
Caution
Unstable Auction
Excessive mixed swings indicate poor rhythm consistency.
Trade Mode:
Wait
Efficiency Metric
Efficiency is calculated as:
Average Swing Size ÷ Average Swing Duration
This metric measures how much distance price is covering per unit of time.
Rising efficiency often indicates increasing participation and directional conviction.
Falling efficiency often indicates slowing market activity and declining momentum.
Intended Usage
This indicator is designed primarily as a market state monitor rather than a signal generator.
It may be used alongside:
* Price action analysis
* Volume analysis
* Order flow tools
* VWAP frameworks
* Market profile
* Liquidity analysis
The indicator is particularly useful for identifying:
* Compression before expansion
* Changes in auction rhythm
* Developing directional impulses
* Potential exhaustion conditions
Recommended Workflow
Higher timeframes may be used to determine dominant market structure while lower timeframes are used for execution.
Example:
30-minute chart:
Market structure and session rhythm
5-minute chart:
Tactical structure
1-minute chart:
Execution and timing
This multi-timeframe approach allows traders to align lower timeframe opportunities with higher timeframe rhythm conditions.
Disclaimer
This indicator is designed to assist with market observation and structure analysis. It does not provide trading advice and should not be interpreted as a standalone buy or sell signal.
Indicator

Price Pulse Oscillator [Live Stochastic Rhythm]Price Pulse Oscillator
Overview
The Price Pulse Oscillator was designed to monitor the internal state of price action rather than simply identify overbought or oversold conditions.
While traditional oscillators such as RSI, Stochastic, and MACD focus primarily on where price is relative to recent history, the Price Pulse Oscillator attempts to answer a different question:
How is price behaving internally right now?
The indicator continuously monitors the relationship between four structural components:
Pulse Position
Pulse Velocity
Pulse Acceleration
Compression / Expansion State
Together these elements provide a dynamic view of market behavior, allowing traders to observe transitions in momentum, participation, and volatility before they become obvious in price structure itself.
The goal is not to generate buy and sell signals.
The goal is to monitor the evolving state of the market.
The Philosophy Behind The Indicator:
Markets rarely move from one state to another instantly.
Before a breakout occurs:
volatility often contracts,
momentum begins to stabilize,
acceleration starts to shift,
internal pressure gradually builds.
Similarly, before trends exhaust:
momentum begins to weaken,
acceleration deteriorates,
expansion loses force,
price continues moving largely through inertia.
The Price Pulse Oscillator was built to visualize these transitions.
Rather than focusing on the final outcome, the indicator focuses on the process leading to that outcome.
Components
1. Live Pulse (Blue Line)
The Live Pulse measures where current price sits within its recent trading range.
Conceptually it functions similarly to a stochastic oscillator but is continuously updated as the active candle develops.
The Pulse provides a real-time representation of market positioning:
High values indicate price is trading near recent highs.
Low values indicate price is trading near recent lows.
Mid-range values indicate equilibrium.
The Pulse itself is not intended to be a signal.
Instead, it serves as the foundation from which the indicator's higher-order information is derived.
2. Signal Line (Red Line)
The Signal Line is a smoothed version of the Live Pulse.
Its purpose is to create a reference against which changes in market rhythm can be evaluated.
Traditional crossover logic can be applied, but the indicator is most effective when analyzing:
the speed of the crossover,
the angle of the crossover,
the compression state surrounding the crossover,
and the behavior of velocity and acceleration during the crossover.
In many cases, how the crossover occurs contains more information than the crossover itself.
3. Velocity (Black Line)
Velocity measures the rate of change of the Pulse.
In simple terms:
Velocity shows how quickly market pressure is changing.
Positive velocity suggests increasing bullish pressure.
Negative velocity suggests increasing bearish pressure.
Velocity often begins shifting before price visibly breaks out of a consolidation structure.
For this reason it can be viewed as a measure of directional participation.
4. Acceleration (Magenta Line)
Acceleration measures the rate of change of Velocity.
In simple terms:
Acceleration shows whether momentum itself is strengthening or weakening.
This is often one of the earliest components to shift.
Acceleration may begin rising while price remains range-bound and before Velocity has fully turned.
For this reason it can serve as an early indication that market conditions are changing beneath the surface.
A useful way to think about the hierarchy is:
Acceleration → Velocity → Price
Changes frequently appear in this order.
5. Compression / Expansion Histogram
The histogram measures the degree of compression or expansion occurring within the Pulse itself.
High histogram readings indicate:
reduced internal oscillation,
consolidation,
volatility contraction,
energy storage.
Low histogram readings indicate:
expansion,
volatility release,
active directional movement.
The histogram should not be viewed as bullish or bearish.
Instead it provides context regarding whether the market is currently storing energy or releasing energy.
Market States
The Price Pulse Oscillator is particularly useful when identifying transitions between market states.
Compression State
Characteristics:
High compression histogram
Flattening Pulse
Declining Velocity
Stabilizing Acceleration
Interpretation:
The market is entering equilibrium.
Directional conviction is temporarily reduced.
Energy is being stored.
These conditions frequently precede significant expansion phases.
Ignition State
Characteristics:
Compression begins declining
Velocity turns higher
Acceleration rises sharply
Pulse crosses Signal
Interpretation:
Stored energy is beginning to release.
The market is transitioning from equilibrium toward expansion.
Expansion State
Characteristics:
Compression continues declining
Velocity remains elevated
Pulse remains above or below Signal
Acceleration remains positive
Interpretation:
Directional movement is strengthening.
Participation is increasing.
The trend is actively expanding.
Mature Expansion State
Characteristics:
Compression remains low
Velocity begins flattening
Acceleration weakens
Price continues trending
Interpretation:
The trend remains intact but internal force is beginning to fade.
Expansion may continue, but participation is no longer strengthening.
Exhaustion State
Characteristics:
Compression fully released
Velocity declining
Acceleration negative
Pulse remains extended
Interpretation:
The market may be approaching a local high or low.
Price can still move further, but internal momentum is deteriorating.
Suggested Usage
The Price Pulse Oscillator is not intended to replace price action analysis.
Instead it is designed to complement:
Market Structure
Volume Analysis
VWAP Frameworks
Order Flow
Market Profile
Bookmap
Liquidity Analysis
The indicator is most effective when used as a continuous market condition monitor.
Rather than asking:
"Should I buy or sell?"
the indicator encourages a different question:
"What state is the market currently in?"
By focusing on transitions between compression, expansion, and exhaustion, traders can develop a deeper understanding of the rhythm and internal mechanics driving price movement.
Key Principle
The Price Pulse Oscillator is not designed to predict price.
It is designed to monitor the changing state of price action in real time.
Its primary purpose is to reveal the evolving rhythm, force, and compression of the market as they develop. Indicator

Market Cycle Wave [Gabremoku]Market Cycle Wave is a price-based cycle indicator built to map broad market phases into a readable oscillator and a price-anchored overlay.
Instead of relying on a single signal, the script combines trend, momentum, volatility, and range-position data into a composite cycle score. That score is normalized and smoothed to create an intermediate Cycle Wave, while a slower Secular line provides broader context.
The script has two main views:
- an oscillator pane with the score histogram, Cycle Wave, Secular baseline, and major Cycle Peak / Cycle Trough labels.
- a price overlay with a cycle line, gradient aura, and a thinner secular context line.
The regime model classifies market conditions into Debt Accumulation, Deleveraging, Reflation, and Transition. The goal is not to generate standalone buy/sell signals, but to help traders read where price may sit inside a broader market cycle structure.
How to use it
This indicator works best on broad indices and diversified equity ETFs, where cycle behavior is usually cleaner than on highly erratic single names.
Typical use:
- Daily chart: monitor intermediate cycle shifts
- Weekly chart: study broader regime transitions
Practical reading:
- A rising blue cycle wave can suggest constructive expansion conditions
- A yellow rollover after a mature advance can suggest a weakening cycle structure
- Deep negative readings followed by green recovery can suggest reflation or post-stress repair
- The secular line helps show whether the shorter cycle is moving with or against the broader backdrop
The dashboard summarizes the current regime, state, direction, score, risk posture, and color legend directly on the chart.
How it works
The cycle model uses eight price-based factors:
- Fast EMA vs slow EMA relationship
- Fast EMA slope
- RSI momentum regime
- RSI extremes
- Position inside the rolling yearly range
- Distance from yearly extremes
- ATR volatility regime
- Price position vs the slow EMA
Each factor contributes to a composite score. That score is then normalized, smoothed, and accumulated over a rolling memory window to build a bounded cycle wave around a midpoint.
A second and slower baseline is built through longer smoothing to represent secular context. This creates two distinct layers:
- Cycle Wave: the intermediate cycle, more reactive to market swings
- Secular Baseline: the broader context, slower and less sensitive
Recent Cycle Peak and Cycle Trough labels are pivot-based, so the latest labels need confirmation from future bars. Indicator

Smart Gap & Support and Resistance Breakout [MarkitTick]💡 This technical analysis script provides a highly sophisticated framework for market structure mapping, gap categorization, and breakout validation. By tracking structural pivot points and combining them with algorithmic gap analysis, the indicator systematically identifies areas of significant price imbalance and evaluates their impact on subsequent price action. The tool dynamically maps historical and developing support and resistance levels across multiple timeframes, integrating volume analysis and time-decay functions to ensure only the most relevant structural levels remain active. Designed for robust technical evaluation, it utilizes a strict non-repainting architecture for its multi-timeframe data retrieval, ensuring historical integrity during retrospective analysis.
✨ Originality and Utility
While many indicators plot basic support and resistance levels or highlight price gaps, this tool introduces a high degree of originality through its algorithmic synthesis and mashup methodology. The combination of structural pivot tracking and gap categorization is a deliberate and logical confluence. Gaps inherently represent sudden shifts in supply and demand, frequently acting as hidden support or resistance zones. By merging gap analysis with traditional pivot-based market structure, the script provides a unified view of market geometry.
Furthermore, the script distinguishes itself by categorizing gaps dynamically into three distinct types: Breakaway, Runaway, and Exhaustion. Rather than treating all price voids equally, it applies contextual logic—such as trend maturity and volume confirmation—to evaluate the probabilistic nature of the gap. The utility is further enhanced by an advanced multi-timeframe engine that overlays macro structural levels onto the active chart without introducing lookahead bias, providing traders with a pristine, top-down analytical perspective within a single pane.
🔬 Methodology and Concepts
● Structural Pivot Detection
The foundation of the script relies on identifying Swing Highs and Swing Lows.
A Pivot High is established when a specific high price is preceded and followed by a defined number of lower highs.
A Pivot Low is established when a specific low price is preceded and followed by a defined number of higher lows.
These points act as the empirical anchors for drawing support and resistance lines.
● Gap Categorization Engine
The script continuously scans for bullish and bearish price gaps (defined as a strict price void between the current low/high and the high/low of two bars prior, combined with directional candle confirmation). Once a gap exceeds the minimum size threshold, it is classified using the following methodology:
Breakaway Gaps (BW): Identified if the gap's occurrence coincides with the breaking of the most recently established structural pivot level. This signifies a forceful escape from a prior consolidation or trend phase.
Exhaustion Gaps (EX): Identified if the gap occurs after a prolonged trend duration (trend maturity) and is accompanied by a significant volume spike. This logic assumes that late-stage acceleration coupled with extreme volume often represents climatic buying or selling.
Runaway Gaps (RW): Any valid gap that does not meet the strict criteria for Breakaway or Exhaustion is classified as Runaway, representing standard trend continuation.
● Non-Repainting Multi-Timeframe Integration
To map higher timeframe (HTF) levels onto the lower timeframe (LTF) chart safely, the script employs a strict index-offset methodology. When fetching HTF pivot data, the script references the previous bar's calculated state while utilizing a lookahead parameter. This architectural design explicitly prevents future data leakage (lookahead bias), ensuring that historical backtesting and real-time execution behave identically.
● Breakout and Time-Decay Logic
Support and resistance lines are evaluated for breakouts based on closing prices. A breakout is only considered valid if the closing price decisively crosses the level and, if volume confirmation is enabled, the breakout bar's volume exceeds the defined moving average threshold. To maintain a clean visual workspace, levels can be subjected to a time-decay function, removing them from the chart after a user-defined number of bars.
🎨 Visual Guide
● Support and Resistance Lines
Green Lines: Represent active support levels derived from current timeframe pivot lows.
Red Lines: Represent active resistance levels derived from current timeframe pivot highs.
Thick Light Blue Lines: Highlight major support levels from the higher timeframe.
Thick Orange Lines: Highlight major resistance levels from the higher timeframe.
● Market Structure Labels
Red "HH" / "LH" Labels: Denote Higher Highs or Lower Highs at resistance pivots.
Blue/Green "LL" / "HL" Labels: Denote Lower Lows or Higher Lows at support pivots.
Purple "EH" / "EL" Labels: Indicate Equal Highs or Equal Lows.
● Gap Visualization Boxes
Blue Boxes: Highlight Breakaway Gaps (BW).
Orange Boxes: Highlight Runaway Gaps (RW).
Red Boxes: Highlight Exhaustion Gaps (EX).
Dotted Mid-Lines: Each gap box contains a dotted line calculating the exact mathematical midpoint of the gap, often acting as a highly reactive micro-level.
● Breakout Markers
Green Upward Triangles (▲): Plotted below the price to indicate a confirmed breakout of a resistance level. The number indicates how many distinct resistance levels were broken on that bar.
Red Downward Triangles (▼): Plotted above the price to indicate a confirmed breakdown of a support level.
Cyan/Orange Triangles: Represent breakouts of higher timeframe (HTF) levels.
📖 How to Use
● Interpreting Gap Signals
Breakaway Gaps: When a blue Breakaway gap forms, it suggests the initiation of a new directional phase. Traders typically monitor the borders of this gap to act as strong support or resistance upon any subsequent retests.
Runaway Gaps: The appearance of an orange Runaway gap confirms underlying trend strength. The midpoint of these gaps (the dotted line) is often used to gauge short-term trend health.
Exhaustion Gaps: A red Exhaustion gap serves as a cautionary signal. Because it indicates mature trend fatigue coupled with high volume, it suggests that the current directional momentum may be nearing a terminal phase or sharp retracement.
● Trading Support and Resistance Breakouts
Structural Mapping: Use the dynamically drawn S/R lines to identify the boundaries of the current market range.
Volume Confirmation: When the indicator plots a breakout triangle, ensure that it aligns with your broader directional bias. If the volume confirmation setting is active, the triangle inherently signifies that the breakout possessed above-average participation, increasing the mathematical probability of continuation.
Multi-Timeframe Confluence: Pay special attention when current timeframe price action interacts with the thicker HTF lines. A breakout that fractures both a LTF and HTF resistance level simultaneously carries significantly more structural weight.
⚙️ Inputs and Settings
● Swing Logic
Left Bars / Right Bars: Determines the number of bars required on either side of a candle to confirm a structural pivot. Higher values yield longer-term, more significant levels.
Max Stored Levels: Controls how many historical S/R lines remain active on the chart to prevent visual clutter.
Max Break Labels: Limits the number of historical breakout triangle markers displayed.
● Usability and Time Decay
Multi-Timeframe: Allows overriding the base timeframe for calculations.
Enable Time Decay: When activated, S/R levels that remain untested or unbroken will automatically expire and be removed from the chart.
Decay Period (Bars): The specific threshold of bars after which an untested level is deleted.
● Higher Timeframe (HTF) Levels
Enable HTF Levels: Toggles the calculation and plotting of macro S/R lines.
HTF Timeframe: The target timeframe for macro structural analysis (e.g., Daily, Weekly).
Hide Current TF When HTF Active: A visual filter to isolate only macro levels when desired.
● Algorithmic Filters and Analysis
Volume Confirmation: When true, breakouts are only validated if the bar's volume exceeds a moving average.
Min Gap Size (Points): Establishes a raw point threshold that a price void must exceed to be classified as a gap, filtering out negligible price skips.
Volume Spike Multiplier: The factor by which current volume must exceed the average to trigger Exhaustion gap logic.
Trend Maturity (Bars): The minimum number of bars a trend must have persisted from the last major pivot to allow for an Exhaustion gap classification.
🔍 Deconstruction of the Underlying Scientific and Academic Framework
● Auction Market Theory and Liquidity Voids
The gap categorization matrix within this script is deeply rooted in Auction Market Theory (AMT). In AMT, price discovery is a continuous auction searching for liquidity. A gap represents a structural liquidity void—a pricing zone where no double-sided auction occurred due to extreme urgency from either buyers or sellers. The script's identification of Breakaway gaps mathematically isolates moments where this urgency successfully overcomes historical supply or demand nodes (the pivots). The dotted midpoint lines inside the gap boxes serve as theoretical "Fair Value" approximations for the void, representing the mean reversion target if the market attempts to repair the inefficient auction.
● Volume Spread Analysis (VSA) Integration
The Exhaustion gap classification heavily relies on principles derived from Volume Spread Analysis. In VSA, volume represents the effort of market participants, while price spread represents the result. The script mathematically quantifies an anomaly: when an extended trend (measured by the Trend Maturity parameter) produces a sudden gap on extreme volume (measured by the Volume Spike Multiplier), it implies climactic transfer of inventory from strong hands to weak hands. The algorithmic detection of these specific variables provides a quantifiable method for identifying trend exhaustion without relying on lagging, bounded oscillators.
● Fractal Market Geometry
By rendering both LTF and HTF structural pivots within the same visual plane, the script operationalizes the concept of fractal market geometry. Financial time series exhibit self-similarity across different scales. A pivot high on a 15-minute chart is formed by the same behavioral mechanics as a pivot high on a Daily chart, but they carry vastly different liquidity weights. The script's strict index-offset MTF architecture ensures that the geometric relationship between these distinct fractal layers is evaluated with absolute temporal accuracy, providing a mathematically sound representation of macro supply and demand overlaying micro price action.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. I expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Indicator

Parallel Transport & Holonomy [DAFE]Parallel Transport & Holonomy - (⟡ PTH)
This publication presents the quantitative mechanics and theoretical architecture behind the Parallel Transport & Holonomy engine. This system models price and volume dynamics as trajectories on a continuous two-dimensional manifold. By computing the parallel transport of multi-scale momentum vectors, tracking their covariant derivatives, and integrating their path-dependent rotational deficit ( Holonomy ), the indicator identifies macro regime shifts, structural pivots, and trend continuations.
The architecture is entirely self-contained, featuring a Legit Footprint Toggle that automatically falls back to an advanced Synthetic Footprint Engine when tick-level footprint data is unavailable. It is strictly anchored by a Rolling Confidence Matrix (RCM) and modulated by an Ensemble Dynamic Volatility Scaling (DVS) engine.
The core principle of this system is geometric invariance: signal evaluation is not based on static, lagging thresholds but on the coordinate-invariant deviation of momentum from its natural geodesic path.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Riemannian Price-Volume Manifold & Metric Tensor
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
We define the market state as a coordinate point on a two-dimensional Riemannian manifold
M, where the coordinates are:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Parallel Transport & Covariant Derivatives
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Let V be a momentum vector on the tangent space of the manifold, constructed at three distinct temporal scales: Fast (vecFast), Medium (vecMed), and Slow (vecSlow). The coordinate components of the vector scale k are computed as:
Geodesic Deviation
A path is geodesic if its covariant derivative along the direction of travel is zero (representing the path of least resistance on the manifold). We define the geodesic deviation Zgeodesic as the rolling z-score of the absolute transport deviation:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Holonomy & Phase Accumulation
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Holonomy describes the geometric phenomenon where parallel transporting a vector along a closed loop returns a vector with a changed orientation. This angular deficit directly measures the total curvature enclosed by the loop.
Holonomy Group Classifications
Based on the magnitude of the accumulated rotation (HolonomyNorm), the local coordinate space is classified into four geometric groups:
Trivial (Norm<0.10): The manifold is flat; parallel transport is path-independent, indicating quiet consolidated ranges.
Abelian (Norm<0.25): Minor commutative drift; the vector field undergoes predictable linear shifts.
Non-Abelian (Norm<0.50): Significant non-commutative curvature. Parallel transport is highly path-dependent, signaling complex trend development and institutional accumulation.
Singular (Norm≥0.50): Severe rotational deficit. The manifold geometry has collapsed or rotated sharply, marking high-probability reversal peaks and structural transitions.
Holonomy Regime Shifts
A Regime Shift is triggered when HolonomyNorm exceeds the user-defined threshold (i_holoThresh). Depending on the sign of the accumulated loop (sgn(H)) and the divergence between the fast and slow vectors, the engine classifies the transition into one of the following states:
Bull Rotation : Enclosed path yields a positive rotational deficit combined with positive multi-scale momentum.
Bear Rotation : Enclosed path yields a negative rotational deficit combined with negative multi-scale momentum.
Geodesic Break : Extreme localized acceleration causing the momentum field to tear away from its expected trajectory.
Scale Divergence : High-frequency (fast) and low-frequency (slow) vectors rotate in opposite directions, enclosing a singular point.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Rolling Confidence Matrix (RCM)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
The Rolling Confidence Matrix (RCM) acts as a structural anchor. It takes multi-scale geometric indicators from the transport engine and compiles them into a state-space model that dynamically controls signal permissions.
State Space Representation
The matrix maintains a rolling assessment of market structure across three distinct states:
Established (State 0): The trend is structurally intact; manifold bands are compressed, and parallel transport confirms high directional persistence.
Transition (State 1): Price is approaching key structural levels or experiencing a holonomy spike. Manifold bands widen, and standard signals are gated.
Damaged (State 2): Price has broken through primary defensive corridors. Structural confidence is compromised; bands expand by the Damage Band Expansion multiplier
(i_damageWiden), and counter-trend positions are heavily penalized.
External Evidence Injection
On every bar, the system injects external geometric parameters from the manifold:
This evidence is integrated into the RCM, outputting structural permissions (allowLong, allowShort) and score modulations that are applied to the final signal scoring calculations.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Ensemble Dynamic Volatility Scaling (DVS)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
To adapt the mathematical models to varying market volatility, the script runs three independent volatility estimators concurrently on every bar:
Ensemble Combinatorics
The baseline values are calculated as moving averages over the memory period. The script then computes the ratios of the current estimators to their historical baselines:
This ratio dynamically scales the width of the holographic manifold bands and the RCM damage thresholds: during highly volatile regimes, thresholds are expanded to prevent whipsaws; during compression regimes, thresholds are tightened to capture early breakouts.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Footprint & Synthetic Fallback Engine
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
The script includes a Use Legit Footprint toggle (i_useFp). When enabled on charts supporting tick databases, the system requests official exchange-traded order flow data:
fp=request.footprint(i_fpTicks,i_fpVA)
The Advanced Synthetic Footprint Engine
If the user deactivates the footprint toggle, or if the asset/timeframe does not support tick database access (e.g., historical bars or Forex), the Synthetic Footprint Fallback Engine** takes over, simulating volume-at-price and directional delta using high-frequency mathematical approximations:
This estimated delta reconstructs the synthetic buy and sell pressures:
Kyle's Lambda (Price Impact & Liquidity Risk)
Using these directional volumes, we calculate Kyle's price impact coefficient λ, measuring the price change per unit of volume flow:
High values of λ represent illiquid, thin, or toxic conditions. The system calculates the z-score of lambda (Zλ). If Zλ > 2.0, signal scores are dynamically penalized to protect capital from low-liquidity slippage.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Structural Scoring & Signal Gating
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
The system generates a directional Signal Score using a two-tier quantitative scoring process.
Stage 1: Structural Base (Minimum of one required)
Siege Corridor Proximity : Price is within 1.2 ⋅ ATR of a verified support or resistance level.
ScoreBase = 0.28+(Hold Probability⋅0.18)
EMA21 Geodesic Pullback : Price pulls back to the EMA21 in trend alignment.
ScoreBase = 0.25
RSI Extreme Exhaustion : RSI is below 25 (for longs) or above 75 (for shorts).
ScoreBase = 0.28
Stage 2: Confirmations (Additive)
Multi-pattern confluence (2+ patterns matching): +0.15
Pressure bar strength exceeds thresholds: +0.08 to +0.15
Metric curvature aligns with structural turn: +0.10
Volume expansion exceeds historical average: +0.10
Holonomy phase shifts or loop spikes: +0.12
Directional Scaling & Gating
The score is adjusted based on trend alignment. With-Trend (WT) setups (longs above the EMA50, shorts below) are evaluated using standard thresholds. Counter-Trend (CT) setups face a strict scaling penalty:
ScoreCT = ScoreRaw ⋅ clamp(1.0−Trend Strength⋅0.15,0.45,1.0)
Additionally, the score passes through three gates:
Liquidity Penalty : Reduced by up to 30% if order flow thickness is classified as Desert or Frozen.
Kyle Lambda Gate : Penalized if price impact is highly volatile (Zλ > 2.0).
Danger Gate : Score is multiplied by 0.60 if the composite risk danger index exceeds 75.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Input Reference
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
═══ GEOMETRY ENGINE ═══
Hurst Period (30 to 200, default 80): Lookback window for R/S calculations to evaluate trend persistence.
Pivot Length (2 to 15, default 5): Lookback/lookahead buffer for swing pivot detection.
TF Preset (Auto, 1m-5m Scalp, 10m-15m Intra, 30m-1H Swing, 4H-D Position): Set the timeframe scaling preset. Auto dynamically scales lookbacks based on the current chart timeframe.
Use Legit Footprint (Boolean, default true): Toggles whether to query exchange tick database for real footprint data.
Footprint Ticks/Row (1 to 500, default 100): Height of the footprint rows in tick units.
Footprint VA % (50 to 90, default 70): Percentage of volume enclosed within the Value Area.
═══ TRANSPORT & HOLONOMY ═══
Vector Fast Scale (3 to 21, default 8): Periods for tracking short-term momentum vectors.
Vector Medium Scale (10 to 55, default 21): Periods for intermediate momentum geometry.
Vector Slow Scale (21 to 144, default 55): Baseline vector window representing the macro manifold.
Holonomy Window (13 to 89, default 34): Size of the temporal loop used to integrate local deviations.
Holonomy Spike Threshold (0.10 to 0.90, default 0.35): Sensitivity threshold for identifying rotational shifts.
Geodesic Deviation Sensitivity (0.5 to 3.0, default 1.5): Sensitivity for flagging off-path momentum.
Enable Continuation Signals (Boolean, default true): Toggles secondary pullback entries in strong trends.
═══ ROLLING CONFIDENCE MATRIX ═══
Block Transition Signals (Boolean, default true): If active, blocks standard entry signals when the matrix is in transition state.
Conf Band Tightening Factor (0.0 to 1.0, default 0.35): Compression multiplier for manifold bands under high confidence.
Damage Band Expansion (1.0 to 1.5, default 1.15): Expansion multiplier for manifold bands under structural damage.
═══ DYNAMIC VOLATILITY SCALING (DVS) ═══
Enable Ensemble DVS Engine (Boolean, default true): Toggles whether to scale target multiples and thresholds by volatility.
DVS Method (ATR Ratio, Parkinson, Garman-Klass, Ensemble): Method for calculating real-time volatility.
DVS Memory Period (20 to 200, default 100): Baseline lookback window for historical volatility.
DVS Sensitivity (0.3 to 1.5, default 0.7): Exponent scaling parameter for the DVS ratio.
═══ SIGNAL GATING ═══
Signal Threshold (0.10 to 0.85, default 0.40): Minimum score required to fire a signal.
Cooldown Bars (1 to 50, default 6): Minimum bar spacing between consecutive signals.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Visual System & Dashboard Interpretation
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Transport Field Manifold : A multi-layered band surrounding price. It contracts during clean, high-confidence geodesic flow and expands during high-entropy, damaged, or volatile regimes. Its color is determined by the RCM state: Green for bullish stability, Red for bearish, and Purple during transitions.
Siege Corridors : Plotted as horizontal support (Green) and resistance (Red) zones with an ATR-scaled boundary. At the right-hand side of the chart, these corridors display critical metrics: the total historical hit count, the estimated break probability (Pbreak), and the fail/reversal probability (Pfail).
Vector Field Lines : Small arrow-headed lines plotted on every third bar. They show the mathematical direction of the Fast momentum vector. They visually represent the difference between the actual observed path of the market and the expected parallel-transported baseline.
Holonomy Phase Ring : An indicator plotted at the right edge of the chart displaying the current phase angle (e.g., ◐ 144∘).
Glitch Markers: Flagged on the chart as ◈ GLITCH when anomalous pricing data or sudden coordinate jumps are detected on the manifold.
Dashboard: Displays real-time metric readings from all quantitative modules:
Tensor Metrics: Curvature, Entropy, Hurst Exponent, and Price Pressure.
Volatility: Dynamic DVS Ratio, active estimator method, and scaling state.
RCM Brain: State classification, integrity index, and gate permissions.
Performance: Total trades, win rate, total profit (R-multiple), profit factor, and max drawdown.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Limitations and Disclaimers
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
This tool is for analytical purposes only and does not predict future market direction.
Historical Simulation: The built-in simulator represents hypothetical performance on historical data. Past results do not guarantee future performance.
Volume Approximations: The synthetic footprint engine uses OHLCV approximations to estimate volume-at-price and directional delta. It is not an actual connection to L2 exchange data feeds or a central clearing book.
Persistence: Reinforcement learning weights are state-space variables that exist within the local execution thread; they reset to 1.0 on every chart load or browser reload.
— Dskyz. Trade with insight. Trade with anticipation. (It's lonely at the top) Indicator

Market Structure Target Tracker [MarkitTick]💡 An advanced, multi-faceted analytical suite designed for traders who rely on price action and logical trend progressions. By systematically identifying structural pivots in the market, this tool automatically maps out Break of Structure (BOS) and Change of Character (CHoCH) events. Rather than simply plotting support and resistance, it integrates a sophisticated risk-management framework directly onto the chart, calculating dynamic Entry, Stop Loss (SL), and multiple Take Profit (TP) levels based on market volatility.
Price action trading requires constant vigilance to identify local maxima and minima. This script relieves the trader of manual chart marking by perpetually analyzing rolling windows of price data. When an established swing high or low is breached, the indicator locks in the structural shift, evaluates higher timeframe momentum to filter out false breakouts, and establishes a forward-looking target zone.
✨ Originality and Utility
Most market structure indicators limit their functionality to placing historical labels on the chart. The originality of this script lies in its forward-looking, state-aware tracking mechanism. It operates not just as an indicator, but as a simulated trade management dashboard.
Once a structural break occurs, the indicator shifts into an active tracking state. It dynamically projects Entry and SL/TP bands anchored to the breakout, using Average True Range (ATR) to adapt to the asset's current volatility. Furthermore, it continuously evaluates the life-cycle of the structural break, monitoring price action to determine if the target is successfully hit or if the setup is invalidated by an opposing swing breach. This level of state persistence provides traders with an objective, real-time assessment of trade feasibility, risk-to-reward ratios, and trend duration.
🔬 Methodology and Concepts
The script is built upon four foundational technical concepts, woven together into a unified logic sequence:
• Pivot Detection
The core engine scans for Pivot Highs and Pivot Lows. A Pivot High is confirmed when a specific bar's high is strictly greater than the highs of a defined number of bars both preceding and following it. This creates a fractal representation of market turning points.
• Break of Structure (BOS)
A bullish structure break occurs when the closing price of a confirmed bar exceeds the most recent Pivot High. Conversely, a bearish break occurs when the close drops below the most recent Pivot Low. The script categorizes the first break in a new direction as a CHoCH, and subsequent continuous breaks as BOS.
• Higher Timeframe (HTF) Alignment
To prevent trading against the dominant macroeconomic trend, the script optionally queries the Relative Strength Index (RSI) from a higher timeframe. If this filter is engaged, bullish breakouts are ignored unless the HTF RSI indicates bullish momentum, adding a crucial layer of directional confirmation.
• Volatility-Adjusted Target Mapping
Upon a valid breakout, the script captures the current ATR. It then maps out a predefined trade setup. The Entry is plotted slightly past the breakout line, the Stop Loss is placed at a multiple of the ATR away from the entry, and up to three Take Profit levels are projected using independent ATR multipliers.
🔍 Deconstruction of the Underlying Scientific and Academic Framework
The indicator translates discretionary price action theory into a strict, rule-based algorithmic framework grounded in discrete mathematics and statistical dispersion.
• Local Extrema in Discrete Time Series
The pivot detection relies on the mathematical definition of local extrema within a bounded domain. For a given time series of high prices $H_t$, a local maximum is identified at time $t$ if $H_t \ge H_{t \pm k}$ for a defined neighborhood $k$ (the Swing Length). By anchoring structural logic to these extrema, the script removes the subjectivity of trendline drawing, relying strictly on empirical data points that define the boundaries of recent market equilibrium.
• Measurement of Dispersion via True Range
The risk management module utilizes the Average True Range. The True Range ( NYSE:TR $) is defined as the greatest of the following: the current high minus the current low, the absolute value of the current high minus the previous close, or the absolute value of the current low minus the previous close. The ATR is a smoothed moving average of this NYSE:TR $. In academic finance, variance and standard deviation are common measures of risk; however, ATR is particularly robust for trading applications as it accounts for overnight gaps and limits, providing a highly adaptive measurement of kinetic market energy to appropriately size stop-loss thresholds.
• Relative Momentum Standardization
The Higher Timeframe filter utilizes the Relative Strength Index. The RSI standardizes the velocity of price movement onto a 0-100 scale by comparing the exponential moving average of recent gains to recent losses. By enforcing a rule where NYSE:RSI > 50$ is required for bullish structural breaks, the algorithm mathematically demands that the higher-degree derivative of price (momentum) aligns with the lower-degree breakout, statistically reducing the probability of mean-reverting false breakouts.
🎨 Visual Guide
The script provides a rich, non-intrusive visual overlay to keep the trader informed of all active states and historical context.
• Structure Break Lines
Dashed Green Lines: Indicate historical and active Bullish breakouts.
Dashed Red Lines: Indicate historical and active Bearish breakouts.
Trend Labels: Triangles and markers (▲ BOS / ▼ CHoCH) appear at the midpoint of the break line to clearly annotate the structural shift.
• Trade Projection Lines
When a break is active, a cluster of dashed lines projects to the right of the current price action:
Blue Line (►): Proposed Entry level.
Red Line (✕): Stop Loss level based on ATR.
Green Lines (●, ★, ◆): Three tiered Take Profit targets based on escalating ATR multiples.
• The Heads-Up Dashboard
Located in the top right corner, this table is the operational nerve center. It displays:
Asset Ticker and Current Trend status.
HTF Direction and a visual block-bar representation of the HTF RSI.
Active BOS Level and Target Status (⏳ Pending or ✓ Hit).
Exact price coordinates for Entry, SL, and all TPs.
The active Risk-to-Reward (R:R) ratio for the first target.
Statistical tracking of Total BOS counts and the duration (in bars) of the active setup.
📖 How to Use
Traders can utilize this script as a complete ruleset for navigating trend continuations and reversals.
When observing the chart, wait for the script to print a new BOS or CHoCH label. This signifies that a confirmed candle has closed beyond a significant structural pivot. If the HTF filter is enabled, this break already has the backing of higher timeframe momentum.
Once the break prints, look to the dashed projection lines and the dashboard. The dashboard will display exact coordinates for a theoretical trade setup. You can use the blue Entry line to plan limit orders or market execution upon pullbacks. Set your structural stop-loss according to the red SL line, and place limit orders to secure profits at the green TP lines.
Monitor the Dashboard's "Tgt Status". If price action reverses heavily and crosses the opposing pivot point before reaching the target, the script will trigger its auto-invalidation sequence, clearing the active lines and returning to a neutral scanning state. This helps in dynamically cutting risk when a setup structurally fails.
⚙️ Inputs and Settings
The indicator is highly customizable, allowing adaptation to any asset or timeframe.
• BOS Group
Swing Length: Determines the lookback and lookforward period for pivot detection. Lower values react faster but produce more noise; higher values identify major macro swings.
• Visibility Group
Show BOS Line / Labels: Toggles the historical structural break drawings.
Auto-Invalidate: When enabled, the script will cancel an active setup if the opposing structural extreme is breached.
Color settings: Fully customize the hues for Bullish breaks, Bearish breaks, and Targets.
• SL/TP Group
Show Entry/SL/TP: Toggles the projection lines on the chart.
ATR Length: The lookback period for calculating market volatility.
Multipliers: Adjust the SL ATR Multiplier and the individual TP1, TP2, and TP3 multipliers to define your specific risk-to-reward parameters.
• HTF Group
HTF: Select the resolution for the higher timeframe filter (e.g., 240 for 4-hour, D for Daily).
HTF Filter: Toggle the momentum alignment requirement on or off.
HTF RSI Len: The period for the higher timeframe momentum oscillator.
• Alerts Group
The script features built-in webhook-ready JSON alerts that can notify external services the moment a BOS occurs or a target is successfully hit.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. I expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Indicator

MS & RSI Divergences [invincible3]MS & RSI Divergences
MS & RSI Divergences is a market-structure-based trading tool designed to identify key swing highs, swing lows, RSI regular divergences, and swing-based volume profile zones directly on the main chart.
This indicator combines price action structure, momentum divergence, and volume distribution into one visual framework, helping traders analyze whether price movement is supported or weakened by momentum and volume.
The script detects confirmed pivot highs and lows using user-defined left and right lookback bars, then classifies each swing as:
HH — Higher High
LH — Lower High
HL — Higher Low
LL — Lower Low
It also draws a dotted ZigZag between confirmed swings, making the overall market structure easier to read. The active swing is dynamically updated, so if another stronger high or lower low appears before the opposite pivot forms, the script keeps only the strongest valid swing. This helps reduce duplicate or weak swing labels and keeps the chart cleaner.
Key Features
1. Market Structure Detection
The indicator automatically identifies major swing points and labels them as HH, LH, HL, or LL. This helps traders quickly understand whether the market is forming bullish continuation, bearish continuation, or possible reversal structure.
A sequence of HH + HL usually reflects bullish structure, while LH + LL usually reflects bearish structure.
2. RSI Regular Divergence
The indicator uses RSI to detect regular divergences at confirmed swing points.
A bearish divergence is detected when price forms a higher high, but RSI forms a lower high. This can suggest weakening bullish momentum.
A bullish divergence is detected when price forms a lower low, but RSI forms a higher low. This can suggest weakening bearish momentum.
Divergence lines are drawn directly on price, with a “D” label marking the divergence area.
3. Swing Volume Profile
For each completed swing leg, the indicator can draw a volume profile between the previous swing and the current swing.
This shows where the most trading activity occurred inside that swing range. The profile also includes a dashed POC line, which represents the price level with the highest volume concentration inside the swing.
This can help identify important reaction zones, support/resistance areas, and volume-based decision levels.
4. Leg Statistics
The indicator can display swing-leg statistics, including:
Total leg volume
Volume delta approximation
POC price
The delta is estimated using candle direction, where bullish candles contribute positive volume and bearish candles contribute negative volume.
Main Settings
Market Structure Settings
Left Bars Lookback controls how many bars are checked on the left side of a pivot.
Right Bars Lookback controls how many bars are required after a pivot before it is confirmed.
Show MS Labels enables or disables HH, LH, HL, and LL labels.
Show Dotted ZigZag enables or disables the dotted swing connection line.
RSI Divergence Settings
Show Regular Divergences enables or disables RSI divergence detection.
RSI Length controls the RSI calculation period.
You can also customize bullish and bearish divergence colors.
Swing Volume Profile Settings
Show Swing Volume Profiles enables or disables the volume profile for each swing.
Profile Granularity controls the number of volume rows.
Profile Width controls how far the profile extends to the right.
Show Leg Stats displays volume, delta, and POC information.
Background Transparency controls the visibility of the profile background box.
How to Use
Use the market structure labels to understand the current trend direction.
Use RSI divergence signals near HH, LH, HL, or LL areas to detect possible momentum weakness.
Use the swing volume profile and POC line to find price zones where volume was concentrated.
For stronger confirmation, combine this indicator with support/resistance, trendlines, higher-timeframe bias, or your own trading system.
Important Notes
This indicator uses pivot-based logic, so swing labels appear only after the required right-side confirmation bars have closed.
The active swing can update until the opposite swing is confirmed. This is intentional because the script keeps the strongest high or lowest low before a new opposite pivot appears.
This tool is designed for analysis and decision support. It should not be used alone as a buy or sell signal.
Best Used For
Price action analysis
Market structure reading
RSI divergence detection
Swing trading
Trend reversal analysis
Support and resistance confirmation
Volume profile-based swing analysis
Disclaimer
This indicator is for educational and analytical purposes only. It does not guarantee future price movement. Always use proper risk management and confirm signals with your own trading strategy before making trading decisions. Indicator

Kalman Flow TrailKalman Flow Trail
Kalman Flow Trail is a clean trend-following and market structure overlay designed to help traders read market direction, structural shifts, protected levels, liquidity targets, and higher-timeframe alignment from one chart.
The script combines an adaptive Kalman-based trail with market structure logic, live strong/weak range levels, POI supply and demand zones, optional MSS/MSB guides, higher-timeframe confirmation, flip markers, and a compact Flow Dashboard.
Core Features
1. Adaptive Kalman Flow Engine
At the centre of the script is a dual Kalman smoothing engine designed to filter market noise while tracking directional flow.
Unlike a standard moving average with fixed behaviour, the trail adapts using market structure activity and volatility. When price action becomes more active, the trail can respond faster. When price is choppy or compressed, the trail becomes smoother to reduce unnecessary noise.
The engine also includes a structure-bias filter to help reduce overreaction when Kalman momentum and market structure are not aligned.
2. MSS / MSB Structure Guides
Kalman Flow Trail includes optional structure guides for traders who want to see internal market structure directly on the chart.
MSS = Market Structure Shift
MSB = Market Structure Break
These guides can be toggled on or off depending on whether the trader wants a detailed structure view or a cleaner visual layout.
3. Live Strong & Weak Range Levels
The script automatically tracks swing structure and highlights strong protected levels and weak target levels.
Strong levels represent the protected side of the current range.
Weak levels represent likely liquidity targets.
When a weak target is swept, the level can roll forward live with the current extreme until a new confirmed pivot forms. This helps keep the range logic responsive during strong continuation moves.
4. POI Supply & Demand Zones
The script can draw POI zones from important structural pivot areas.
In a bullish range, the POI highlights a potential demand area around the protected strong low.
In a bearish range, the POI highlights a potential supply area around the protected strong high.
The zones use theme-adaptive colours and dashed borders for a cleaner and more professional chart style.
5. Higher-Timeframe Confirmation
The optional HTF Kalman Basis allows traders to compare current chart flow with a selected higher timeframe.
For example, traders can view a 1H Kalman basis while analysing a 5-minute or 15-minute chart. This helps identify whether lower-timeframe price action is aligned with the broader market direction.
6. Flow Dashboard
The built-in Flow Dashboard gives a compact read of current market conditions:
Trail Direction
Kalman Momentum
HTF Alignment
Range State
This allows traders to quickly check whether the current flow, momentum, higher timeframe, and range structure are aligned.
7. Trail Flip Markers
Diamond markers appear when the Kalman Flow Trail changes direction.
These Trail Flip markers are designed to highlight possible shifts in directional flow. They are not standalone buy or sell signals, but they can help traders identify when market conditions are changing.
8. Proximity Star
The live trail star follows the active trail level.
When price moves close to the trail, the star changes into a warning state. This can help traders see when price is approaching a possible reaction area, mean-reversion zone, or potential trail breach.
Visual Themes
Kalman Flow Trail includes multiple built-in colour themes:
Lucid Neon
Ember Pulse
Arctic Signal
Violet Flux
Mono Current
Custom Theme
Users can also toggle trail glow, trail fill, trail boundaries, flip diamonds, live trail star, HTF basis, POI zones, MSS/MSB guides, and candle colouring.
How Traders Can Use It
Trend Continuation
Look for price respecting the trail and holding above protected demand areas in bullish conditions, or below protected supply areas in bearish conditions.
Trail Flip
Use diamond markers as visual alerts that directional flow may be shifting.
Strong / Weak Range Logic
Use strong levels as protected structure and weak levels as potential liquidity objectives.
HTF Alignment
Higher-quality conditions generally occur when Trail Direction and HTF Alignment point in the same direction.
POI Zones
Use POI Demand and POI Supply zones as structural areas of interest for reactions, continuation, or invalidation.
Best Use Cases
Trend-following analysis
Market structure reading
Liquidity target mapping
Higher-timeframe confirmation
Clean visual trend tracking
Crypto, Forex, Indices, Stocks, and Commodities
Notes
This indicator is designed as an analytical tool. It does not predict the future and should not be used as a standalone trading system. Traders should combine it with their own market context, confirmation process, and risk management.
Disclaimer
Trading involves risk. This script is for educational and analytical purposes only and does not constitute financial advice.
Indicator

Market State Forecast Projection EngineThis indicator is a **forecast projection tool**. It looks at the current market environment, searches history for the most similar environments, then plots what usually happened afterward. It is not trying to predict the future with certainty. It is saying: “When the market looked like this before, what tended to happen next?”
The engine defines the current market environment using three things:
* **Trend**, based on moving averages.
* **Momentum**, based on RSI.
* **Volatility**, based on ATR.
Then it finds the closest historical matches, studies their future paths, and draws a forecast line with optional upper and lower bands.
---
## What You See on the Chart
### Forecast Midline
The main forecast line shows the **average path** of the selected historical matches.
In simple terms:
* If similar past situations usually moved higher, the line slopes up.
* If similar past situations usually moved lower, the line slopes down.
* If similar past situations were mixed, the line may be flat or choppy.
### Upper Band
The upper band shows the stronger side of historical outcomes.
It means:
* Some similar historical setups moved better than the average.
* The upper band gives you a visual idea of the upside range from those past examples.
* It is not a guaranteed target.
### Lower Band
The lower band shows the weaker side of historical outcomes.
It means:
* Some similar historical setups moved worse than the average.
* The lower band gives you a visual idea of downside risk from those past examples.
* It is not a guaranteed support level.
### Band Width
The space between the bands matters.
* Tight bands mean historical outcomes were more consistent.
* Wide bands mean historical outcomes were scattered and less reliable.
* A forecast with wide bands should be treated with more caution.
---
## Main Inputs
### Non-Repaint Mode
**Default: On**
This controls whether the forecast uses the live candle or the last completed candle.
Use **Non-Repaint Mode On** when:
* You want more stable signals.
* You want the forecast to update only after the candle closes.
* You care about cleaner historical testing.
Use **Non-Repaint Mode Off** when:
* You want the forecast to react during the current live candle.
* You accept that the forecast may change before the candle closes.
For most use cases, leave this **On**.
---
## Model Group
### Forecast Horizon
This controls how far into the future the indicator projects.
Example:
* On a daily chart, `20` means 20 trading days.
* On a 1-hour chart, `20` means 20 hours.
* On a 5-minute chart, `20` means 20 five-minute candles.
Use a lower value when:
* You are trading short-term moves.
* You want a tighter forecast window.
* You do not want the projection stretched too far.
Use a higher value when:
* You are looking for swing-trade context.
* You want to see the broader projected path.
* You are using higher timeframes.
A practical range is usually:
* `10–20` for shorter-term analysis.
* `20–50` for swing-style analysis.
---
### Search Depth
This controls how much history the engine searches.
Example:
* `1000` means the engine searches roughly 1,000 prior bars.
* `2000` means it searches more history.
* `500` means it searches less history.
Use a higher Search Depth when:
* You want a larger historical sample.
* You are on a short timeframe with lots of bars.
* You want more possible market-state comparisons.
Use a lower Search Depth when:
* You want the model to focus on more recent market behavior.
* You are on a slower chart like daily or weekly.
* You want less influence from older market regimes.
The tradeoff is simple:
* More history gives more examples.
* Less history may be more relevant to the current market regime.
---
### Pattern Matches
This controls how many of the closest historical matches are used.
This is one of the most important inputs.
If set to `30`, the engine finds the **30 closest historical market states** and builds the forecast from those.
Use fewer matches when:
* You want stricter, more specific comparisons.
* You want only the closest historical examples.
* You are okay with a forecast that may be more reactive.
Use more matches when:
* You want a smoother forecast.
* You want less noise from individual examples.
* You want a broader historical sample.
General interpretation:
* `10–20` = stricter, more selective.
* `25–40` = balanced.
* `50+` = broader, smoother, but less specific.
---
### Weight Closer Matches
This controls whether the best matches receive more influence.
When turned **On**:
* The closest historical matches matter more.
* Weaker matches still count, but less heavily.
* The forecast becomes more focused on the most similar examples.
When turned **Off**:
* Every selected match is treated equally.
* The forecast becomes more democratic.
* A very close match and a weaker match have the same influence.
For most users, leave this **On**.
---
## Advanced Model Inputs
### Forecast Model
This chooses how the engine defines the market environment.
All models use:
* EMA trend.
* RSI momentum.
* ATR volatility.
The difference is how each model emphasizes those ingredients.
---
### Conservative
Use **Conservative** when you want a slower, smoother model.
It is designed to:
* React less aggressively.
* Favor more stable market environments.
* Put more importance on trend and volatility.
* Reduce noisy forecast changes.
Best for:
* Daily charts.
* Swing trading.
* Slower-moving stocks or ETFs.
* Users who want fewer false shifts.
---
### Balanced
Use **Balanced** as the general-purpose default.
It is designed to:
* Give trend, momentum, and volatility a normal balance.
* Work across many markets.
* Avoid being too slow or too fast.
Best for:
* Most users.
* Most chart timeframes.
* General market forecasting.
* Starting point before testing other models.
---
### Aggressive
Use **Aggressive** when you want a faster model.
It is designed to:
* React more quickly to changing momentum.
* Give more influence to short-term market shifts.
* Be more sensitive to fresh moves.
Best for:
* Intraday trading.
* Fast-moving markets.
* Crypto.
* Momentum names.
* Traders who want earlier, more responsive shifts.
The downside is that it may be noisier.
---
### Trend Following
Use **Trend Following** when you want the model to emphasize persistent directional moves.
It is designed to:
* Care more about trend structure.
* Care less about short-term momentum noise.
* Favor markets that continue moving in the same direction.
Best for:
* Strong trending stocks.
* Indexes.
* Breakout environments.
* Higher-timeframe directional trading.
This model is less ideal in sideways or choppy markets.
---
### Mean Reversion
Use **Mean Reversion** when you want the model to focus on stretched conditions.
It is designed to:
* Emphasize momentum extremes.
* Look for environments where price may snap back or reverse.
* Care less about long-term trend persistence.
Best for:
* Range-bound markets.
* Overbought/oversold setups.
* Countertrend analysis.
* Shorter-term reversal ideas.
This model may fight strong trends, so use it carefully in momentum-heavy markets.
---
## Historical Lookback Inputs
### Lookback Bars
This lets you move the forecast backward in time.
Example:
* `0` means current forecast.
* `50` means show what the forecast would have looked like 50 bars ago.
* `250` means show what the forecast would have looked like 250 bars ago.
Use this for:
* Visual backtesting.
* Studying old setups.
* Checking whether the forecast was useful historically.
* Comparing forecast paths against what actually happened.
This is one of the most valuable testing features.
---
### Lock to Candle
This lets you anchor the forecast to a specific candle time instead of a simple bar offset.
Use it when:
* You want to test a specific time of day.
* You trade a regular session open.
* You want repeatable historical anchors.
Example:
* You can lock to the 13:30 UTC candle, which often corresponds to the U.S. stock market open during daylight saving time.
When this is off, the indicator uses **Lookback Bars** instead.
---
### Days Back
This works with **Lock to Candle**.
It tells the indicator how many matching anchor candles to go back.
Example:
* `0` = most recent matching candle.
* `1` = one matching session back.
* `2` = two matching sessions back.
Use this when:
* You want to test the most recent open.
* You want to test yesterday’s open.
* You want to step through past sessions one by one.
---
### Hour UTC
This is the UTC hour used for candle locking.
Use it with **Minute UTC** to identify the exact candle you want.
Example:
* `13` means 13:00 UTC.
* Combined with `30`, it means 13:30 UTC.
This is useful because PulseWire symbols and sessions can vary, but UTC gives a consistent anchor.
---
### Minute UTC
This is the UTC minute used for candle locking.
Example:
* Hour UTC = `13`
* Minute UTC = `30`
Together, that means:
* Lock to the 13:30 UTC candle.
Use this for precise historical testing.
---
### Auto Previous Session
This controls what happens if today’s target candle has not printed yet.
When turned **On**:
* The indicator automatically uses the most recent previous matching candle.
* This keeps the forecast visible even before today’s target time exists.
When turned **Off**:
* If today’s target candle has not printed, the lock may show no match and fall back.
For most users, leave this **On**.
---
## Bias Logic Inputs
### Bias Threshold %
This controls how strong the bull or bear probability must be before the indicator labels the forecast bullish or bearish.
Example:
* If Bias Threshold is `60`, Bull Probability must be at least 60% before a bullish label can appear.
* If Bear Probability is at least 60%, a bearish label can appear.
Use a lower threshold when:
* You want more frequent bias labels.
* You are okay with weaker directional evidence.
Use a higher threshold when:
* You want stricter signals.
* You only want stronger historical agreement.
Practical range:
* `60%` = balanced.
* `70%+` = more conservative.
* `50–55%` = loose and more signal-heavy.
---
### Minimum Bull/Bear Edge %
This controls how large the gap must be between Bull Probability and Bear Probability.
Example:
* Bull Probability = 65%
* Bear Probability = 35%
* Edge = 30 percentage points
If the minimum edge is `15`, this would qualify.
But:
* Bull Probability = 58%
* Bear Probability = 42%
* Edge = 16 percentage points
This may still fail if Bull Probability is below the Bias Threshold.
This input prevents weak differences from being labeled as strong directional bias.
Use a higher edge when:
* You want cleaner bias labels.
* You want the model to avoid borderline calls.
Use a lower edge when:
* You want more frequent directional bias.
* You accept more uncertainty.
---
## Display Inputs
### Show Forecast Midline
This turns the main forecast line on or off.
Turn it **On** when:
* You want to see the projected average path.
Turn it **Off** when:
* You only want the info box probabilities.
* You want a cleaner chart.
---
### Show Confidence Bands
This turns the upper and lower forecast bands on or off.
Turn it **On** when:
* You want to see the historical range of outcomes.
* You care about uncertainty.
* You want to know whether the forecast is tight or messy.
Turn it **Off** when:
* You only want the central forecast.
* The chart feels too cluttered.
---
### Band Width Multiplier
This controls how wide the bands are.
Higher values make the bands wider.
Lower values make the bands tighter.
Use lower values when:
* You want a cleaner, tighter visual range.
* You want bands closer to the average forecast.
Use higher values when:
* You want to see a broader range of historical outcomes.
* You want a more conservative uncertainty envelope.
Default `1.0` is a good starting point.
---
## Forecast Midline Style Inputs
### Forecast Midline Color
Controls the color of the main projection line.
The default aqua color makes it visually distinct from price candles.
### Forecast Midline Width
Controls how thick the midline is.
Use a thicker line when:
* You want the forecast to stand out.
* You are using a busy chart.
Use a thinner line when:
* You want a cleaner chart.
* You use many overlays.
### Forecast Midline Type
Controls whether the line is:
* Solid.
* Dashed.
* Dotted.
Solid is usually best for the main forecast line.
---
## Upper Band Style Inputs
### Upper Band Color
Controls the color of the upper forecast band.
The default green tone suggests upside range.
### Upper Band Width
Controls how thick the upper band is.
A thin dashed line usually works best because it should be secondary to the midline.
### Upper Band Type
Controls whether the upper band is solid, dashed, or dotted.
Dashed is usually best because it visually communicates “range” rather than “target.”
---
## Lower Band Style Inputs
### Lower Band Color
Controls the color of the lower forecast band.
The default red tone suggests downside range.
### Lower Band Width
Controls how thick the lower band is.
A thin line keeps it useful without dominating the chart.
### Lower Band Type
Controls whether the lower band is solid, dashed, or dotted.
Dashed is usually best for the same reason as the upper band.
---
## Info Box Inputs
### Show Info Box
This turns the dashboard on or off.
Turn it **On** when:
* You want the probabilities and diagnostics visible.
* You are actively evaluating the forecast.
Turn it **Off** when:
* You only want the chart projection.
* You want a cleaner visual layout.
---
### Info Box Position
Controls where the dashboard appears.
Options:
* Top Left.
* Top Right.
* Bottom Left.
* Bottom Right.
Use the position that interferes least with price action on your chart.
---
### Text Size
Controls the dashboard text size.
Use:
* **Tiny** for compact charts.
* **Small** for normal use.
* **Normal** if you want easier reading.
* **Large** for presentations or large monitors.
---
### Background
Controls the info box background color.
A darker background usually works best on most PulseWire chart themes.
### Border
Controls the info box border color.
This helps separate the dashboard from the chart.
### Header Text
Controls the title/header text color.
### Header Background
Controls the top header row background.
This gives the dashboard its polished look.
---
## Info Box Metrics
### Bull Prob %
This shows the weighted percentage of selected historical matches that ended bullish.
Simple meaning:
> Of the similar historical market states, how many tended to move up?
A high number means bullish outcomes dominated the selected historical matches.
---
### Bear Prob %
This shows the weighted percentage of selected historical matches that ended bearish.
Simple meaning:
> Of the similar historical market states, how many tended to move down?
A high number means bearish outcomes dominated the selected historical matches.
---
### Direction Bias
This shows the final label after applying the bias rules.
Possible outputs:
* Bullish.
* Bearish.
* None.
* Weak Data.
* No Matches.
A bullish or bearish label only appears when the probability and edge requirements are met.
---
### Bull/Bear/Flat
This shows how many selected matches ended:
* Bullish.
* Bearish.
* Flat.
Example:
* `18 / 9 / 3`
This means:
* 18 bullish historical outcomes.
* 9 bearish historical outcomes.
* 3 flat historical outcomes.
This gives you a quick look at the underlying distribution.
---
### Match Count
This shows how many historical matches were actually used.
If Pattern Matches is set to `30`, Match Count should usually show `30`.
If it shows less, there may not have been enough valid historical data.
---
### Fit Quality
This tells you how closely the selected historical matches resemble the current market state.
High Fit Quality means:
* The current market environment closely resembles the selected historical examples.
Low Fit Quality means:
* The engine found matches, but they were not very close.
Important:
* Fit Quality is not win rate.
* Fit Quality is not probability.
* Fit Quality is not accuracy.
* It only measures how good the historical comparisons are.
Best interpretation:
* High Fit Quality + strong Bull/Bear Probability = more compelling.
* High Fit Quality + split probabilities = similar markets existed, but outcomes were mixed.
* Low Fit Quality = be cautious.
---
### Model
This shows which Forecast Model is active.
Examples:
* Balanced.
* Conservative.
* Aggressive.
* Trend Following.
* Mean Reversion.
This is useful for screenshots and reviewing past setups.
---
### Anchor
This tells you where the forecast is anchored.
Examples:
* `0 bars · NR` means current forecast using Non-Repaint Mode.
* `50 bars · NR` means historical forecast from 50 bars ago.
* `Locked` means it is anchored to a specific UTC candle.
This helps you know whether you are looking at a current forecast or a historical replay.
---
### Search Depth
This shows the actual number of bars being searched.
It may be lower than your input if the chart does not have enough loaded history.
---
## Best Practical Way to Use It
A clean workflow would be:
* Start with **Balanced** model.
* Keep **Non-Repaint Mode On**.
* Use **Pattern Matches around 30**.
* Use **Search Depth around 1000**.
* Watch **Fit Quality**.
* Watch **Bull/Bear Probability**.
* Treat the forecast line as a scenario path, not a guaranteed prediction.
* Use **Lookback Bars** to test whether the forecast was historically useful.
* Avoid trusting any forecast where the bands are very wide and probabilities are split.
The strongest setup is usually when:
* Fit Quality is high.
* Bull or Bear Probability is clearly dominant.
* The forecast bands are not extremely wide.
* The projection agrees with price structure.
Indicator

Structure & Trend ContextStructure & Trend Context is a clean overlay that visualises market structure and trend direction without cluttering the chart. It is built as a context tool to support your own analysis, not as a signal system.
What it shows
- Trend filter: a fast and a slow EMA define the prevailing direction. The slow EMA is colour-coded by bias (up / down / neutral).
- Volatility band: an ATR band around the fast EMA gives a sense of normal price travel and dynamic over-/under-extension.
- Swing structure: the most recent confirmed swing high and swing low are tracked and drawn as reference levels.
- Structure breaks (BoS): a marker appears only when price closes beyond the prior swing by an ATR buffer while in trend. Each level is locked after it breaks, so markers stay rare and meaningful rather than firing on every minor poke.
- Context panel: a compact top-right table showing current trend bias, last higher high and last lower low.
How to use it
Read the chart first. Use the trend filter and band for context, the swing levels for reference, and treat a structure break as one piece of confluence, not a standalone trigger. Raise "Swing sensitivity" on higher timeframes or noisy assets to keep only the larger structure.
Inputs
Every layer (band, swing levels, structure markers, raw pivots, panel, bar tint) has its own toggle, and the EMA, ATR and pivot lengths are fully adjustable.
Notes
This indicator is a visualisation aid for discretionary analysis. It does not predict price, does not generate buy or sell recommendations, and is not financial advice. Markers are confirmed on bar close and do not repaint. Open-source — adapt it to your own workflow. Indicator

Sloped LinReg Volume Profile [MarkitTick]💡 This indicator introduces a highly dynamic approach to volume and price analysis by merging standard volume principles with vector-based linear regression. Rather than plotting volume distributions on a static horizontal plane, this tool maps volume nodes parallel to the prevailing mathematical trend. By constructing a localized volume profile that follows the trajectory of price action, it captures momentum-adjusted value areas, providing an advanced lens for interpreting market geometry, support/resistance, and volume anomalies. It is strictly engineered for standard candlestick charts, specifically excluding non-standard formats to ensure pristine volume and price data integrity.
● ✨ Originality and Utility
Standard volume profiles aggregate historical volume at fixed price levels, which often creates fragmented or obsolete value nodes when a market is actively trending. This indicator resolves that structural limitation by angling the volume bins to match the slope of a linear regression channel.
It identifies where volume is concentrated relative to the trend's axis, not just the absolute price.
It reveals volume-weighted momentum, highlighting whether buying or selling pressure is accelerating in the direction of the regression slope.
The tool includes an integrated, dark-mode optimized analytics dashboard that processes quantitative metrics natively on the chart without requiring secondary oscillators.
● 🔬 Methodology and Concepts
The foundational logic relies on computing a rolling linear regression to establish a baseline trajectory over a specified period. The methodology relies on Pine Script's time-series event loop, evaluating arrays of data dynamically as new bars form.
Vector-Based Binning: Instead of horizontal rows, the profile utilizes a dynamic upper and lower deviation band. The mathematical distance between these bands is partitioned into a user-defined number of rows.
Volume Distribution: As the script loops through the historical lookback window, it evaluates the volume of each bar. The volume is divided proportionally across the sloped bins that intersect the bar's high-low range.
Directional Volume (Delta): Each bin further categorizes volume into "Buy" or "Sell" categories based on whether the bar's closing price was greater than or equal to its opening price.
Value Area Calculation: The Point of Control (POC) identifies the sloped bin with the highest total volume. The Value Area High (VAH) and Value Area Low (VAL) expand outward from the POC until they encapsulate a specific percentage of the total allocated volume, dynamically updating as price action develops.
● 🎨 Visual Guide
Every visual element is rendered utilizing Pine Script's advanced drawing arrays and is fully user-configurable to support dark-mode analytical environments.
• The Sloped Profile
Volume Bars: Rendered as polygons extending inward from the right side of the channel. The length of each polygon represents the relative volume allocated to that specific standard deviation bin.
Color Coding: Bullish volume defaults to a translucent teal, while bearish volume displays as a translucent red. Bins experiencing extraordinary volume influxes override with a bright, high-visibility color to highlight anomalous market participation.
• Channel and Level Lines
Regression Bounds: Solid or semi-transparent lines mapping the start and end of the regression channel, defining the upper and lower standard deviation extremes.
POC Line: A thick, solid yellow line plotting the Point of Control across the length of the channel.
Value Area Lines: Dashed blue lines tracking the VAH and VAL. The area between these lines is shaded with a deep blue fill to instantly highlight the trend's core acceptance zone.
Delta POC: A dashed fuchsia line identifying the bin with the most extreme difference between buying and selling volume.
• Analytics Dashboard
Located in the top right, this table provides real-time quantitative readouts formatted to precise tick values.
LinReg Slope: Indicates the mathematical direction of the trend (Bullish/Bearish).
Price Regime: Identifies if the current close is inside the channel or breaking the upper/lower bounds.
Volume POC & Delta POC: Displays the exact price equivalents of the sloped control lines at the current bar index.
Buy Vol Bias: A visual progress bar detailing the ratio of bullish to bearish volume within the regression window.
Vol Compression: Evaluates the density of the value area. A highly concentrated value area yields a higher compression score.
● 📖 How to Use
The indicator serves as a complete environmental map for trending markets.
Trend Qualification: Utilize the slope of the regression channel to establish the primary directional bias. Trades should ideally align with the slope.
Value Area Rejections: The VAH and VAL lines function as dynamic support and resistance. A price action rejection at the VAH within a downward-sloping channel offers a high-probability continuation setup.
POC Magnetism: Price will naturally gravitate toward the sloped POC. Deviations far outside the Value Area typically mean-revert to the POC unless accompanied by a severe volume imbalance.
Interpreting Delta: Compare the traditional POC to the Delta POC. If the Delta POC rests significantly higher or lower than the overall Volume POC, it indicates an aggressive concentration of directional absorption (trapped buyers or sellers).
Repainting Warning: Because this indicator calculates a dynamic linear regression over a moving lookback window, the visual placement of the channel and profile will continually recalculate and shift on the real-time bar until the bar closes. This is standard behavior for dynamic geometric overlays, but users should wait for bar confirmation before executing trades based on channel interactions.
● ⚙️ Inputs and Settings
• Linear Regression Settings
Channel Length: Defines the historical lookback window (default is 100). Higher values create smoother, macro-trend profiles.
Source: The price data used for the regression calculation (Open, High, Low, Close, HL2, HLC3, OHLC4).
Upper/Lower Deviation: Toggles the outer bounds of the channel and sets the standard deviation multipliers.
• Sloped Volume Profile Settings
Number of Rows: The granularity of the profile. More rows create thinner, more precise volume nodes.
Profile Width %: Determines how far the volume polygons stretch across the screen relative to the channel length.
Value Area %: The percentage of total volume to include within the VAH and VAL bounds (default 70%).
• Advanced Quant Analytics
Highlight Footprints: Visually isolates volume bins that exceed two standard deviations above the mean bin volume.
Calculate Anchored VWAP: Toggles the inclusion of an Anchored VWAP (anchored to the start of the regression window) within the dashboard matrix.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. I expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Indicator

Indicator

STWP Market MatrixOverview
STWP Market Matrix is a multi-factor market dashboard designed to consolidate several commonly used technical concepts into a single visual framework.
Most technical indicators focus on one aspect of market analysis, such as trend, volume, volatility, or support and resistance. STWP Market Matrix combines these factors into a structured dashboard so traders can evaluate market conditions from multiple perspectives without switching between several indicators.
The objective is not to generate buy or sell signals, but to provide a quick and organized view of trend direction, participation, relative strength, volatility conditions, and key market reference levels.
________________________________________
Why This Indicator?
Market decisions are often influenced by multiple factors rather than a single indicator. A stock may show a bullish trend but weak participation, strong volume but poor relative strength, or favorable structure while trading below key reference levels.
STWP Market Matrix brings together:
• Trend Analysis (EMA Structure)
• VWAP Positioning
• Buyer vs Seller Participation
• Volume Assessment
• Market Structure Analysis
• Multi-Timeframe Confirmation
• Relative Strength vs NIFTY
• Daily Volume Context
• Pivot Reference Levels
• Volatility Assessment
into one dashboard to help users evaluate these conditions simultaneously.
________________________________________
Dashboard Components
Trend
Trend is determined using Fast and Slow Exponential Moving Averages (EMA).
Bullish: Fast EMA above Slow EMA
Bearish: Fast EMA below Slow EMA
This provides a simple directional bias.
________________________________________
VWAP
Displays whether price is trading above or below the Volume Weighted Average Price (VWAP).
VWAP is commonly used by traders to assess intraday strength and market positioning.
________________________________________
Buyers & Sellers
These metrics evaluate the balance between bullish and bearish candle pressure.
The goal is to provide a simple visual indication of whether buyers or sellers currently have greater influence on price movement.
________________________________________
Volume
Current volume is compared against average volume to identify participation levels.
Higher-than-average volume may indicate stronger market participation, while lower volume may suggest reduced activity.
________________________________________
Market State
The indicator classifies market conditions into:
Breakout
Breakdown
Range
based on recent price structure and historical highs/lows.
________________________________________
Price Structure
Price structure evaluates whether the market is producing:
Higher Highs and Higher Lows
Lower Highs and Lower Lows
Sideways Conditions
This provides additional context beyond simple trend analysis.
________________________________________
Multi-Timeframe Alignment
The dashboard evaluates whether higher timeframe EMA conditions support the current chart timeframe.
This helps identify whether trends are aligned across multiple timeframes.
________________________________________
Relative Strength (RS)
Relative Strength compares the selected symbol against the NIFTY Index.
Possible interpretations:
Outperforming
Underperforming
This helps identify whether a symbol is displaying relative leadership or weakness compared to the broader market.
________________________________________
Daily Volume
Daily volume is compared against its historical average to provide additional participation context.
________________________________________
Pivot Reference Framework
The dashboard includes classic pivot calculations based on the previous trading session's:
High
Low
Close
Displayed levels include:
Pivot
R1 to R5
S1 to S5
These levels are intended as objective reference zones that may help identify potential areas of support, resistance, reaction, or expansion.
The levels are not intended as price targets or predictions.
________________________________________
STWP Matrix Panel
Grade
A composite score derived from:
Trend Alignment
VWAP Position
Volume Participation
Relative Strength
Multi-Timeframe Confirmation
Grades range from D to A+.
Higher grades indicate stronger alignment among the evaluated factors.
________________________________________
Flow
Flow evaluates participation bias using candle position and volume behavior.
Possible states:
Accumulation
Distribution
Balanced
________________________________________
Energy
Energy evaluates volatility conditions using:
Bollinger Band Width
Average True Range (ATR)
Possible states:
Building
Normal
Exploding
This can help identify periods of contraction and expansion.
________________________________________
Risk
Risk provides a simplified assessment of current market conditions using momentum and volatility characteristics.
Possible states:
Low
Medium
High
________________________________________
Opportunity
Opportunity summarizes overall market conditions based on the dashboard's underlying factors.
Possible states:
Excellent
Good
Average
Avoid
This metric is intended to provide context and should not be interpreted as a trading recommendation.
________________________________________
Suggested Workflow
A possible workflow for using the dashboard:
Review Trend and VWAP alignment.
Evaluate Market State and Price Structure.
Check Relative Strength versus NIFTY.
Assess volume participation.
Review Pivot and Support/Resistance levels.
Evaluate Grade, Flow, Energy, Risk, and Opportunity readings.
Combine observations with personal analysis, trade planning, and risk management.
________________________________________
Limitations
The indicator relies entirely on historical price and volume data.
Pivot levels are reference zones and not guarantees of future market reactions.
Relative Strength readings may vary across instruments and timeframes.
Market conditions can change rapidly during periods of elevated volatility.
No technical indicator can predict future price movement with certainty.
The dashboard should be used as an analytical aid rather than a standalone decision-making system.
________________________________________
Disclaimer
This script is provided strictly for educational and informational purposes.
The indicator does not provide investment advice, research reports, trading recommendations, portfolio management services, or buy/sell calls.
All calculations are derived from historical price and volume data and are intended solely to assist technical analysis.
Users should conduct their own independent research, analysis, and risk assessment before making any trading or investment decisions.
Past performance does not guarantee future results. Financial markets involve risk, and losses may occur.
For users subject to SEBI regulations, this indicator should not be interpreted as a recommendation, solicitation, stock tip, investment advisory service, or research report.
Any trading or investment decision remains solely the responsibility of the user.
© Simple Trade With Patience (STWP)
Indicator

Confirmed Fibonacci with Market StructureConfirmed Fibonacci with Market Structure
-Description
A Fibonacci retracement tool for trend-continuation setups. It draws only after price has confirmed a directional move through market structure, then locks the levels in place so the pullback zone stays where it was set.
-What it does
The script applies three conditions before it draws a retracement, and once it draws, the anchors are fixed until the setup is invalidated:
- it requires a break of structure, not just any swing;
- it requires the impulse to be large enough relative to recent volatility;
- it can require agreement from the higher timeframe.
The result is a small number of retracements, drawn on moves that have shifted structure, that stay in place once set.
-How the detection works
1. Swing pivots. The script identifies swing highs and lows using pivot detection — a bar is a pivot high when it is the highest over a set number of bars to its left and right (the Pivot length input), and the reverse for a pivot low. These pivots define the prior swing and the structural reference levels.
2. Break of structure. For a bullish leg, the script takes the most recent prior swing low as the origin, then looks for an impulse high that trades above the last swing high formed before that low. Trading above that prior high is the break of structure — confirmation that buyers have shifted structure upward. The bearish case is the mirror image (a swing high origin, and an impulse low that breaks the prior swing low).
3. Displacement filter. The impulse is only accepted if its size (impulse high minus origin low) is at least a chosen multiple of ATR(14) — the Min displacement (ATR) input. Normalising to ATR judges a move on a quiet instrument and a volatile one on the same scale, and filters out small, insignificant structural breaks.
4. Draw timing. In Fast Draw mode the leg confirms on an asymmetric impulse pivot (fewer bars required to the right of the extreme), so the fib appears sooner after the high or low. With Fast Draw off, it instead waits for a completed pullback pivot before drawing — slower, but it only commits once a retracement is already underway.
-The Fibonacci leg and golden zone
When a bullish leg confirms, 0.0 is placed at the impulse high and 1.0 at the origin low, so the retracement levels measure how far price pulls back into the move (bearish legs are inverted). The shaded 0.618–0.786 band is the golden zone — the area where trend-continuation pullbacks commonly find support or resistance. A dashed line marks the broken structure level (BOS), and the impulse leg is labelled at its anchors (HH/HL for a bull leg, LH/LL for a bear leg).
-Higher-timeframe bias
The optional bias filter reads swing structure from the next standard timeframe up (for example, a 1-hour chart reads the 4-hour). That timeframe is rated bullish when its recent structure prints higher highs and higher lows, and bearish on lower highs and lower lows. With the filter on, the script only draws bullish legs in a bullish higher-timeframe context and bearish legs in a bearish one, and it clears the active leg if the higher timeframe flips against it. The request uses confirmed values with no lookahead.
-Invalidation and refresh
A bullish leg is invalidated when price closes below its origin low, with a small ATR buffer to absorb wicks; bearish legs mirror this. A leg is also cleared if it goes stale — when no new structure forms within a configurable number of bars. Until one of those happens, the anchors stay locked, so the levels on your chart are the same ones set when the leg confirmed.
-How to use it
This tool is built for trending markets and continuation trading, not ranges. The premise is simple: after a structure break and a displaced impulse, a trend often pauses and retraces before continuing in the same direction, and the golden zone is where that retracement commonly runs out of steam.
- Trade with the leg, into the pullback. On a confirmed bullish leg, treat the 0.618–0.786 golden zone as a pullback entry zone for longs — you are looking to join the move as price retraces into it, not to fade it. On a bearish leg, the same zone is where you look for shorts as price pulls back up into it.
- Use the higher-timeframe filter for alignment. Leaving HTF Bias on keeps you taking pullbacks in the direction of the larger trend, which is the context where continuation setups tend to hold up best. Turning it off shows every confirmed leg regardless of the bigger picture.
- Anchor risk to the structure the tool already marks. The origin (the 1.0 level, where the leg began) is the natural invalidation — a close back through it means the continuation idea has failed, which is also when the script clears the leg. Targets are typically toward the impulse extreme or beyond it. The BOS line shows the level whose break confirmed the move.
- Read the zone, don't blindly buy or sell it. The golden zone is an area of interest, not a trigger. Wait for your own confirmation inside it — a reaction candle, a lower-timeframe shift in structure, or whatever you normally use — before committing.
- The golden zone isn't the only level worth watching. Shallower retracements such as the 0.382 or the 0.500 often hold in strong trends that don't pull back far, while the deeper 0.618–0.786 zone tends to come into play on bigger retracements. Different instruments and timeframes react at different levels, so test which ones your pairs respect and toggle the levels you don't use off to keep the chart clean.
- Filter the chop. In ranging or low-momentum conditions a structure break is more likely to fail. Raise Min displacement (ATR) so the tool only draws on decisive moves, and set Pivot length to suit the timeframe (suggested starting points are in each input's tooltip).
-Inputs
-Structure
- Fast Draw (default on). On, the retracement is drawn as soon as the impulse, break of structure and displacement all confirm — the earliest possible draw. Off, it waits for a completed pullback pivot before drawing, which is slower but only commits once a retracement is already under way. Turning it off gives later but more conservative entries.
- Pivot length (default 8). Bars to the left and right used to confirm the structural swing highs and lows that define the prior swing and the break-of-structure reference. Higher values track larger, slower swings and draw fewer legs; lower values react to smaller swings and draw more. Rough starting points: 18 on 15m, 8 on 1h, 4 on 4h, 3 on daily.
- Impulse pivot R (default 3, Fast Draw only). The number of bars required to the right of the impulse extreme before it is accepted. Lower confirms the leg sooner after the high or low; higher waits for more confirmation, so the leg draws later but the extreme is more settled.
- Pullback pivot length (default 2, used only when Fast Draw is off). Bars left and right for the pullback pivot the script waits on before drawing. Lower draws faster on shallower pullbacks; higher requires a deeper, more developed pullback first.
- Min displacement (ATR) (default 1.5). The minimum impulse size, measured in ATR(14) units, before a structure break counts. Raising it ignores small moves and only draws on decisive ones; lowering it draws on smaller breaks too. As a guide: 0 accepts any impulse, 1.0 is modest, 1.5 is meaningful, 2.5 and up captures only major moves.
- Invalidation buffer (ATR) (default 0.25). A tolerance, in ATR(14) units, added beyond the origin before the leg is invalidated, so a single wick through the level doesn't cancel the setup. Higher gives the trade more room before it's cleared; lower invalidates more strictly.
- Max leg age (bars) (default 150). If no new structure forms within this many bars, the leg is treated as stale and cleared. Lower keeps only fresh setups on the chart; higher lets a quiet leg persist longer.
- Pivots retained (default 15). How many recent pivots the script keeps in memory to look back through when building a sequence. Higher allows it to reference older swings; lower keeps it focused on the most recent structure. Mostly affects edge cases — the default suits most charts.
HTF Bias
- Use HTF bias filter (default on). When on, the script only draws legs that agree with the higher-timeframe trend and clears a leg if that timeframe flips against it. Turning it off shows every confirmed leg regardless of the larger trend.
- HTF pivot length (default 3). Bars left and right used to read swing structure on the higher timeframe. Higher reads a broader, slower higher-timeframe trend; lower makes the bias more responsive.
Fib Levels
- 0.000 to 1.000 toggles. Switch each standard retracement level on or off independently, so you can show only the ones you trade.
- Custom level (default off, 0.75). Enables one extra level at a ratio you choose, with its own colour — useful for a level such as 0.705 or 0.79 that sits outside the standard set. Drawn alongside the standard levels.
Visual
- Colour Theme (default "Default"). Sets the dashboard colours and the fib line colour. Ten themes are included; purely cosmetic.
- 0.500 line color, Golden zone fill, Golden zone edge, Impulse line color, BOS line/label color. Individual colour controls for those specific elements, so you can tune contrast against your chart.
- Show BOS line + label (default on). Draws the dashed line at the broken structure level with a "BOS" tag. Off hides it for a cleaner chart.
- Show impulse line (default on). Draws the dashed line connecting the two anchors of the leg.
- Extend right (default on). Extends the level lines to the right of the current bar so they project forward; off ends them at the current bar.
- Price labels (default on). Shows the price value beside each level.
- Anchor markers (default on). Labels the two anchor points (HH/HL or LH/LL) of the leg.
- Info panel (default on). Shows the dashboard with structure state, higher-timeframe bias, anchor prices and how long ago the impulse confirmed.
Alerts
- Alert on new fib drawn (default on). Fires when a new bullish or bearish leg is drawn.
- Alert on Golden Zone touch (default on). Fires the first time price touches the golden zone of the active leg.
**Notes**
Swing pivots confirm a fixed number of bars after the actual high or low, so a leg appears after that confirmation delay rather than at the exact extreme — this is inherent to pivot-based detection. Once drawn, anchors are locked and do not move. The higher-timeframe bias uses confirmed values without lookahead, so it does not repaint on historical bars, though like any higher-timeframe data it can update within a forming higher-timeframe bar in real time. These levels are decision support, not buy or sell signals.
**Disclaimer**
This indicator is for educational and informational purposes only and is not financial or investment advice. Past performance does not guarantee future results. Always do your own analysis and manage your own risk.
Indicator

OMSF Learning SpaceWelcome to the Omsf Learning Space.
This is not a commercial "holy grail" indicator, nor is it a rigid, corporate course. This is my personal sandbox and educational archive where I dissect market structure, breakout mechanics, and reversal setups.
THE CORE PHILOSOPHY:
Everything in this space is built upon my Omsf (Objective Market Structure Framework). Whether you are a beginner trying to understand how charts breathe, or an advanced trader looking for mechanical rules – this space is designed to give you a clear, visual reality check.
WHAT TO EXPECT:
This script is dynamic and will change organically over time. As I publish new trading ideas, research notes, or structural concepts, this indicator will adapt. Old parts might get swapped out, new experiments will be added, or it might evolve into a v2.0 down the road. There is no fixed schedule. It updates when it updates.
CURRENT VERSION (Launch):
Right now, we are looking at the foundational mechanics: Classic, rigid Pivots alongside the dynamic volatility adjustment of the Omsf.
- Toggle "Exercise 1" to stress-test both engines in the configuration sandbox.
- Toggle "Outlook" to see how classic Pivots perform when taken literally as a trend filter.
Enjoy the sandbox, play with the parameters, and use the Bar Replay. See you in the ideas section!
— arni Indicator
