Strategy

Indicator

Indicator

Indicator

Indicator

Indicator

CQ_(A)_Larry Williams Vix Fix V4 - Tops & Bottoms + Histogram================================================================================
CQ_(G)_LARRY WILLIAMS VIX FIX V4 - TOPS & BOTTOMS + HISTOGRAM
Pine Script v6 | PulseWire Overlay Indicator
Author: CQuevedo345
Based on open-source work by theehoganator
================================================================================
════════════════════════════════════════════════════════════════════════════════
PART I — WILLIAMS VIX FIX: THEORY & CONCEPTUAL FRAMEWORK
════════════════════════════════════════════════════════════════════════════════
────────────────────────────────────────────────────────────────────────────────
1. ORIGIN AND MOTIVATION
────────────────────────────────────────────────────────────────────────────────
The Williams VIX Fix (WVF) is a synthetic volatility indicator invented by
Larry Williams and published in a 2007 article in Technical Analysis of Stocks
and Commodities magazine. Its central goal was to replicate the informational
content of the CBOE Volatility Index (VIX) using nothing but price data,
making it applicable to any instrument and any timeframe — equities, futures,
forex, crypto, indices — without requiring access to options markets.
The VIX measures the implied volatility of S&P 500 index options, essentially
reflecting the market's collective expectation of near-term price movement.
When fear spikes — during crashes, sharp corrections, or unexpected shocks —
the VIX surges. When markets are calm and complacent, the VIX stays low. This
behavioral pattern makes VIX extremes valuable as contrarian timing signals:
peak fear often coincides with market lows, and peak complacency often precedes
market tops.
Williams's insight was that the same relationship could be approximated using
only the distance between the current price bar and recent price extremes. If a
bar's low has fallen far below recent highs, it reflects the same kind of
compression that produces VIX spikes — panic, forced selling, exhaustion. No
options data required.
────────────────────────────────────────────────────────────────────────────────
2. THE CORE FORMULAS
────────────────────────────────────────────────────────────────────────────────
STANDARD WVF (Bottoms / Fear Detection):
WVF = ( Highest Close over N bars − Current Low )
─────────────────────────────────────────── × 100
Highest Close over N bars
A large WVF value means the current low has fallen far below the highest recent
close. This mimics a VIX spike: the market has dropped sharply relative to
where it recently was, suggesting fear, capitulation, or oversold conditions.
High values are associated with potential market bottoms.
INVERSE WVF (Tops / Greed Detection):
Inverse WVF = ( Current High − Lowest Close over N bars )
─────────────────────────────────────────── × 100
Lowest Close over N bars
A large Inverse WVF value means the current high has extended far above the
lowest recent close. This is the mirror image: the market has run up sharply
relative to where it recently was, suggesting euphoria, extension, or overbought
conditions. High values are associated with potential market tops.
Both formulas are always positive. The Inverse WVF is used internally as a
negative series in the histogram engine so both can be rendered symmetrically
around a shared baseline.
────────────────────────────────────────────────────────────────────────────────
3. SIGNAL THRESHOLDS: WHEN IS A VALUE "ELEVATED"?
────────────────────────────────────────────────────────────────────────────────
A raw WVF number alone is not a signal. It must be evaluated against its own
recent statistical behavior. This indicator uses two independent thresholds,
and a value qualifies as elevated when it exceeds EITHER one:
BOLLINGER BAND UPPER BAND
The WVF series is itself treated as a data series. A Bollinger Band is
computed on the WVF values (not on price): SMA(WVF, bbl) + mult × StdDev.
When the current WVF value exceeds its own upper band, volatility is elevated
relative to its recent average behavior.
PERCENTILE RANGE HIGH
The highest WVF value over a long lookback (lb bars) is found, and a
percentile fraction (ph) is applied: RangeHigh = Highest(WVF, lb) × ph.
This ensures that signals only fire when the WVF reaches a historically
significant level relative to its own recent range. At ph = 0.85, the WVF
must reach 85% of its recent peak to qualify.
When EITHER threshold is breached, the WVF is "True" (active/elevated).
────────────────────────────────────────────────────────────────────────────────
4. THE PRIMARY SIGNAL: "WAS TRUE, NOW FALSE"
────────────────────────────────────────────────────────────────────────────────
Williams's original methodology did not recommend entering on the spike itself.
Extreme readings can persist for multiple bars, and entering during a spike
means buying into ongoing panic (for bottoms) or ongoing euphoria (for tops).
The cleanest signal comes when the elevation RESOLVES — when the WVF drops back
below BOTH thresholds on the bar immediately following an elevated reading.
This "Was True, Now False" condition represents the moment fear (or greed) has
peaked and is beginning to dissipate. Price has typically found at least a
short-term equilibrium, and the statistical anomaly is over. This is the bar
where the opportunity is most cleanly defined.
The indicator renders this as the ◓ (top resolution) and ◒ (bottom resolution)
half-circle glyphs, accompanied by a ➙ arrow — the primary actionable signals.
────────────────────────────────────────────────────────────────────────────────
5. FILTERED AND AGGRESSIVE ENTRIES
────────────────────────────────────────────────────────────────────────────────
Two additional layers of qualification improve signal timing and reduce noise:
FILTERED ENTRY (conservative, higher quality):
All of the following must be true simultaneously:
— WVF was elevated on the prior bar (Was True condition met).
— Price shows directional confirmation: for bottoms, close must be below the
long-term OR medium-term lookback close, confirming a downtrend context. For
tops, close must be above those levels, confirming an uptrend context.
— A price range confirmation: for bottoms, the low must be higher than the
prior low AND the close above the prior high (upRange). For tops, the high
must be lower than the prior high AND the close below the prior low
(downRange).
— A momentum confirmation: for bottoms, close must be greater than the close
N bars ago (str parameter). For tops, close must be less.
AGGRESSIVE ENTRY (permissive, earlier entry):
The WVF resolution requirement is relaxed — the entry fires while the WVF is
still elevated, rather than waiting for it to drop. The directional and
momentum conditions are still required, but the aggressive variant captures
potential entries before the spike has fully resolved. Higher risk, earlier
timing.
────────────────────────────────────────────────────────────────────────────────
6. PRACTICAL INTERPRETATION AND CONTEXT
────────────────────────────────────────────────────────────────────────────────
The Williams VIX Fix is fundamentally a MEAN-REVERSION volatility signal. Its
core assumption is that markets periodically overshoot driven by emotional
extremes — fear at bottoms, greed at tops — and that those extremes are
statistically identifiable and tend to resolve back toward equilibrium.
WHEN IT WORKS WELL:
— Ranging, cyclical, or oscillating markets.
— Higher timeframes (daily, weekly) where volatility spikes are meaningful.
— Instruments with clear boom-and-bust cycles (commodities, small caps, crypto
in trending cycles).
— As a filter layered on top of a directional thesis.
WHEN IT IS LESS RELIABLE:
— Strong, persistent trending markets (a bottom signal in a bear market may
just be a pause before continuation).
— Very low timeframes (1m, 5m) where noise drowns out meaningful signals.
— Instruments with structural volatility regimes that change over time.
The WVF does not predict direction — it identifies statistical extremes. The
trader's job is to determine whether that extreme is a reversal opportunity or
a continuation pause. Combining with trend filters (e.g. moving averages,
market structure) significantly improves reliability.
════════════════════════════════════════════════════════════════════════════════
PART II — INDICATOR MANUAL
════════════════════════════════════════════════════════════════════════════════
────────────────────────────────────────────────────────────────────────────────
7. OVERVIEW
────────────────────────────────────────────────────────────────────────────────
This indicator merges two separate tools into a single Pine Script v6 overlay:
COMPONENT A — TOPS & BOTTOMS LABELS (V4)
Detects potential market tops using the Inverse WVF and market bottoms using
the standard WVF. Signals are rendered as label markers directly on the price
chart — triangles, arrows, and text callouts above or below qualifying bars.
Each signal type has independent display toggles and alert line plots.
COMPONENT B — DUAL-MODE HISTOGRAM
Renders a proportional histogram of both WVF series (lows and highs) as
colored boxes anchored to the price chart. The histogram is configurable in
size, position, orientation, and color, and supports a split mode where the
two series are displayed on opposite sides of the visible price range.
Both components share a common set of core parameters and all outputs
(labels, boxes, lines, alert plots, alert conditions) are active simultaneously.
────────────────────────────────────────────────────────────────────────────────
8. ADDING THE INDICATOR
────────────────────────────────────────────────────────────────────────────────
1. Open PulseWire and navigate to any chart.
2. Open the Pine Script Editor (bottom panel → Pine Editor tab).
3. Paste the full script and click Save, then Add to Chart.
4. The indicator renders directly on the price pane as an overlay.
5. Access all settings via the gear icon next to the indicator name on the
chart, or via the indicator title in the top-left of the pane.
────────────────────────────────────────────────────────────────────────────────
9. INPUT GROUPS AND PARAMETERS
────────────────────────────────────────────────────────────────────────────────
The settings panel is organized into seven groups:
┌─────────────────────────────────────────────────────────────────────────┐
│ GROUP 1: SHARED — Tops and Bottoms Variables │
└─────────────────────────────────────────────────────────────────────────┘
These parameters affect all calculations in both Component A (labels) and
Component B (histogram). Changing any of these alters every signal and every
histogram bar simultaneously.
LookBack Period Standard Deviation Default: 22
The N-bar window used in both WVF formulas. Controls the period over which
the Highest Close (for bottoms WVF) and Lowest Close (for tops WVF) are
computed. Smaller values make the indicator more reactive to recent price
action; larger values smooth out shorter-term fluctuations.
Bollinger Band Length Default: 20
The SMA and standard deviation period applied to the WVF series itself
(not to price). The upper band derived from this setting is one of the two
elevation thresholds.
Bollinger Band Standard Deviation Default: 2.0 (range: 1–5)
The multiplier applied to the standard deviation in the Bollinger Band
calculation. Higher values (e.g. 3.0) raise the threshold, reducing the
frequency of signals but increasing their statistical significance. Lower
values (e.g. 1.5) lower the threshold, producing more frequent but noisier
signals.
Look Back Period Percentile Default: 50
The lookback window used to find the highest WVF value for the percentile
threshold calculation. A 50-bar window means the indicator looks back 50
bars to find the peak WVF, then applies the Highest Percentile fraction.
Highest Percentile Default: 0.85
The fraction of the recent WVF range peak that must be reached to qualify
as elevated. At 0.85, the WVF must hit 85% of its 50-bar high to trigger.
At 0.90, 90% is required (more selective). At 0.99, only near-peak values
qualify (very selective, very rare).
Lowest Percentile Default: 1.01
The inverse multiplier used for the histogram's highs (inverse WVF) series.
Applied to the lowest WVF value in the lookback window. Used internally for
the histogram's upper threshold boundary for the tops series. Values above
1.00 raise the bar; 1.01 requires the highs WVF to reach 101% of its
recent trough (near-exact match to the extreme).
Long-Term LookBack (Filtered) Default: 40 (range: 25–99)
Used in filtered entry criteria. For bottoms, the close must be BELOW the
close 40 bars ago OR below the medium-term lookback to confirm that price
is in a downtrend context. For tops, close must be ABOVE it. Acts as a
trend context filter.
Medium-Term LookBack (Filtered) Default: 14 (range: 10–20)
The shorter of the two lookback comparisons for filtered entries. The OR
condition between this and the Long-Term LookBack means only one needs to
be satisfied — providing some flexibility in trend context detection.
Entry Price Action Strength Default: 3 (range: 1–9)
The momentum lookback. For bottoms, the close must exceed the close N bars
ago. For tops, the close must be below the close N bars ago. Larger values
require more sustained momentum to qualify.
Markers Label Size Default: Large
Size of the primary signal markers (◥ ↘ ◓ ➙ ◢ ↗ ◒). Options: Tiny,
Small, Normal, Large, Huge. Controls only the compact glyph labels.
Notes Label Size Default: Normal
Size of the extended text callouts (Filtered Short/Long, Aggressive
Short/Long with the vertical │ pointer lines). Kept separate from Markers
to allow the text to scale independently.
┌─────────────────────────────────────────────────────────────────────────┐
│ GROUP 2: TOPS — Text Plots Above │
└─────────────────────────────────────────────────────────────────────────┘
Controls which of the four top-signal label types are rendered above bars.
Show Plot: Inverse WVF IS True Default: true
Displays ◥ and ↘ labels above bars where the Inverse WVF is currently
elevated (above either threshold). This is the "active spike" state —
the market is in a statistically elevated top-side reading right now.
Two labels appear per qualifying bar (one triangle glyph, one arrow).
Show Plot: Inverse WVF WAS True, Now False Default: true
Displays ◓ and ➙ labels on the bar immediately after the Inverse WVF
drops back below both thresholds. This is the primary short signal — the
top-side spike has resolved.
Both of these toggles are in the TOPS — Text Plots Above group. The
Filtered and Aggressive toggles are in the TOPS — Filtered Criteria group
(see below).
┌─────────────────────────────────────────────────────────────────────────┐
│ GROUP 3: TOPS — Filtered Criteria │
└─────────────────────────────────────────────────────────────────────────┘
Show Plot: Filtered Short Entry Default: true
Renders the "Filtered Short │││" text callout above bars meeting the full
filtered criteria (WVF resolved + downRange + strength + trend context).
Show Plot: Aggressive Filtered Short Entry Default: true
Renders the "Aggressive Short │││" text callout when aggressive criteria
are met (WVF still elevated + strength + trend context, without waiting
for full resolution).
Long-Term LookBack — Close ABOVE this OR Medium-Term Default: 40
Tops-specific version of the shared long-term lookback. Close must be
above close or close to confirm an uptrend context for the
filtered short signal.
Medium-Term LookBack — Close ABOVE this OR Long-Term Default: 14
Tops-specific medium-term lookback, paired with the long-term above.
Strength — Close < X Bars Back Default: 3
Tops-specific momentum check. Close must be less than close (default),
confirming downward momentum is present on the signal bar.
┌─────────────────────────────────────────────────────────────────────────┐
│ GROUP 4: TOPS — Alerts │
└─────────────────────────────────────────────────────────────────────────┘
Four boolean toggles that control whether numeric alert line plots are
rendered for tops. When enabled, a plot outputs 1 on qualifying bars and 0
otherwise. These plots are used to create PulseWire Alerts (see Section 12).
Alert: Inverse WVF = True Default: false
Plot goes to 1 when the Inverse WVF is currently elevated.
Alert: Inverse WVF Was True, Now False Default: false
Plot goes to 1 on the resolution bar (the primary short signal bar).
Alert: Inverse WVF Filtered Default: false
Plot goes to 1 when the full filtered short criteria are satisfied.
Alert: Inverse WVF Aggressive Filter Default: false
Plot goes to 1 when the aggressive filtered criteria are satisfied.
┌─────────────────────────────────────────────────────────────────────────┐
│ GROUP 5: BOTTOMS — Text Plots Below / Filtered Criteria / Alerts │
└─────────────────────────────────────────────────────────────────────────┘
Mirror image of Groups 2–4 for the standard WVF (bottoms detection).
All logic is identical but applied to the lows series. Labels appear below
bars. Summary of the parameters:
Show Plot: WVF IS True Default: true
◢ and ↗ labels below bars where WVF is currently elevated.
Show Plot: WVF WAS True, Now False Default: true
◒ and ➙ labels on the resolution bar. Primary long signal.
Show Plot: Filtered Long Entry Default: true
"Filtered Long │││" text callout when full criteria are met.
Show Plot: Aggressive Filtered Long Default: true
"Aggressive Long │││" text callout for aggressive criteria.
Long-Term LookBack — Close BELOW this OR Medium-Term Default: 40
For filtered longs, close must be below close or close .
Medium-Term LookBack — Close BELOW this OR Long-Term Default: 14
Paired with the long-term lookback above.
Strength — Close > X Bars Back Default: 3
Close must exceed close (upward momentum) to qualify.
Four alert toggles matching the tops group, for long-side signals.
┌─────────────────────────────────────────────────────────────────────────┐
│ GROUP 6: HISTOGRAM — Display Options │
└─────────────────────────────────────────────────────────────────────────┘
Flip Histogram Upside Down Default: true
When true, the histogram grows downward from the baseline (lows bars hang
below, highs bars hang above in the combined/flipped orientation). When
false, the orientation is inverted. Useful for visual preference or when
using Split mode.
Number of Bars to Show Default: 50 (range: 5–100)
How many of the most recent bars display histogram boxes. Older bars beyond
this count have no boxes drawn. Reducing this value improves performance
and reduces visual clutter on zoomed-out views.
Histogram Height (price units) Default: 300 (range: 200–600, step 25)
The total vertical span of the histogram, expressed in the chart's own
price units. The tallest bar within the visible window always fills this
full height; all other bars are scaled proportionally. Adjust this to match
the price scale of the instrument being analyzed — a stock at $500 needs a
much larger value than a forex pair at 1.08.
Split Histogram: Above highest/Below lowest Price Default: false
When false (combined mode): Both the lows (green) and highs (red) series
share a single baseline, placed below the lowest low of the visible window
at 120% of the barHeight offset. Lows grow upward, highs grow downward from
this shared baseline.
When true (split mode): The two series separate to opposite edges of the
visible price range. The lows series anchors 20% of barHeight below the
lowest low and grows outward from there. The highs series anchors 20% above
the highest high and grows outward. This gives an unobstructed view of both
series without overlap and relates them spatially to price action.
The Flip toggle swaps which series sits above vs. below.
Plot High/Low Range Lines Default: true
When enabled, a thin horizontal line is drawn at the percentile threshold
level for each bar. Orange lines for the lows series (Highest Percentile),
red lines for the highs series (Lowest Percentile). These lines show where
the threshold sits relative to each bar's actual WVF value.
Plot Standard Deviation Band Default: false
When enabled, a thicker line is drawn at the Bollinger Band upper/lower
band level for each bar. Aqua for lows, maroon for highs. Shows the moving
Bollinger threshold relative to the histogram bars.
Green Bars Needed to Trigger Alert Default: 1 (minimum: 1)
Controls the alertcondition() green bar logic. At 1 (default), a green bar
alert fires on the first bar the WVF reaches extreme territory. At 2, two
consecutive extreme bars are required before the alert fires. Useful for
filtering brief, noise-level spikes.
┌─────────────────────────────────────────────────────────────────────────┐
│ GROUP 7: HISTOGRAM — Colors │
└─────────────────────────────────────────────────────────────────────────┘
Eight color pickers controlling the visual appearance of the histogram boxes,
plus two line color pickers for the range and SD band lines.
WVF Lows — Extreme Default: semi-transparent green
Color of lows bars when the WVF is currently elevated (above threshold).
WVF Lows — Normal Default: semi-transparent dark gray
Color of lows bars during non-elevated periods.
WVF Highs — Extreme Default: opaque red
Color of highs bars when the Inverse WVF is currently elevated.
WVF Highs — Normal Default: semi-transparent gray
Color of highs bars during non-elevated periods.
WVF Lows — Reverted Default: semi-transparent gold
Color used for the lows bar on the single bar immediately after the WVF
drops from elevated to normal (the "Was True, Now False" moment). Visually
highlights the resolution event.
WVF Highs — Reverted Default: semi-transparent gold
Same as above, for the highs (Inverse WVF) reversion bar.
Show Reversion (Yellow) Histogram Bars Default: true
Toggle to enable/disable the reversion color. When disabled, reverted bars
display in their normal (non-elevated) color.
Range Line — Lows Default: semi-transparent orange
Color of the percentile threshold line drawn alongside each lows bar.
Range Line — Highs Default: semi-transparent red
Color of the percentile threshold line for the highs series.
SD Band — Lows Default: semi-transparent aqua
Color of the Bollinger Band level line for the lows series.
SD Band — Highs Default: semi-transparent maroon
Color of the Bollinger Band level line for the highs series.
────────────────────────────────────────────────────────────────────────────────
10. SIGNAL REFERENCE TABLE
────────────────────────────────────────────────────────────────────────────────
Signal Location Color Meaning
─────────────────────────────────────────────────────────────────────────
◥ Triangle Above bar Red text Inverse WVF IS True. Tops-side
volatility currently elevated.
↘ Arrow Above bar White on red Inverse WVF IS True. Directional
bias indicator (downward).
◓ Half-circle Above bar Gold on green Inverse WVF WAS True, Now False.
Primary short signal. Spike
resolved, sell-side opportunity.
➙ Arrow Above bar White on green Accompanies ◓. Resolution
confirmed.
Aggressive Above bar Orange text Aggressive Short. Inverse WVF
Short │││ still elevated; early short entry
with momentum/trend confirmation.
Filtered Above bar White text Filtered Short. Full criteria met:
Short │││ resolution + range + momentum +
trend context.
◢ Triangle Below bar Green text WVF IS True. Bottoms-side
volatility currently elevated.
↗ Arrow Below bar White on green WVF IS True. Directional bias
indicator (upward).
◒ Half-circle Below bar Gold on red WVF WAS True, Now False. Primary
long signal. Spike resolved,
buy-side opportunity.
➙ Arrow Below bar White on red Accompanies ◒. Resolution
confirmed.
│││ Below bar Orange text Aggressive Long. Early long entry
Aggressive while WVF still elevated.
Long
│││ Below bar White text Filtered Long. Full criteria met
Filtered for conservative long entry.
Long
────────────────────────────────────────────────────────────────────────────────
11. HISTOGRAM VISUAL GUIDE
────────────────────────────────────────────────────────────────────────────────
COMBINED MODE (bSplit = false, bFlip = true — defaults):
A single horizontal baseline is anchored below the lowest low of the
visible window. Green (lows) bars grow downward from this baseline, and
red (highs) bars grow upward from the same baseline. The tallest bar in
either series fills the full barHeight; all others are proportionally
scaled.
SPLIT MODE (bSplit = true):
The lows (green) series separates below price action, anchored 20% of
barHeight below the lowest low. The highs (red) series separates above
price action, anchored 20% of barHeight above the highest high. Each
series grows away from the price center — lows downward, highs upward
(or swapped if bFlip is true). This mode is ideal when you want the
histogram to frame the price action symmetrically.
BAR STATES:
Gray (low opacity): WVF value is within normal statistical range.
Green (extreme): WVF has exceeded the elevation threshold — lows spike.
Red (extreme): Inverse WVF has exceeded its threshold — highs spike.
Gold/Yellow: The bar immediately after an elevated reading drops back to
normal — the reversion bar, visually identical to the primary signal.
RANGE LINES:
Thin horizontal lines at the percentile threshold level (orange = lows,
red = highs). When a histogram bar exceeds its range line, it will be
colored in the extreme color.
SD BAND LINES:
Thicker lines at the Bollinger Band level (aqua = lows, maroon = highs).
When a bar exceeds this line, it also qualifies as elevated.
────────────────────────────────────────────────────────────────────────────────
12. SETTING UP ALERTS
────────────────────────────────────────────────────────────────────────────────
This indicator supports two types of alerts:
TYPE A — LABEL ALERT PLOTS (Tops & Bottoms, 8 plots):
These output 1 on qualifying bars and 0 otherwise. To use them:
1. Enable one or more Alert toggles in the TOPS — Alerts or BOTTOMS —
Alerts groups (e.g. "Alert: Inverse WVF Was True, Now False").
2. Open PulseWire's Alerts panel (the clock icon or Alt+A).
3. Click Create Alert and select this indicator.
4. Choose the relevant plot (e.g. "Alert: Top Now False").
5. Set condition to "Crossing" or "Greater Than 0".
6. Configure notification method (email, push, webhook) and click Create.
Note: These plots are invisible on the chart by default. They output at
the price scale and are not intended as visual elements.
TYPE B — HISTOGRAM ALERTCONDITION (Green Bar Logic, 2 conditions):
These fire based on the histogram's bColorBars state (extreme readings).
They appear in the Alerts panel automatically without any toggle needed.
1. Open Alerts panel → Create Alert → select this indicator.
2. Choose "Williams Green Bar (LOWS)" or "Williams Green Bar (HIGHS)".
3. The alert fires when N consecutive extreme bars appear (where N is
set by "Green Bars Needed to Trigger Alert" in the Histogram group).
INVISIBLE HISTOGRAM ALERT PLOTS (8 additional plots):
Eight invisible plots (Hist Alert 1–4 Lows and 1–4 Highs) are also
available in the Alerts panel for more granular histogram-based alert
conditions. These correspond to the four filtered/aggressive stages for
each direction.
────────────────────────────────────────────────────────────────────────────────
13. RECOMMENDED SETTINGS BY USE CASE
────────────────────────────────────────────────────────────────────────────────
SWING TRADING (Daily / Weekly Charts)
Core parameters: pd=22, bbl=20, mult=2.0, lb=50, ph=0.85
Label signals: Enable WAS True, Now False only; disable IS True.
Histogram: Split mode on; 30–50 bars; height adjusted to chart.
Entry filter: Enable Filtered signals; disable Aggressive.
Alert: Alert: WVF Was True, Now False (both directions).
Note: On daily charts, one confirmed resolution bar per week or month is
a rich signal. Be patient and wait for the full resolution.
INTRADAY (15m / 1H Charts)
Core parameters: pd=14, bbl=14, mult=2.0, lb=30, ph=0.90
Label signals: Enable both IS True and WAS True, Now False.
Histogram: Combined mode; 20–30 bars; reduce height.
Entry filter: Enable Aggressive for faster reaction.
Alert: Green Bar alert at threshold 1 for instant reaction.
Note: Signal frequency increases sharply. Apply a trend filter separately
(e.g. compare to a 200 EMA on the same chart) to avoid counter-trend trades.
MEAN REVERSION / RANGE TRADING
Core parameters: pd=22, bbl=20, mult=1.5, lb=50, ph=0.80
Label signals: All four signal types enabled.
Histogram: Split mode for clear visual separation.
Entry filter: Enable both Filtered and Aggressive.
Note: Lower mult and ph makes signals more frequent. Suitable for range-
bound instruments where any WVF spike is likely to revert.
TREND FOLLOWING (using WVF as a pullback entry tool)
Core parameters: pd=22, bbl=20, mult=2.5, lb=50, ph=0.90
Label signals: Only WAS True, Now False; only Filtered entries.
Direction bias: Only trade Bottoms signals in an established
uptrend; only Tops signals in a downtrend.
Histogram: Use as a visual confirmation tool.
Note: In a strong uptrend, WVF Bottoms signals (fear spikes on pullbacks)
are often the best entries. Ignore all Tops signals in an uptrend.
────────────────────────────────────────────────────────────────────────────────
14. TECHNICAL ARCHITECTURE NOTES
────────────────────────────────────────────────────────────────────────────────
DUAL CALCULATION TRACKS:
The indicator maintains two separate calculation tracks for the WVF:
— inv_wvf / wvf: the label-driving track, used for all 12 label signals
and 8 alert line plots. These use ph as the sole percentile parameter.
— wvf_lows / wvf_highs: the histogram-driving track, identical in formula
to the above but using both ph and pl for separate high/low thresholds.
wvf_highs is a negative series (inverted sign convention) enabling
symmetric rendering around a shared baseline.
This separation ensures the label signals remain independent of the
histogram's additional pl parameter.
ARRAY-BASED DRAW ENGINE:
The histogram does not draw on every bar. Instead, 13 rolling arrays collect
values on every bar and are trimmed to nBars entries. On barstate.islast
(the final bar), a single loop draws all boxes and lines at once. This
approach ensures: (a) no ghost history bars, (b) a flat, stable baseline,
and (c) normalization against only the visible window's max value.
PINE SCRIPT LIMITS:
max_boxes_count = 500: at nBars=50 with 2 boxes per bar, 100 boxes are
used at any time. Well within the limit.
max_lines_count = 500: with hp=true and sd=false, 2 lines per bar = 100
lines. With sd=true, 4 lines per bar = 200 lines. Still within limits.
Labels are not bounded by a max_labels_count declaration, but PulseWire
limits labels to 500 per indicator. With many signals enabled, this limit
may be reached on charts with long histories.
NON-REPAINTING:
All historical WVF calculations use ta.highest() and ta.lowest() on closed
bar data. These do not repaint. The "IS True" label condition is based on
the current bar's WVF value, which is provisional until bar close — treat
IS True labels on the real-time bar as unconfirmed until the bar closes.
────────────────────────────────────────────────────────────────────────────────
15. KNOWN LIMITATIONS
────────────────────────────────────────────────────────────────────────────────
— No built-in stop loss or target: the indicator identifies volatility
extremes and potential reversal zones. It does not compute or display price
targets, stop levels, or position sizing. These must be determined by the
trader independently.
— Histogram height is instrument-dependent: barHeight is expressed in price
units. A value of 300 works well for a $300 stock but is far too small for
Bitcoin at $60,000 or far too large for a forex pair. Adjust barHeight to
roughly 5–15% of the instrument's current price level as a starting point.
— Label accumulation on long-history charts: if all label types are enabled
and the chart spans many years on a high-frequency timeframe, PulseWire's
500-label limit may be reached and older labels will be silently dropped.
Disable unused label types to conserve the label budget.
— Split mode positioning: in split mode, the baseline is computed from the
highest high and lowest low within the visible nBars window. Panning or
zooming the chart does not automatically recompute until a new real-time
tick arrives. The histogram will update on the next price movement.
— Histogram on instruments with very low prices (below $5): barHeight has a
minimum of 200, which may cause the histogram to extend far beyond the
visible chart area for very low-priced instruments. In this case, reduce
barHeight by editing the input constraints directly in the script.
================================================================================
© CQuevedo345 — Pine Script v6 — PulseWire
Based on original work by theehoganator and Larry Williams
================================================================================ Indicator

Indicator

Indicator

Indicator

Indicator

Indicator

Indicator

Dual EMA ZloiVOVERVIEW
Dual EMA ZloiV is a trend‑following indicator based on two exponential moving averages that color both the EMAs and the ribbon between them according to the current market direction. It is designed as a clean trend filter that quickly highlights bullish, bearish, and neutral phases without additional oscillators or visual noise.
FEATURES
Two customizable EMAs (fast and slow) with separate length and color settings for uptrend and downtrend, so you can adapt the tool to any market or timeframe.
Dynamic color change of each EMA depending on its slope and relative position, making trend shifts visually obvious on the chart.
Optional ribbon between the EMAs that reflects the overall trend direction (bullish/bearish/neutral) and helps you see momentum transitions at a glance.
Minimalistic design focused purely on trend visualization, so you can use it as a universal building block on top of your own strategies, entries and exits.
HOW TO USE
Use Dual EMA ZloiV as your primary trend filter: trade in the direction of the ribbon and EMA colors, and avoid or size down trades that go against the current trend.
Shorter EMA lengths work better for scalping and intraday trading, while longer lengths are more suitable for swing and positional setups.
Combine the indicator with your preferred entry tools (RSI, Stoch RSI, price action patterns, volume, etc.): Dual EMA ZloiV defines the direction, and other tools fine‑tune entries and exits.
LIMITATIONS
This script does not generate trade signals or execute orders; it only visualizes trend conditions based on two EMAs.
In choppy or low‑volatility markets the EMAs can frequently change color, so consider adding a separate trend/volatility filter (e.g., ADX, ATR, volume) in your system to reduce whipsaws. Indicator

Macro Market Health IndexThis comprehensive indicator, Macro Market Health and Dynamic Regime Scoring, is a multi-asset "Risk-ON / Risk-OFF" framework designed to quantify market health by analyzing six specialized macro pillars. Unlike static indicators, this tool features an adaptive weighting engine that calibrates the importance of each macro block based on its real-time relationship with the specific asset currently on your chart
.
The Six Pillars of Market Health
The indicator processes raw data through six "Blocks," each utilizing specific mathematical models to score health from 0 to 1
:
Risk Block (Sentiment): Monitors the VIX (normalized against a baseline of 22), Gold, and the USD/JPY "Carry Trade"
. It calculates a blend of absolute levels (distance from the 200-day EMA) and momentum (9-day ROC of the 21-day EMA) to detect capital flight into safe havens
.
Breadth Block (Internal Strength): Uses the S5FI (S&P 500 stocks above their 50-day EMA) and the SPX/RSP Spread
. If the standard S&P 500 is significantly outperforming the equal-weighted version, it signals poor "under the hood" participation
.
Equity Block (Momentum & Volume): Analyzes the S&P 500 using a Gaussian "Sweet Spot" model
. It scores the trend highest when the price is in a healthy range above the 200-day EMA, while also penalizing the score if relative volume trends (21-day vs 251-day EMA) show exhaustion
.
Crypto Block (Risk Appetite): Serves as a high-beta proxy by measuring Bitcoin's distance from its 50, 100, and 200-day EMAs
. These are weighted (45% for 50-day, 32% for 100-day, 23% for 200-day) to capture multi-timeframe risk sentiment
.
Growth Block (Economic Context): Tracks Crude Oil and its 50-day correlation to equities
. It identifies whether energy prices are acting as a growth driver or a risk-off inflationary headwind
.
Credit Block (Fixed Income): Monitors the HYG (High Yield Corporate Bonds) as a leading indicator of credit stress
. It evaluates both the trend level and the rate of change in corporate bond demand
.
Advanced Mathematical Components
To ensure all data is comparable, the script employs several core math engines:
Sigmoid Normalization: Squashes all outputs into a standard 0 to 1 range for easy comparison
.
Z-Score Sigmoids: Normalizes volatility and momentum by measuring how many standard deviations a value is from its mean
.
Gaussian Probability: Uses a bell-curve distribution to score the "Equity Block," rewarding trends that stay within a specific volatility-adjusted distance from the mean
.
Distance/ATR Scaling: All price distances from moving averages are divided by the ATR (Average True Range) to ensure the scores are relative to current market volatility
.
Data-Driven Weighting: Tailored to YOUR Asset
The standout feature is the Weight Engine, which rejects the "one-size-fits-all" approach. It calculates weights against the specific ticker (hlc3) on your chart
:
Asset Correlation: The indicator measures the real-time statistical correlation between each macro block and the specific stock you are trading
. If your stock starts moving in lockstep with Credit or Crypto, those blocks are automatically given more weight
.
Dynamic Volatility Scaling: It calculates the ratio of a block's volatility (CV) to your stock's volatility (CV) to dynamically adjust the lookback period (between 50 and 300 bars)
Adaptive Lookback Engine: The index uses the Coefficient of Variation (CV) (StandardDeviation/Mean) to compare macro environment volatility against your stock's volatility
. This ratio automatically scales the lookback window between 50 bars (for high-volatility responsiveness) and 300 bars (for stable trend smoothing)
.
Weighting & Analytics: Final weights blend asset-specific correlation with Inverse Volatility (1/SD) to prioritize correlated, stable, low-noise signals
.
Signals and Predictive Analytics
Trade Status Overlay: Provides a definitive "TRADE" (Score > 0.58) or "NO TRADE" (Score < 0.45) signal
.
Regime Classification: Categorizes the market into BULL MARKET, EARLY BULL, NEUTRAL, or RISK OFF
.
Swing Probability: Uses a Gaussian Survival Model to estimate the conditional probability that a "Risk-ON" or "Risk-Off" (current identified) regime will last for a user-defined "Swing Duration" (e.g., the next 21 bars)
.
Reliability Index: Based on the number of historical samples collected for that specific asset, it labels the probability data as Adequate, Marginal, or Low
. Indicator

Indicator

Aquila Reale Macro Dashboard PRO v1.7🦅 AQUILA REALE — MACRO DASHBOARD PRO
"Born to fly, born to dare"
A complete macro overview in a single table, with automatic interpretation of each asset's impact on Gold price and a final ACTIONABLE trade signal that resolves conflicts intelligently between macro tailwinds and price-action reality.
═══════════════════════════════════════════
📊 WHAT IT SHOWS
═══════════════════════════════════════════
For each of 12 macro assets, the dashboard displays:
- Current value (live intraday)
- Daily change %
- Auto-interpreted status (e.g. "VERY STRONG", "HIGH FEAR", "STAGFLATIONARY")
- 🥇 Gold impact (green = pro-Gold, red = anti-Gold, gray = neutral)
═══════════════════════════════════════════
📋 ASSETS COVERED (12 + 2 derived)
═══════════════════════════════════════════
US MACRO:
- DXY (Dollar Index)
- US10Y / US20Y / US30Y (Treasury yields)
- USIRYY (CPI Inflation YoY)
- S5TH (S&P 500 stocks above 200dma — market breadth)
ASIA:
- USDJPY (Yen strength)
- NI225 (Nikkei 225)
- HSI (Hang Seng Index)
SENTIMENT:
- VIX (CBOE Volatility Index — fear gauge)
GLOBAL:
- URTH (iShares MSCI World ETF)
GEOPOLITICAL:
- USDCNH (Offshore Chinese Yuan)
COMMODITIES:
- XAUUSD (Gold spot)
- USOIL (WTI Crude Oil spot)
DERIVED:
- Gold/Oil ratio (with historical valuation reading)
- Macro Scenario (synthesis of WTI level + Gold direction + yields)
═══════════════════════════════════════════
🎯 FINAL SYNTHESIS (3 dedicated rows)
═══════════════════════════════════════════
💬 SCENARIO — One of 6 macro readings:
• STAGFLATIONARY (yield squeeze, no Gold longs)
• GOLD HEDGE ACTIVE (inflation trade pro-Gold)
• RISK-OFF (cautious flight-to-safety)
• REFLATIONARY (broad pro-Gold)
• RISK-ON (anti-Gold)
• MIXED (no clear regime)
💎 MACRO BIAS — Aggregate score (±13) across all assets
🎯 TRADE SIGNAL — Final actionable verdict combining BIAS + SCENARIO:
• 🚀 LONG STRONG / ▲ LONG OK
• ⚠️ LONG CAUTIOUS
• ⏸️ WAIT (yield squeeze / mixed signals)
• 🛑 NO LONG / STAY OUT / SHORT BIAS
═══════════════════════════════════════════
🧠 KEY LOGIC INNOVATION
═══════════════════════════════════════════
Equity indices (NKY/HSI/URTH) only count as pro-Gold when VIX > 22 (true flight-to-safety). This prevents the dashboard from misreading a "bonds beat all" regime as pro-Gold — a common flaw in naive aggregations.
The TRADE SIGNAL row resolves the inevitable conflicts between macro bias (what "should" happen) and price action (what's actually happening), using a priority hierarchy where the SCENARIO has veto power over the BIAS score.
═══════════════════════════════════════════
📺 3 VIEW MODES
═══════════════════════════════════════════
- FULL: complete 19-row dashboard
- MINIMAL: only the 3 synthesis rows (SCENARIO + BIAS + SIGNAL)
- COMPACT: only the TRADE SIGNAL (1-line ticker)
Switch on-the-fly via settings — all modes use the same underlying calculations.
═══════════════════════════════════════════
⚙️ CUSTOMIZATION
═══════════════════════════════════════════
- Dark / Light theme
- 9 anchor positions + signed offsets (H/V)
- 4 text sizes (Tiny / Small / Normal / Large)
- Real-time refresh (lookahead_on for intraday)
═══════════════════════════════════════════
⚠️ IMPORTANT DISCLAIMER
═══════════════════════════════════════════
This indicator is for informational and educational purposes only and does not constitute financial advice. Macro readings are simplified models — always combine with your own analysis, risk management, and price action.
NOT suitable for backtesting strategies due to lookahead_on usage (which is intentional for real-time intraday monitoring).
Past performance does not guarantee future results.
═══════════════════════════════════════════
🦅 Born to fly, born to dare. Indicator

BB RSI Scalping + Trend Mode Auto-Switch# BB RSI Scalping + Trend Mode Auto-Switch
## Overview
This is a **multi-mode scalping indicator** for PulseWire that combines Bollinger Bands mean reversion with intelligent trend detection. It automatically switches between two trading modes based on market conditions.
---
## Two Trading Modes
### 1. BB Mean Reversion Mode (Default when ranging)
- **Best for:** Ranging or choppy markets
- **Strategy:** Fade extremes—buy near the lower Bollinger Band, sell near the upper band
- **Entry Types:**
- **Reversal** — Counter-trend trades at band extremes with RSI/MACD/volume confirmation
- **Continuation** — Trades that continue toward the middle band (basis)
- **Exit Logic:** Based on momentum (MACD histogram inflection, MACD crosses, RSI 50 cross)
### 2. Trend Following Mode (When strong trend detected)
- **Best for:** Trending markets with clear direction
- **Strategy:** Trade with momentum on pullbacks during established trends
- **Entry Trigger:** ADX above threshold (default: 20) with +DI/-DI confirming direction
- **Exit Logic:** Exits when trend weakens (ADX drops 5+ from entry) or reverses
---
## Key Features
| Feature | Description |
|---------|-------------|
| **Auto Mode Switching** | Automatically detects trend vs. ranging and switches strategies |
| **Trend Detection** | Uses ADX + DI (Directional Index) to identify trend strength & direction |
| **Entry Modes** | Conservative (all confirmations), Balanced, or Aggressive |
| **Continuation Trading** | Midline Bollinger Band continuation trades when momentum aligns |
| **Dynamic Exits** | Stop levels that trail and adjust with price action |
| **Visual Labels** | Entry, HOLD, EXIT SOON, and warning labels on chart |
| **Mode Display Table** | Shows current mode, ADX level, trend direction, and strength |
| **Trade History** | Tracks recent trades with entry/exit prices, P&L, and results |
| **Webhook Alerts** | Sends JSON alerts for Google Sheets integration |
---
## How the Mode Display Table Works
The table in the **upper left corner** shows at a glance what's happening:
| Row | What It Shows | Example |
|-----|---------------|---------|
| **MODE** | Current strategy | `TREND FOLLOWING` or `BB MEAN REVERSION` |
| **ADX** | Trend strength (0-100) | `28.5` (color-coded: green ≥30, yellow 20-30, red <20) |
| **TREND** | Direction | `↑ BULL`, `↓ BEAR`, or `— RANGE` |
| **STRENGTH** | Classification | `STRONG`, `MODERATE`, or `WEAK/NONE` |
---
## Decision Flow
```
ADX < 20 (Weak/None)
↓
BB MEAN REVERSION MODE
- Buy at lower band
- Sell at upper band
- Exit on momentum
ADX > 20 (Trending)
↓
TREND FOLLOWING MODE
- Buy pullbacks in uptrend
- Sell rallies in downtrend
- Exit when trend weakens
```
---
## Entry Signal Types
| Label | Meaning |
|-------|---------|
| `REVERSAL` | Counter-trend trade at Bollinger Band extremes |
| `CONTINUATION` | Trade along the middle band with momentum |
| `TREND LONG/SHORT` | Pullback entry during established trend |
---
## Visual Elements on Chart
| Element | Description |
|---------|-------------|
| **BUY/SELL Labels** | Entry points with price, invalidation, and dynamic exit levels |
| **HOLD Labels** | Shows current target, stop, and any warnings |
| **EXIT SOON Labels** | Alerts when momentum is weakening |
| **TREND LONG/SHORT NEAR** | Warnings when trend setup is building |
| **Dotted Lines** | Dynamic exit levels, trailing stops, break-even |
| **Solid Lines** | Entry price, Bollinger Bands |
---
## Use Cases
| Market Condition | Mode Active | What to Watch For |
|------------------|-------------|-------------------|
| Ranging/Sideways | BB MEAN REVERSION | Reversal trades at bands, continuation trades at midline |
| Strong Uptrend | TREND FOLLOWING | Pullback entries to buy, exit when ADX drops |
| Strong Downtrend | TREND FOLLOWING | Rally entries to short, exit when trend reverses |
| Choppy/Weak | BB MEAN REVERSION | Conservative entries with all confirmations |
---
## Customization Options
- **Entry Mode:** Conservative, Balanced, or Aggressive
- **ADX Threshold:** When to switch to trend mode (default: 20)
- **Strong Trend Level:** When to consider trend "strong" (default: 30)
- **Trailing/Break-Even Stops:** ATR-based management
- **Take Profit Levels:** Multiple TP levels with partial exits
- **Session Filter:** Trade only during certain hours
- **Max Holding Time:** Auto-exit after X minutes Indicator

Indicator

Indicator

IANI Liquidity M/W ScalperEnglish description
IANI Liquidity M/W Scalper is a price-action scalping indicator designed mainly for low-timeframe execution, especially M1 and M5.
The indicator combines:
liquidity levels: PDH / PDL / PWH / PWL
higher-timeframe support and resistance
local trendline breakout structure
M / W reversal patterns
breakout + pullback / retest logic
optional EMA 50 / EMA 200, hidden by default
The goal is to help identify:
where liquidity is located
where important reaction zones are
where price may reverse or continue
where local breakout structure appears
where a pullback entry may form
How to use — English
1. Start with the main map
First, watch the main liquidity levels:
PDH = Previous Day High
PDL = Previous Day Low
PWH = Previous Week High
PWL = Previous Week Low
These are liquidity areas. Price may move toward them to take liquidity, trigger stops, or react.
2. Use higher-timeframe support and resistance
Support and resistance are calculated from higher timeframes, such as H1.
Basic idea:
near support, look for BUY setups
near resistance, look for SELL setups
after a breakout, watch the next level as a possible target
Do not enter only because price touches a line. Wait for reaction, structure, rejection, or retest.
3. Use the trendline for scalp structure
The trendline is for local scalp structure.
By default, it uses Chart TF:
on M1, it draws trendlines from M1 pivots
on M5, it draws trendlines from M5 pivots
Usage:
green line below price = local bullish structure
break below it = possible SELL watch
red line above price = local bearish structure
break above it = possible BUY watch
4. Use M / W patterns for confirmation
M/W patterns help with reversal setups:
W near support / PDL / liquidity zone = possible BUY
M near resistance / PDH / liquidity zone = possible SELL
The most useful labels are:
BUY PB / W Retest
SELL PB / M Retest
This means the pattern had a breakout and then a pullback/retest.
5. Safer entry workflow
Do not enter every label blindly.
Better process:
1. Price reaches an important area: PDH / PDL / S/R / weekly level
2. Price reacts
3. M or W structure forms
4. Local structure or trendline breaks
5. Wait for pullback / retest
6. Enter with a small SL behind structure
Recommended settings for M1 scalping
Show EMA 50 / EMA 200 = OFF
Show Liquidity Zones = ON
Show Previous Day High / Low = ON
Show Previous Week High / Low = ON
Show Daily Swings = OFF
Show Weekly Swings = OFF
S/R Source TF = 60
Visible S/R Above = 3 or 4
Visible S/R Below = 3 or 4
Trendline Source TF = Chart
Trendline Swing Mode = Major
Show TL Break Labels = OFF
Show M/W Retest Entry Labels = ON
Important
This is not a blind buy/sell system.
Use it with market structure, liquidity, session timing, risk management, and confirmation from price action. Indicator

Indicator

Directional Flow Signals
Directional Flow Signals is a DMI-based trend direction indicator designed to highlight shifts in directional pressure directly on the price chart.
The indicator uses the Directional Movement Index system, comparing DI+ and DI- to determine which side of the market is currently dominant.
When DI+ is above DI-, candles are colored bullish.
When DI- is above DI+, candles are colored bearish.
A Long signal appears when directional control shifts from bearish to bullish.
A Short signal appears when directional control shifts from bullish to bearish.
This allows traders to quickly visualize changes in directional bias without needing to keep a separate DMI/ADX panel open.
Key features:
- Bullish and bearish candle coloring
- Long and Short signal labels
- DI+ / DI- crossover-based trend shifts
- Built-in alert conditions
- Adjustable DMI length and smoothing
- Custom candle colors
This tool can be useful for identifying directional transitions, trend bias changes, and possible momentum shifts when combined with support/resistance, volume, VWAP, market structure, or higher timeframe confirmation.
Important:
This indicator does not predict price movement and should not be used as a standalone trading system. Since the signals are based on DI+ and DI- crossovers, they may produce false signals during sideways or low-volatility market conditions.
Inputs:
Show BUY/SELL Signals:
Allows users to enable or disable Long and Short labels on the chart.
ADX Length:
Controls the lookback period used for the Directional Movement Index calculation.
ADX Smoothing:
Controls the smoothing applied to the ADX/DMI calculation.
Up Candle Color:
Sets the candle color when DI+ is stronger than DI-.
Down Candle Color:
Sets the candle color when DI- is stronger than DI+.
Directional Flow Signals is a visual trend-bias indicator based on the Directional Movement Index.
The script compares DI+ and DI- to determine whether bullish or bearish directional pressure is dominant. Candles are colored according to the active directional bias, and signal labels are displayed when the dominant side changes.
Signal logic:
Long Signal:
A Long signal is generated when DI+ becomes stronger than DI- after previously being below it.
Short Signal:
A Short signal is generated when DI- becomes stronger than DI+ after previously being below DI+.
The goal of this indicator is not to predict reversals, but to provide a clear visual representation of directional pressure shifts.
It is best used as a confirmation layer together with price structure, volume, VWAP, support/resistance, or higher timeframe trend analysis.
Limitations:
- Signals are based only on DI+ and DI- dominance.
- The ADX value is calculated but not used as a strength filter.
- False signals may occur in ranging or choppy markets.
- The indicator does not provide stop loss, take profit, or risk management levels.
- It should be used as a confirmation or visual bias tool, not as a complete trading system.
Indicator
