Index Peak Dispersion█ OVERVIEW
Index Peak Dispersion plots, in a separate pane, two normalized series computed across a configurable universe of up to twelve equity indexes: the calendar-day dispersion of their all-time-high dates, expressed as a percent of a topping window, and the share of indexes that printed a fresh all-time high within a short recent window. The thesis is that healthy advances register all-time highs across indexes nearly simultaneously, while major distributive tops fragment, spreading index peak dates across weeks or months.
█ HISTORY / BACKGROUND
The concept descends from the non-confirmation principle of Dow Theory as developed by Charles Dow, William Hamilton and Robert Rhea, in which a new high in one average unaccompanied by a new high in another warns that the trend is losing sponsorship. Classic non-confirmation is measured in the price domain: one index fails to exceed its prior peak while another does.
Market historians and technicians, including Robert Prechter, have documented a related phenomenon in the time domain: at major tops, the final all-time highs of the major indexes scatter across the calendar rather than clustering. At the 2000 top, the Dow Industrials peaked in January, the S&P 500 and NASDAQ Composite in March, and the NYSE Composite in September. At the 2007 top, the Dow Jones Composite peaked in July while the Dow Industrials and S&P 500 peaked in October. This script converts that qualitative observation into a mechanical, reproducible statistic.
█ HOW IT WORKS
The script performs the following steps on each bar:
• For each of up to twelve enabled symbols, one same-timeframe request.security() call evaluates a function inside the requested symbol's context. The function maintains a running maximum of closing prices over the symbol's loaded history and records the timestamp of the bar on which that maximum was last exceeded. This running maximum is point-in-time by construction: no future data enters the calculation, and lookahead is off.
• On the chart symbol, each recorded timestamp is converted to an age in calendar days: current bar time minus the all-time-high time, divided by the number of milliseconds in a day.
• Each enabled index with data is classified. An age at or below the fresh window makes it Fresh. An age at or below the topping window makes it part of the in-window set. An age beyond the topping window makes it Stale.
• When the in-window set contains at least the minimum required count of indexes, the dispersion span equals the maximum in-window age minus the minimum in-window age, in calendar days. The plotted dispersion value is that span divided by the topping window length, times 100. When the in-window count is below the minimum, the dispersion plot returns na.
• The participation value equals the count of Fresh indexes divided by the count of enabled indexes with data, times 100, plotted as columns.
• The fractured top condition is true when the dispersion value is at or above the warning threshold while at least one index is Fresh. The pane background is shaded on those bars, and an alert fires on the first bar of each new occurrence. A second alert fires when every enabled index with data is simultaneously Fresh, which marks a synchronized advance, the opposite condition.
• On the last bar, an optional table lists each index with its all-time-high date, age in days and classification, plus summary counts and the raw span in days.
█ HOW TO USE
The script is designed for the 1D timeframe. The running all-time high is intended to operate on daily closes, and both windows are specified in calendar days, so daily resolution matches the granularity of the logic.
In plain terms, the blue columns answer one question: how many of the enabled indexes hit a record high this week? The red line answers another: how spread out in time are everyone's record highs? In a strong market, the indexes peak together, so the columns are tall and the line stays low. At major tops, the market tends to fall apart in slow motion: one index peaks, then months later another, and by the time the last index prints its final record, several others stopped making records long ago. Each new high is carried by fewer indexes, so the columns thin out while the line climbs. The shaded background marks the combination of both: the market is still printing record highs, but the set of indexes confirming them has been shrinking for months. That is the structure documented at the 2000 and 2007 tops. The same combination also appears during rotation phases that resolve higher, so treat it as a statement that conditions resemble past major tops, not as an instruction to act.
Read the two plotted series together. Low dispersion with high participation describes a synchronized advance in which the enabled indexes are registering highs together. Rising dispersion while some indexes continue to print fresh highs describes fragmentation: leadership is narrowing and earlier leaders have stopped confirming. The shaded background marks bars on which the dispersion value is at or above the dashed threshold line while at least one fresh high exists, the specific combination in which fragmentation is present at a live high rather than in an established downtrend.
The table gives the attribution behind the numbers: which indexes are Fresh, which remain inside the topping window, and which have gone Stale, along with each all-time-high date. Stale entries are non-confirmations older than the topping window and are deliberately excluded from the span so that a single long-dormant index does not saturate the statistic.
The condition is a warning context, not a timing trigger. It identifies an environment consistent with historical distributive tops. It does not predict the date or the existence of a decline.
█ SETTINGS
• Index universe, twelve slots, each with an enable checkbox and a symbol field. Defaults: DJI, DJT, DJU, DJA, SPX, NDX, IXIC, NYA, RUT, SOX, MID, SPXEW. All twelve are enabled by default. Any slot can be repointed to another symbol or disabled.
• Fresh high window, calendar days. Default 7. An index whose all-time high printed within this many days counts as Fresh.
• Topping window, calendar days. Default 378. An index whose all-time high printed within this many days participates in the dispersion span. Older highs are classified Stale.
• Dispersion warning threshold, percent of topping window. Default 25. The dashed reference line and the threshold for the fractured top condition.
• Minimum in-window index count for a valid span. Default 4. Below this count the dispersion plot returns na, which prevents a span computed from too few indexes.
• Show status table. Default on.
• Table position. Default Top right.
█ WHAT MAKES IT ORIGINAL
Breadth and non-confirmation tools on this platform generally measure the price domain: divergences between an index and an internal line, counts of components above a moving average, or new-high and new-low tallies within one exchange universe. This script instead measures the time domain across whole indexes. It reduces the peak-date scatter of a user-defined index universe to a single bounded statistic, the in-window span of all-time-high ages, and pairs it with a participation series so that fragmentation is only flagged while a high is live. The classification into Fresh, in-window and Stale, with the Stale exclusion and the minimum-count validity gate, is what allows the scatter of a historical topping process to be plotted as one continuous, comparable series across eras.
█ NOTES / LIMITATIONS
• The running all-time high is computed only over the bars loaded for each requested symbol. Symbols with short available history, and the early portion of any chart, understate the true age of the all-time high. Treat the plot as reliable only after all enabled symbols have substantial loaded history.
• The logic is designed for the 1D timeframe. On intraday charts the running maximum operates on intraday closes and the calendar-day windows lose their intended granularity. On weekly or monthly charts a fresh window shorter than one bar cannot register.
• All request.security() calls run on the chart timeframe with lookahead off. Values on the developing bar update until the bar closes and do not repaint afterward.
• The script issues twelve security calls. A symbol slot that fails to resolve or returns no data is excluded from every count and appears in the table as No data.
• Ages and spans are measured in calendar days, not trading days, so weekends and holidays are included in the counts.
• The warning threshold is expressed as a percent of the topping window. Changing the topping window changes the day-equivalent of the same percent threshold.
• The dispersion plot returns na whenever fewer than the minimum required indexes have an all-time high inside the topping window.
• The status table renders on the last bar only. อินดิเคเตอร์

ATR PulseATR Pulse is an ATR-based trend and signal indicator designed to identify transitions around a dynamic volatility-adjusted trailing stop.
The script combines one core ATR transition engine with optional validation filters. These filters are not separate trading systems merged together; they act as configurable confirmation layers around the same underlying price-versus-trailing-stop event. This allows users to keep the indicator simple or make signal requirements more selective without changing the core concept.
**How it works**
The indicator calculates Average True Range over the selected ATR Period and multiplies it by the ATR Sensitivity setting.
This produces a dynamic loss distance:
ATR distance = ATR x Sensitivity
The trailing stop then adjusts according to the relationship between the current price, the previous price, and the previous trailing-stop value.
When price remains above the trailing stop, the stop follows upward without moving lower.
When price remains below the trailing stop, the stop follows downward without moving higher.
A directional transition is detected when price crosses the ATR trailing stop:
* A bullish signal requires price to cross above the trailing stop.
* A bearish signal requires price to cross below the trailing stop.
The indicator uses standard chart prices and does not request data from another symbol or timeframe.
**ATR Sensitivity**
ATR Sensitivity controls how closely the trailing stop follows price.
Lower values create a tighter stop that reacts to smaller price movements.
Higher values create a wider stop that requires a larger price movement before a directional transition occurs.
ATR Period controls the lookback used to calculate market volatility.
**Optional EMA trend filter**
When enabled:
* Bullish signals require price to be above the selected EMA.
* Bearish signals require price to be below the selected EMA.
The purpose of this filter is to restrict ATR transitions to the selected broader price direction.
**Optional ADX / DMI filter**
When enabled, the indicator requires both directional strength and directional agreement.
For bullish signals:
* ADX must be at or above the selected minimum.
* +DI must be greater than -DI.
For bearish signals:
* ADX must be at or above the selected minimum.
* -DI must be greater than +DI.
DI Length, ADX Smoothing, and Minimum ADX are independently adjustable.
**Optional RSI filter**
The RSI filter provides an additional directional condition.
When enabled:
* Bullish signals require RSI above the selected RSI Direction Level.
* Bearish signals require RSI below that level.
The default center level is 50, but both the RSI length and directional level can be changed.
**Optional volume filter**
When enabled, current volume must be at least the selected multiple of its moving average.
For example, a setting of 1.5 requires current volume to be at least 1.5 times the selected average-volume reference.
If usable volume data is not available for the symbol, the volume condition is bypassed rather than preventing all signals. Volume therefore should be interpreted according to the quality of volume data provided for the selected market.
**Optional candle-quality filter**
This filter evaluates the signal candle itself.
When enabled:
* A bullish signal requires a bullish candle.
* A bearish signal requires a bearish candle.
* The candle body must represent at least the selected percentage of the candle's full high-to-low range.
This can be used to exclude transition candles with relatively small bodies and large wicks.
**Signal cooldown**
The Minimum bars between signals setting can be used to reduce closely spaced signals.
A value of 0 disables the cooldown.
Higher values require the specified number of bars to pass before another signal can be accepted.
**Candle-close confirmation**
Confirm signals on candle close is enabled by default.
When enabled, Buy and Sell signals are accepted only after the current candle is confirmed closed.
When disabled, signal conditions can become true while the realtime candle is still developing. In that mode, a signal may appear or disappear before the candle closes as price changes.
**Visual controls**
The indicator can display:
* Buy and Sell labels.
* The ATR trailing stop.
* The trend EMA.
* A bullish or bearish background.
* An information dashboard.
Most supplementary visuals are optional so users can keep the chart clean and display only the elements relevant to their analysis.
The dashboard can show the current trend state together with ATR, ADX, RSI, sensitivity, and current filter readiness.
**Alerts**
Two alert conditions are included:
* ATR Pulse Buy
* ATR Pulse Sell
These alerts use the same final signal conditions as the chart labels, including any optional filters that the user has enabled.
Users should configure the indicator settings before creating an alert so the alert reflects the intended configuration.
**Pine Screener support**
ATR Pulse can also be used with TradingView's Pine Screener.
The script includes dedicated Buy and Sell alert conditions that can be used as screening filters, allowing users to scan a watchlist for symbols currently meeting the ATR Pulse bullish or bearish conditions.
This can be particularly useful when the same ATR Pulse settings need to be evaluated across multiple symbols instead of checking charts individually.
Pine Screener has its own platform limitations and calculation scope, so screening results should be interpreted within the data and timeframe processed by the Screener.
**Example workflow**
A user who wants the basic ATR transition behavior can leave all optional filters disabled.
A more selective configuration can enable one or more of the following:
* EMA trend alignment.
* ADX / DI directional strength.
* RSI direction.
* Volume expansion.
* Candle quality.
* Signal cooldown.
Each enabled filter becomes an additional requirement for the same underlying ATR transition signal.
There is no single recommended combination for every symbol or timeframe. Settings should be selected according to the market, timeframe, and type of analysis being performed.
**Repainting and realtime behavior**
ATR Pulse does not use future data or lookahead calculations.
With Confirm signals on candle close enabled, signal confirmation occurs only on closed candles.
The ATR trailing stop itself continues to update as new market data arrives.
If candle-close confirmation is disabled, conditions on the realtime candle can change before that candle closes. This is normal realtime behavior and should not be interpreted as a confirmed historical signal until the bar is complete.
Changing indicator settings, symbol, timeframe, or available chart history causes TradingView to recalculate the indicator.
**Limitations**
ATR Pulse is sensitive to volatility and parameter selection.
A tight ATR Sensitivity may produce more frequent transitions in sideways markets, while a wider setting can respond more slowly to directional changes.
Optional filters can reduce the number of signals, but they can also delay or exclude transitions that would otherwise qualify under the core ATR logic.
ADX, RSI, EMA, volume, and candle-quality conditions describe different aspects of current market behavior. Their inclusion does not guarantee that a subsequent price move will continue in the signal direction.
Signals are descriptive outputs of the selected rules, not forecasts of future price movement.
ATR Pulse is an indicator, not a strategy. It does not place orders, provide performance statistics, or claim a particular win rate. It is intended as a configurable technical-analysis and screening tool to help users identify and evaluate ATR-based directional transitions.
อินดิเคเตอร์

All-Markets Movement Extremes ToolA causal all-markets movement tool for identifying retained terminal PEAK/TROUGH extremes and exposing the earliest available confirmation of those extrema after the required price structure develops.
Name:
All-Markets Movement Extremes Tool
Searchable Name:
All-Markets Movement Extremes Tool
Technical Name:
All-Markets Non-Repainting Terminal-to-Causal Directional Movement Extremes Tool
Short title:
Movement Extremes
Summary
All-Markets Movement Extremes Tool identifies terminal peaks and troughs within developing directional movement and preserves the causal confirmation that makes each retained extreme available.
The central difficulty is that a completed extreme and the generated signal capable of establishing that extreme are not necessarily available at the same time.
A trough can already exist before enough upward structure has developed to confirm that the downward movement terminated there.
A peak can already exist before enough downward structure has developed to confirm that the upward movement terminated there.
Price can therefore move meaningfully away from the terminal before the corresponding confirmation becomes available.
The tool is built around that separation.
During an active directional leg, the current extreme remains provisional and can be replaced by a newer same-side high or low.
Once the required opposite structure confirms, the retained extreme becomes:
TROUGH for the completed low of the prior downward movement
PEAK for the completed high of the prior upward movement
The terminal marker remains attached to the retained movement extreme.
The causal confirmation remains attached to the later bar where that extreme became confirmable.
This keeps two important references visible at the same time:
where the directional movement terminated
and
where the corresponding confirmation became available
The confirmed PEAK/TROUGH stream can therefore provide context for directional-movement trading, filtering, confirmation, and broader trading decisions, while the stream itself represents confirmed movement extremes and their causal availability rather than a complete standalone buy/sell signal.
The result is a directional-movement tool that provides:
movement direction and transition context
terminal peak/trough identification
directional-movement trading context
confirmation and filtering context
entry/exit context
movement-cycle review
and comparison of completed movement with what became causally available
Terminal extremes
The script follows an active directional leg and retains its strongest extreme.
During an upward leg, the highest retained high remains the potential terminal PEAK.
During a downward leg, the lowest retained low remains the potential terminal TROUGH.
A newer same-side extreme can replace the previous candidate while that directional movement remains active.
The extreme becomes confirmed only after the required opposite structure develops.
This prevents a temporary move away from a high or low from automatically being treated as the completed terminal.
Causal confirmation
Every confirmed terminal has two important locations.
Terminal
The retained PEAK or TROUGH belonging to the completed directional movement.
Causal confirmation
The later confirmed-bar event where enough completed structure exists to establish that terminal.
The terminal shows where the completed movement ended.
The causal confirmation shows when the script could establish that terminal through its forward process.
Those two points can be close together or separated by several bars.
The optional Causal Confirmation Comparison makes that difference visible directly on the chart.
Earliest available confirmation
The tool attempts to expose a retained terminal on the first confirmed transition that satisfies its active structural requirements.
That does not move the historical terminal forward.
The PEAK or TROUGH remains attached to the completed movement extreme, while the causal marker remains attached to the later confirmation event.
This is what allows the tool to preserve both the final movement location and its actual causal availability.
Directional movement
The PEAK/TROUGH sequence forms a continuing directional structure.
A confirmed TROUGH establishes the completed low of the preceding downward movement.
A confirmed PEAK establishes the completed high of the preceding upward movement.
Consecutive opposite terminals describe the completed movement between retained extrema.
The tool can display those relationships with HOLD paths and directional backgrounds so the broader directional movement remains visible rather than reducing the chart to isolated labels.
Directional-movement trading context
The confirmed extremes and their causal transitions provide directional-movement context that can be examined alongside confirmation rules, filtering, entry/exit context, or other market-state methods.
The value of the output is the movement structure it establishes:
terminal extreme → causal confirmation → directional movement context
That structure remains available for broader trading-related evaluation without changing what the PEAK/TROUGH stream itself represents.
Movement cycles
Consecutive opposite confirmed extrema form completed directional cycles.
The tool keeps two reference systems available.
Terminal-to-terminal
The completed movement between retained extrema.
Confirmation-to-confirmation
The corresponding directional movement between the causal confirmation points.
These measurements can differ substantially because part of the terminal movement can occur before confirmation becomes available.
Last capture / confirm gap
The Movement Cycle page shows Last capture / confirm gap for the most recent completed cycle.
The capture value compares the latest completed terminal-to-terminal directional result with the corresponding confirmation-to-confirmation result when the terminal movement is positive.
The confirm gap shows the difference between those two completed-cycle results.
Together, they provide a compact comparison between the retained movement extremes and the corresponding causal confirmation references.
Unconfirmed context
Not every developing extreme becomes the retained terminal.
An earlier high can be superseded by a higher high.
An earlier low can be superseded by a lower low.
When enabled, the tool can expose this context separately from the confirmed PEAK/TROUGH sequence.
The optional Minimum Reversal Filter can also reject structural transitions that do not meet the selected movement requirement.
Current movement
For the latest confirmed extreme, the tool can compare:
terminal price
confirmation close
current price
terminal-to-confirm move
price change from confirmation to current
directional move from confirmation to current
best move after confirmation
and bars since confirmation
This provides a current directional reference after the extreme has been established.
Status pages
The tool includes four compact status pages:
Summary
Movement Cycle
Timing
Guide
Summary provides the broad state of confirmed extrema and completed movement cycles.
Movement Cycle focuses on the latest terminal, its confirmation, current movement, and the previous completed cycle.
Timing focuses on terminal-to-confirmation separation and structural timing.
Guide provides a compact interpretation of the active PEAK/TROUGH framework.
Alerts
Optional alerts are available for confirmed PEAK and TROUGH events.
The alert occurs when the causal confirmation becomes available.
The terminal remains attached to the retained movement extreme, while the alert reflects the later confirmation event.
This preserves the difference between terminal location and causal availability.
Features
all-markets directional movement framework
retained terminal PEAK identification
retained terminal TROUGH identification
causal confirmed-bar operation
terminal-versus-confirmation separation
Causal Confirmation Comparison
Confirmed Hold Path
Confirmed Hold Background
movement-cycle tracking
terminal-to-current directional movement
confirm-to-current directional movement
best move after confirm
Last capture / confirm gap
Unconfirmed Extreme Context
Minimum Reversal Filter
compact Summary, Movement Cycle, Timing, and Guide pages
confirmed PEAK/TROUGH alerts
Strengths
Terminal Extreme Preservation — the completed PEAK/TROUGH remains anchored to the retained movement endpoint.
Causal Availability — the corresponding confirmation remains separately visible where it actually became available.
Directional Context — the output describes continuing directional movement rather than isolated bar labels.
All-Markets Use — the framework can be applied across different markets because it is based on directional price structure.
Early Causal Exposure — the tool attempts to establish the retained terminal on the first qualifying confirmed transition.
Terminal-versus-Causal Comparison — completed movement and causally available movement remain directly comparable.
Broader Trading Context — the confirmed extrema provide directional, confirmation, filtering, and entry/exit context while retaining their underlying movement-extreme meaning.
Weaknesses
Confirmation Delay — the terminal can exist before enough opposite structure develops to confirm it.
Movement Before Confirmation — part of the next directional movement can occur before the causal confirmation becomes available.
Superseded Extremes — developing terminal candidates can be replaced by newer same-side extremes.
Standalone Trade Outcome Variability — confirmed PEAK/TROUGH extremes can remain structurally reliable movement references while the result of directly trading every confirmation as its own buy/sell action can vary substantially across market conditions.
Structural Dependence — confirmation timing depends on the selected structural requirements.
No Complete Trade Management — position sizing, risk management, stop placement, profit targets, and wider trade-management logic are separate from the movement-extreme output.
Who it’s for
This tool is suited for users interested in:
terminal market peaks and troughs
directional movement trading
movement-transition confirmation
structural filtering
entry/exit context
causal versus completed movement
terminal-to-terminal cycles
confirmation timing
Last capture / confirm gap
and incorporating confirmed extrema into broader trading methods
It is especially relevant when the question is not only:
“Where did the movement terminate?”
but also:
“When did that terminal become causally available?”
Known limitations
The final retained extreme cannot be confirmed until enough opposite structure has developed.
Some movement can therefore occur before confirmation.
Some developing terminal candidates can be superseded.
Some confirmation-to-confirmation cycles can be non-positive.
The distinction between the terminal and the causal confirmation is therefore explicitly preserved as part of the tool's output.
Final note
All-Markets Movement Extremes Tool identifies retained terminal PEAK/TROUGH extremes and exposes the causal confirmation of those extrema.
The terminal remains attached to the completed movement extreme.
The causal confirmation remains attached to the point where the required structure becomes available.
The relationship between those two references provides directional movement context for confirmation, filtering, cycle comparison, and broader trading-related evaluation. อินดิเคเตอร์

Edo Equal Highs/LowsEdo Equal Highs/Lows — Detects Equal Highs and Equal Lows as Resting Liquidity and Flags When Price Takes It
When two swing highs form at the same level, or two swing lows, they create one of the clearest forms of resting liquidity in price action. Traders place their stops just beyond a double top or double bottom, and breakout orders cluster there too — so that matched level becomes a pool of liquidity that price is frequently drawn to take. In the Smart Money Concepts approach these are equal highs (EQH), holding buy-side liquidity above price, and equal lows (EQL), holding sell-side liquidity below it.
Edo Equal Highs/Lows maps these levels automatically and tracks what happens to them. It marks each EQH and EQL when two swings match within an ATR-based tolerance, extends the level as resting liquidity, and flags the exact moment price closes through it and takes that liquidity — all validated on closed bars so the indicator does not repaint. It is the equal-levels specialist of the Edolab structure family, designed to work alongside liquidity sweep and liquidity zone analysis.
EQUAL HIGHS AND EQUAL LOWS
The indicator compares each new swing pivot with the previous one of the same type. When two consecutive swing highs sit at the same price within the tolerance, it draws an Equal Highs (EQH) level — buy-side liquidity resting above. When two swing lows match, it draws an Equal Lows (EQL) level — sell-side liquidity resting below. The level is drawn from the earlier matching pivot and labelled EQH or EQL, extending to the right as a live reference.
THE ATR TOLERANCE
What counts as "equal" is not a single tick but a configurable band. The Equal Tolerance input is expressed as a fraction of ATR (0.10 by default): two swings are treated as equal when their difference is within that fraction of the average true range. A lower value is stricter — only near-perfect matches qualify; a higher value is looser, catching approximate double tops and bottoms. Tying the tolerance to ATR keeps it adaptive across instruments and timeframes, so the same setting behaves consistently whether the chart is a low-volatility index or a fast-moving crypto.
SWING PROFILES
The swings compared for equality come from pivots whose sensitivity is set by the Swing Profile: Scalper (5 bars each side) for short-term levels on low timeframes, Swing (10 bars, the default) for the balanced 4H and daily read, and Long Term (21 bars) for the major levels on weekly and higher horizons.
ACTIVE AND TAKEN
Each equal level lives in one of two states, evaluated on every closed bar. Active: the level is intact, holding its resting liquidity, drawn as a solid coloured line extending to the right — red for EQH, teal for EQL by default. Taken: price has closed through the level and swept the liquidity — the line turns dashed and faded grey and the label gains a ✕. An EQH is taken when price closes above it; an EQL, when price closes below it. Only Active levels count in the panel, since a taken level has already done its job. To keep the chart clean, only the most recent levels per side are kept, up to Max EQ Levels per side (10 by default).
INFORMATION PANEL
The panel condenses the read into a compact table: the number of active EQH and active EQL levels, and the nearest unswept level on each side — the closest Equal Highs above the current price and the closest Equal Lows below it, with their exact prices. Those nearest levels are the most immediate liquidity targets above and below, the quickest way to see where price may be drawn next. The panel sits in any of the four chart corners (Top Right by default), comes in three sizes (Tiny / Small / Normal) and two themes (Dark / Light), and can be hidden entirely.
NO REPAINTING
Equal levels are built on confirmed pivots and their taken state is validated on closed bars, so a level never appears or disappears intrabar. A wick that pierces an equal level but closes back on the same side does not mark it as taken — the indicator waits for the close. There are no higher-timeframe functions: all logic runs on the current chart timeframe.
CONFIGURATION
The inputs are grouped by block. Detection sets the swing profile, the equal tolerance in ATR and the maximum number of levels kept per side. Style exposes the equal highs and equal lows colours, the taken colour, the label size and the Dark/Light theme. Panel controls panel visibility, position and size. The defaults are calibrated to work without adjustment on stocks, crypto, forex, indices and futures, on any timeframe — the inputs most users touch are the Swing Profile and the Equal Tolerance, to set how strict the matching should be.
ALERTS
Four predefined alerts cover the life of an equal level: Equal Highs formed and Equal Lows formed fire when a new EQH or EQL level is drawn; Equal Highs taken and Equal Lows taken fire when price closes through a level and sweeps its liquidity. The formed alerts flag fresh liquidity targets, and the taken alerts fire exactly when that liquidity is swept — often the trigger for a reaction. All alerts fire on bar close, consistent with the indicator's anti-repaint validation.
HOW TO READ IT
Equal highs and lows are liquidity targets, not entries: price is often drawn toward an EQH above or an EQL below to take the stops resting there, so the nearest levels in the panel point to where the move may head next. Watch the take: when price closes through an equal level and it turns Taken, the liquidity has been swept — that sweep frequently precedes a reaction, and classifying it as confirmed or faded turns the event into a fuller read. Trade levels in confluence: an EQL that sits on a demand zone or a higher-timeframe support is a stronger reference than an isolated one. And set inside broader liquidity zones, the equal levels mark precise liquidity pools, completing the liquidity map.
OPEN SOURCE
Edo Equal Highs/Lows is published as a free open source indicator. The full Pine Script is publicly accessible on TradingView for study, adaptation and integration into any workflow. Part of the Edolab Markets free tools ecosystem, with more structure, liquidity and order-flow indicators available on TradingView.
This indicator is a technical analysis tool for educational and informational purposes only. It does not generate automatic buy or sell signals and should not be considered financial advice. Trading financial markets involves significant risk of capital loss. Past performance does not guarantee future results. Always use proper risk management.
อินดิเคเตอร์

QuantLine Auction State EngineQuantLine Auction State Engine asks one question: what is price doing with the
edge of its prior range?
Many breakout tools mark the first trade above a rolling high or below a rolling
low. That does not distinguish a wick from acceptance, and the rolling level can
move while the event is still being judged. This script separates the process
into explicit states and locks the point-in-time range when a test begins.
States
- BAL — price remains in balance inside the prior range.
- CMP — balance with low ATR percentile: potential energy, no direction.
- T↑ / T↓ — price is testing beyond a locked range edge; acceptance is not yet confirmed.
- A↑ / A↓ — the required closes remain outside the edge and the move passes the selected efficiency and relative-volume checks.
- FA↑ / FA↓ — price returns inside after an attempted auction beyond the edge.
- RT↑ / RT↓ — the first retest holds on the accepted side of the locked edge.
How it is calculated
1. The reference range is the highest high and lowest low of prior bars. The
current bar is excluded.
2. When a close moves beyond an edge by the selected ATR distance, both edges
are locked. They cannot slide while the test is active.
3. Acceptance requires a user-selected number of closes beyond the locked edge.
4. Kaufman-style efficiency ratio separates directional travel from a noisy
path. Optional relative volume checks whether participation is above its
recent average.
5. ATR percentile identifies compression. It does not predict the direction of
the next expansion.
6. A return inside the edge marks a failed auction. After acceptance, the first
touch that closes on the accepted side marks a held retest.
State transitions and alerts occur on confirmed bars. No future bars are used,
and the active range is locked at the time of the test.
How to use it
The tool is a market-structure classifier. It can help a trader distinguish
between “price traded beyond a level” and “price was accepted beyond a level.”
It does not provide an entry, stop, target, position size, probability, or
profitability claim.
All defaults are round research hypotheses and are user-adjustable. Market
quality, fees, slippage and higher-timeframe context remain outside this script.
Educational context only. Not financial advice. อินดิเคเตอร์

Smart Money Structure & Dynamic Equilibrium Suite [ICT Pro]Smart Money Structure & Dynamic Equilibrium Suite
Overview & Purpose
Smart Money Structure & Dynamic Equilibrium Suite is an advanced, high-precision technical analysis visual tool engineered for Pine Script v6. Designed specifically for modern Price Action, Smart Money Concepts (SMC), and Inner Circle Trader (ICT) analysts, this script provides clean visual overlays for key liquidity boundaries, trend momentum, and range midpoints without cluttering chart aesthetics.
Instead of displaying unnecessary lines or repainting historical indicators, this suite focuses purely on real-time structural clarity, dynamic range evaluation, and institutional volume tracking.
Key Features & Technical Components
1. Auto-Swept Previous Day High & Low (PDH / PDL)
- Institutional Liquidity Levels: Automatically tracks and plots the Previous Day High (PDH) and Previous Day Low (PDL) as horizontal daily boundaries.
- Dynamic Disappear / Swept Logic: Once price crosses or sweeps a daily liquidity level during an active trading session, the swept level automatically vanishes from the chart. This ensures your view remains clean and focused only on active, unmitigated daily liquidity targets.
- Full Visual Customization: Adjust line colors, text colors, line thickness, and stroke style (Solid, Dashed, or Dotted) directly from the inputs menu.
2. Connected Dynamic Equilibrium Range
- 50% Midpoint Calculation: Continuously calculates the real-time 50% Equilibrium price zone based on customizable local swing lookback periods.
- Connected Line Extension: Features an extended horizontal line that connects seamlessly to the "EQUILIBRIUM" text label on the right margin, eliminating visual gaps or confusion about range boundaries.
3. Smart Volume Spike & Trend Candle Glow Engine
- Directional Candle Glow: Color-codes chart candles based on dual Moving Average alignments—Neon Green during bullish momentum and Neon Red during bearish momentum.
- Golden Volume Spike Highlighting: Dynamically overlays high-volume institutional candles in a distinct Glowing Gold color whenever current bar volume exceeds customizable moving average multipliers. This makes it effortless to spot institutional expansion bars.
4. Major Intermediate Term Swing Badges (ITH / ITL)
- Structural Pivot Badges: Automatically flags confirmed major high and low points using clear ITH (Intermediate Term High) and ITL (Intermediate Term Low) badges.
- Customizable Sensitivity: Adjust the pivot lookback sensitivity to tailor the detector for scalp, intraday, or higher-timeframe swing trading.
Full Inputs & Parameter Configuration Guide
1. Moving Average & Ribbon Controls
- Show MAs: Enables or disables the visibility of the two core Moving Averages on the chart.
- MA Type: Choose between EMA (Exponential), SMA (Simple), or WMA (Weighted) calculation methods.
- Fast MA Length: Defines the lookback period for the fast directional moving average (Default: 9).
- Slow MA Length: Defines the lookback period for the baseline moving average (Default: 21).
- MA Line Thickness: Adjusts stroke width for both moving averages (1 to 4 pixels).
- Show MA Ribbon Glow: Toggles the background color fill between the Fast and Slow MAs on or off.
2. Smart Candle Glow Settings
- Enable Trend Candle Coloring: Toggles custom candle coloring based on MA trend direction.
- Highlight Volume Spikes: Turns on or off the special Golden Candle overlay for high-volume bars.
- Volume Spike Threshold: Set the volume multiplier relative to the 20-period volume average (Default: 1.8x).
3. Equilibrium Settings
- Show Equilibrium Level: Turns the 50% range midpoint line on or off.
- Equilibrium Lookback Period: Sets the number of historical bars evaluated to compute the local range midpoint.
- Line Style & Thickness: Customize whether the line appears Solid, Dashed, or Dotted, as well as its thickness and color.
4. Daily Liquidity Settings (PDH / PDL)
- Show PDH & PDL: Toggles display of Previous Day High and Low levels.
- PDH/PDL Line Style & Thickness: Select custom visual preferences for daily boundaries.
- Color Pickers: Separate line and text color options for both High and Low daily levels.
Step-by-Step Guide: How to Use This Tool Effectively
Step 1: Determine Structural Bias
Use the Trend Ribbon Cloud and candle coloring to establish current market bias. Green candles and ribbons indicate bullish control, while Red candles signify bearish dominance.
Step 2: Monitor Daily Liquidity Targets
Observe active PDH and PDL lines as primary liquidity pools. When a line disappears from your chart, it confirms that liquidity at that level has been swept by price.
Step 3: Evaluate Value Zones
Refer to the Equilibrium step-line to determine whether current price trades above 50% (Premium territory) or below 50% (Discount territory) relative to recent market swings.
Step 4: Identify Institutional Volume Expansion
Pay close attention to Glowing Gold candles. Volume spikes often coincide with smart money entries, order block mitigations, or explosive range breakouts.
Trading Disclaimer & Risk Warning (House Rules Compliance)
Educational Disclaimer:
This script is strictly a visual analysis and charting utility designed for technical educational purposes. It does NOT offer financial advice, trade signals, investment recommendations, or automated buy/sell algorithms.
Risk Acknowledgment:
Financial trading carries inherent risk, and historical market behavior depicted by visual indicators does not guarantee future results. Users are fully responsible for their own trading decisions and risk management strategies. อินดิเคเตอร์

FRFFlat Range Finder (FRF)
FRF is a high-performance analysis tool developed to detect consolidation (sideways movement) zones in the market.
About FRF Drawing
Purpose and Usage:
The primary purpose of the FRF drawing is to objectively identify zones where the price is compressed within a channel without forming a significant trend over a certain period. This channel allows you to visualize the "uncertain" or "rest" phase of the market.
Update Mechanism:
The FRF drawing periodically scans within the "Min FRF Search Length" and "MAX FRF Search Length" range defined by the system. At each new bar close, the most appropriate channel length is recalculated using the "Channel Fixed R" coefficient. If a stronger consolidation structure forms in the current data, the channel automatically updates itself to adapt to this new data.
Fibonacci & Risk/Reward Box
This feature helps you determine entry, target, and stop-loss levels by using the boundaries of the detected channel.
Why and How to Use It?
Why: In moments of market uncertainty, it provides a disciplined Risk/Reward management based on the channel's own internal dynamics (statistical deviations) rather than arbitrary levels.
How: Activate the box by selecting "Long" or "Short" from the "Position Mode" setting. The box uses the 0.236 Fibonacci ratio as the entry level. The badges on the box dynamically display the current Open P&L status and the Risk/Reward Ratio at the end of the channel.
⚠️ WARNING: THE FIBONACCI & RISK BOX IS AUTOMATICALLY RECALCULATED UPON EVERY NEW CHANNEL DETECTION OR CHANGE IN PRICE DATA. PREVIOUS BOXES AND LABELS ARE DELETED AND REDRAWN ACCORDING TO THE MOST CURRENT CHANNEL DATA. TO AVOID LOSING YOUR PREVIOUS TRADE ANALYSES, ENSURE YOU ARE TRACKING THE LATEST BOX DATA.
Technical Specifications of the Indicator
FRF is equipped with the following capabilities within the classic TradingView library:
MTF (Multi-Timeframe) Support: The indicator can process data from a different timeframe regardless of the current timeframe. You can select your desired TF by activating the Enable MTF option.
Dynamic Channel Fixed R Analysis: This is a statistical metric used to determine the strength of the consolidation. You can optimize how "flat" the channel should be using the Target Threshold <= this setting.
Breakout Alerts: When the upper or lower boundaries of the channel are broken by the body of a candle, the indicator triggers the alert() function to send you a notification.
Advanced Visualizations:
Debug Table: You can view the statistical data of the channel in real-time in the corner of your screen.
Channel Customization: You can fully adjust the channel line style, transparency, and fill colors according to your personal chart preferences.
Midline: You can display the middle baseline within the channel, allowing you to distinguish more clearly which half of the channel the price is dominant in.
Debugging: You can toggle the labels on the bars to understand the indicator's operational logic by using the Show Debug Label option.
This indicator is not a prediction tool, but a data-driven channel detection engine. อินดิเคเตอร์

DUAL Relative Strength Index (Settings: 14 14 28)RSI with Dual Smoothing MA
A modified version of TradingView's built-in RSI indicator with a second RSI-based moving average added.
The standard RSI includes a single smoothing MA. This version adds a second, fully independent one — so you can run a fast MA alongside a slow MA and compare the RSI's short-term movement against its longer-term trend in the same pane.
Features
Two separate RSI-based MAs, each with its own type and length (SMA, EMA, SMMA/RMA, WMA, VWMA)
Independent color selection for each line
Either MA can be switched off entirely by setting its type to "None"
Optional Bollinger Bands on the first MA (as in the original)
Regular bullish/bearish divergence detection and alerts (as in the original)
Settings
RSI Settings: RSI length, source, divergence calculation
Smoothing: first MA — defaults to 14 SMA, yellow
Smoothing 2: second MA — defaults to 28 SMA, orange
Ways to use it
The fast MA crossing above the slow MA can be read as strengthening momentum; crossing below, as weakening
Both MAs sitting on the same side of the 50 level can serve as directional confirmation
The distance between the two lines gives a sense of how quickly momentum is shifting
This indicator does not generate standalone buy or sell signals. It is intended as a confirmation tool within your own system, and settings should be tested against the symbol and timeframe you trade.
Based on TradingView's open-source built-in "Relative Strength Index" indicator.
İngilizce:
Ways to use it
The fast MA crossing above the slow MA can be read as strengthening momentum; crossing below, as weakening
Crossovers that occur in the extreme zones (below 30 / above 70) tend to be more meaningful than those in the middle range (roughly 40–60), where the RSI often moves sideways and the MAs cross back and forth, producing noise
Both MAs sitting on the same side of the 50 level can serve as directional confirmation
The distance between the two lines gives a sense of how quickly momentum is shifting อินดิเคเตอร์

อินดิเคเตอร์

Professional Volume Delta & CVD SuiteEnglish Version
Professional Volume Delta & CVD Suite
Professional Volume Delta & CVD Suite is an all-in-one order flow and volume analysis indicator engineered to deliver institutional-grade market context across any timeframe. By combining Intrabar Volume Delta estimation, Cumulative Volume Delta (CVD), Order Flow Divergences, Volume Climax detection, and a dynamic Real-Time Data Table, this script condenses multiple advanced trading tools into a single, clean workspace.
Key Features & Internal Mechanics
Dual Volume Delta Calculation Engine:
Wick-Based Estimation (Recommended): Evaluates intrabar price action by analyzing high, low, and close prices (volume * (close - low) / (high - low)) to accurately distribute buying and selling volume within each candle.
Color-Based Alternative: Calculates net volume based strictly on candle close vs. open.
Automated Multi-Timeframe Adaptation (Auto-Adjust):
Intraday Mode (1m - 1H): Calculates a Session CVD that resets to 0 at the start of each trading day (00:00 UTC), ideal for tracking day-trading order flow absorption. Divergence lookback is set to 5 bars, Volume MA to 20 periods, and Climax Multiplier to 2.0x.
Daily & Weekly Mode (1D, 1W, 1M): Automatically switches to a Continuous Accumulated CVD (no daily reset) to track multi-week accumulation/distribution cycles. Sets the volume Moving Average to 21 periods (1 trading month) and divergence lookback to 10 bars for high-conviction swing signals.
In-Bar Buyer/Seller Percentage Labels:
Plots exact percentages of buying (%C) and selling (%V) pressure on each individual volume bar.
Fully customizable display: show both percentages, only the winning side, adjust font sizes, toggle % symbols, and control vertical offset distance.
Algorithmic Price vs. Delta Divergence Detection:
Bullish Divergence (Green Arrow): Triggers below the volume histogram when price marks a lower low but Volume Delta forms a higher low (indicates institutional supply absorption).
Bearish Divergence (Red Arrow): Triggers above the volume histogram when price marks a higher high but Volume Delta forms a lower high (indicates demand exhaustion/distribution).
Volume Climax & Trend Filters:
Volume Moving Average (MA): Smoothed volume baseline (default 21 periods for daily charts).
Volume Climax Highlights: Highlights exceptional volume spikes in bright gold when total volume exceeds the moving average by the configured multiplier (e.g., 1.8x or 2.0x), signaling heavy institutional positioning or potential exhaustion.
Dynamic Real-Time Information Table:
Candle Status: Live indicator (Bullish 🟢 / Bearish 🔴).
% Buyer / % Seller: Exact percentage breakdown for the current open candle.
Candle Delta: Net delta percentage of the active bar.
Session CVD / Accumulated CVD: Shows continuous capital flow adapted to the current timeframe.
Volume Activity: Displays current volume activity relative to the MA percentage or alerts CLIMAX ⚡.
Inputs & Customization Settings
Timeframe Configuration: Toggle auto-adaptation or manually enforce Intraday / Daily modes.
Calculations & Display: Choose calculation methods, toggle label modes, change text sizes, and adjust label offsets.
Divergences & MA Filters: Customize MA period, divergence lookback window (bars), and climax thresholds.
Table & Aesthetics: Full control over UI table placement (9 anchor points), table size, row visibility, and custom color palettes for buyers, sellers, climax bars, and divergence shapes.
Versión en Español
Professional Volume Delta & CVD Suite
Professional Volume Delta & CVD Suite es un indicador de análisis de flujo de órdenes (order flow) y volumen todo-en-uno, diseñado para proporcionar contexto de nivel institucional en cualquier marco temporal. Al combinar la estimación de Delta por vela, el Delta Acumulado (CVD), Divergencias de Order Flow, detección de Clímax de Volumen y una Tabla de Datos en Tiempo Real, este script sintetiza múltiples herramientas avanzadas en un único panel limpio y eficiente.
Características Principales y Mecánica Interna
Motor Doble de Cálculo de Volumen Delta:
Estimación por Mechas (Recomendado): Evalúa la acción del precio dentro de la vela analizando máximos, mínimos y cierres (volumen * (cierre - mínimo) / (máximo - mínimo)) para distribuir de manera precisa el volumen comprador y vendedor.
Alternativa por Color de Vela: Calcula el volumen neto basándose estrictamente en el cierre vs. la apertura.
Adaptación Automática según Temporalidad (Auto-Adjust):
Modo Intradía (1m - 1H): Calcula un CVD de Sesión que se reinicia a 0 al inicio de cada jornada (00:00 UTC), ideal para medir la absorción en el day trading. Configura la evaluación de divergencias en 5 velas, la Media Móvil en 20 períodos y el Clímax en 2.0x.
Modo Diario y Semanal (1D, 1W, 1M): Cambia automáticamente a un CVD Acumulado Continuo (sin reseteo diario) para medir ciclos de acumulación y distribución de mediano/largo plazo. Ajusta la Media Móvil de volumen a 21 ruedas (1 mes bursátil) y la evaluación de divergencias a 10 velas para señales swing de alta probabilidad.
Etiquetas de Porcentaje Comprador/Vendedor en Barras:
Muestra en tiempo real los porcentajes exactos de presión compradora (%C) y vendedora (%V) sobre cada barra de volumen.
Personalización visual total: muestra ambos porcentajes, solo el lado ganador, ajusta el tamaño de texto, activa/desactiva el símbolo % y modifica la distancia vertical.
Detección Algorítmica de Divergencias (Precio vs. Delta):
Divergencia Alcista (Flecha Verde): Salta debajo del histograma cuando el precio hace un mínimo más bajo pero el Delta de Volumen hace un mínimo más alto (señal de absorción de oferta institucional).
Divergencia Bajista (Flecha Roja): Salta arriba del histograma cuando el precio marca un máximo más alto pero el Delta de Volumen marca un máximo más bajo (señal de agotamiento de demanda o distribución).
Clímax de Volumen y Filtros de Tendencia:
Media Móvil de Volumen (MA): Línea base del volumen promedio (fijada en 21 ruedas para gráficos diarios).
Resaltado de Clímax: Pinta las barras en color dorado brillante cuando el volumen total supera drásticamente la media móvil según el multiplicador configurado (1.8x o 2.0x), alertando sobre volumen institucional masivo o posible agotamiento.
Tabla Informativa Dinámica en Tiempo Real:
Estado Vela: Indicador en vivo del sesgo actual (ALCISTA 🟢 / BAJISTA 🔴).
% Comprador / % Vendedor: Desglose porcentual exacto de la vela en formación.
Delta Vela: Porcentaje de delta neto de la barra activa.
CVD Sesión / CVD Acumulado: Flujo continuo de dinero adaptado dinámicamente según la temporalidad del gráfico.
Actividad Vol.: Muestra la actividad de volumen respecto a la Media Móvil o la alerta de CLÍMAX ⚡.
Parámetros y Opciones de Configuración
Configuración de Temporalidad: Activa/desactiva la autoconfiguración o fuerza manualmente los modos Intradía o Diario/Semanal.
Cálculos y Visualización: Elección del método de cálculo, formatos de etiqueta, tamaños de texto y distancias en el gráfico.
Divergencias y Filtros de MA: Ajuste de períodos de Media Móvil, rango de velas para divergencias (lookback) y umbrales de clímax.
Estética de la Tabla: Control total sobre la posición de la tabla (9 anclajes), tamaño de celda, visibilidad de filas y paletas de colores totalmente personalizables (compradores, vendedores, clímax y flechas de divergencia).
อินดิเคเตอร์

VWAP Regime AI [AxeAlgo]OVERVIEW
VWAP Regime AI is an anchored VWAP (Volume-Weighted Average Price) with
standard-deviation bands, enhanced by a native, from-scratch k-means
clustering engine that classifies recent market volatility into three
regimes — Low, Medium, and High — and adapts the indicator's behavior
based on which regime is currently active.
At its foundation this is the same tool institutional desks use every
day: a running volume-weighted average price with bands around it, used
to judge where "fair value" sits and how far price has stretched away
from it. What this script adds on top is a genuine unsupervised machine
learning step that reads the market's own volatility and lets that
reading drive three things: how wide the bands are, which signal logic
is active, and how much the indicator should trust its own regime call
before acting on it.
This script is free and open-source. All calculations happen natively in
Pine Script on your own chart data.
============================================================
FULL TRANSPARENCY ABOUT THE "AI" IN THIS SCRIPT
============================================================
Pine Script cannot call an LLM, a remote model, or any external AI
service — TradingView does not allow outbound network requests from
indicators, and this script makes none. There is no hidden API call,
no "black box," and nothing running outside of what you can read in the
source code.
What "AI" means here specifically: this script implements k-means
clustering — a well-established unsupervised machine learning algorithm
— entirely in native Pine Script math and arrays. It groups a rolling
window of recent ATR (volatility) readings into three clusters by
repeatedly assigning each reading to its nearest cluster center and then
recomputing each center as the mean of everything assigned to it. This
publication states plainly what is and is not happening so nobody
mistakes this for predictive AI, sentiment analysis, or anything that
consults external data or forecasts the future. It classifies what has
already happened; it does not predict what will happen next.
============================================================
HOW IT WORKS
============================================================
VWAP & Standard Deviation Bands
--------------------------------
The core VWAP resets at the start of each new anchor period (Session,
Week, Month, Quarter, or Year — configurable) and accumulates a running
volume-weighted average from there. Standard deviation is calculated
using the same volume-weighted variance formula TradingView's own
built-in VWAP-with-bands tool. Up to three bands can be shown,
each set at a configurable standard-deviation distance from VWAP.
AI Volatility Clustering (K-Means)
------------------------------------
A rolling window of recent ATR readings (length and window size are both
configurable) is periodically re-clustered into three groups — Low,
Medium, High — using k-means. Reclustering happens every N bars rather
than every single bar, purely for performance; the live classification
of the current bar still updates continuously between reclusters.
Alongside the classification, the script computes a Confidence score
(0-100%): how much closer the current reading sits to its nearest
cluster than to its second-nearest one. A reading sitting right on a
cluster's center scores near 100%; a reading sitting on the boundary
between two regimes — an effectively ambiguous call — scores near 0%.
A "Minimum Regime Confidence" input lets you require a minimum score
before the regime is allowed to influence anything else in the script,
so an unconfident, boundary-line classification doesn't silently drive
behavior.
Adaptive Band Width
----------------------
When enabled, the standard-deviation band multipliers are scaled by a
per-regime factor: tighter in Low volatility, wider in High volatility,
instead of one fixed multiplier that's too tight in some conditions and
too loose in others. This only engages once the AI is both ready
(its lookback window has filled and it has run at least once) and
confident, per the Minimum Regime Confidence setting above.
Signal Logic — Mean Reversion, Breakout, or Auto
----------------------------------------------------
Two independent signal styles are built in, both measured off Band 2:
Mean Reversion looks for price crossing back inside the band from
outside (betting an extreme move snaps back toward VWAP); Breakout looks
for price crossing outside the band (betting the move has momentum to
keep running). "Auto" mode lets the detected volatility regime decide
which logic applies bar by bar — Low/Medium volatility defaults to Mean
Reversion, High volatility defaults to Breakout — falling back to Mean
Reversion whenever the AI isn't ready or confident enough to trust.
Three independent, stackable filters reduce noise on top of the raw
band cross:
- Bar-Close Confirmation: a cross only counts once the bar has fully
closed, filtering out intrabar wicks that reverse before the close.
- Signal Cooldown: blocks a new signal, in either direction, for a
configurable number of bars after the last one — aimed directly at
whipsaw (price crossing back and forth across a band repeatedly).
- Band Cross Buffer (hysteresis): requires price to clear a band by a
small extra distance, in standard deviations, rather than an exact
touch, so noise sitting right on the line doesn't keep re-triggering
crosses back and forth.
AI Volume Confirmation Filter
---------------------------------
The same k-means engine used for volatility is optionally reused on raw
volume, classifying each bar's volume as Low, Normal, or High. When
enabled, signals are only allowed on Normal-or-above volume, filtering
out low-conviction moves.
Secondary VWAP
-----------------
An optional second VWAP anchored to a different (typically higher)
period can be plotted alongside the primary one — for example a Weekly
VWAP behind a Session VWAP — for confluence, since multiple VWAP anchors
are commonly watched together rather than trusting a single one in
isolation. It is a reference line only; no bands are drawn for it.
Signal Track Record
-----------------------
An on-chart scorecard tracks, in a simple and fully model-free way, how
the signals have actually performed: each signal opens a virtual
position at that bar's close, and the next opposite-direction signal
closes it out, scored as a win or a loss purely on which way price
moved in between. No target or stop-loss assumption is built into this
score — see the Limitations section below for exactly what this number
does and does not tell you.
Status Table
---------------
An optional on-chart table shows the current regime and its confidence,
the active band scale, the current VWAP value, a "Stretch Score" (see
below), and the Signal Track Record numbers, all in one place.
Stretch Score
----------------
A signed z-score of how many standard deviations price currently sits
from VWAP. Because it's measured in the same standard deviations the
bands are drawn in, it stays consistent with whatever the adaptive band
width currently has in effect — a reading of +2.00 always means "sitting
on Band 2," whether that band is currently tight or wide.
============================================================
HOW TO USE THIS INDICATOR
============================================================
1. Start with the default settings and watch the status table for a
while before changing anything. Let the AI Volatility Clustering
lookback window fill (the table will show "Calibrating..." until it
has enough data) so the regime classification is meaningful.
2. Decide whether you want Mean Reversion, Breakout, or Auto signal
logic. Auto is a reasonable starting point since it adapts to
detected conditions automatically.
3. Watch the Confidence score alongside the regime label. If confidence
is frequently low on your instrument/timeframe, consider raising the
Minimum Regime Confidence input so the indicator falls back to
neutral behavior more readily instead of acting on ambiguous calls.
4. Use the Stretch Score to judge how extended price currently is
relative to VWAP in a way that stays consistent even as band width
adapts.
5. Treat the Signal Track Record as a rough, ongoing sanity check on
signal quality — not a backtest and not a promise (see Limitations).
6. This is a visual/analytical tool, not an auto-trading system. It
does not place trades. Any alerts it can generate are notifications
only.
============================================================
INPUT GROUPS (SUMMARY)
============================================================
VWAP Settings
- Anchor Period (Session / Week / Month / Quarter / Year)
- Source price used for the VWAP calculation
Secondary VWAP (Confluence)
- Show/hide toggle, its own anchor period, and its own color
Standard Deviation Bands
- Independent show/hide and distance (in standard deviations) for
three bands, plus a toggle for the gradient fill shading around them
AI Volatility Clustering (K-Means)
- Enable/disable the clustering engine
- ATR length used as the raw volatility reading that gets clustered
- Clustering lookback window (bars) and reclustering frequency
- Number of k-means refinement iterations per reclustering
- Adaptive band width toggle and the three per-regime scale factors
- Minimum Regime Confidence threshold
Signals
- Show/hide signal markers
- Signal Mode (Mean Reversion / Breakout / Auto)
- Volume confirmation filter toggle
- Bar-close confirmation toggle
- Signal cooldown (bars)
- Band cross buffer (hysteresis, in standard deviations)
Visuals
- Regime background highlight toggle
- Status table toggle and Signal Track Record toggle
- Colors for VWAP, each band, each regime, and each signal direction
============================================================
REPAINTING & REAL-TIME BEHAVIOR
============================================================
This script does not use any higher-timeframe security() calls and does
not look ahead — every value at every historical bar is a function of
data available up to and including that bar. Once a historical bar is
confirmed, its VWAP, bands, regime classification, and signals do not
change on subsequent chart loads or reloads.
Like any real-time indicator, values on the currently forming (unclosed)
bar update as new price/volume ticks arrive, and will settle once that
bar closes — this is standard behavior for any live indicator, not
repainting of historical data. If you want signal markers to appear only
after a bar has fully closed rather than updating intrabar, keep the
"Require Bar Close Confirmation" input enabled (it is on by default).
============================================================
LIMITATIONS — PLEASE READ
============================================================
- The Signal Track Record is a simplified, model-free heuristic, not a
backtest. It ignores commissions, spread, slippage, position sizing,
and any stop-loss/take-profit logic, and it scores a "trade" purely by
whether price was above or below the entry price when the next
opposite signal fired. It exists to give a rough, ongoing sense of
signal direction quality — it is not a performance guarantee and
should not be relied on as one.
- K-means clustering, like any clustering method, can produce a
misleadingly high confidence score if recent volatility (or volume)
readings happen to be nearly constant for an extended window — a rare
condition, more likely on thinly-traded instruments, but worth being
aware of.
- Regime classification and adaptive behavior depend on the Clustering
Lookback window filling with data first; expect "Calibrating..." on a
freshly loaded chart or a short history until then.
- This is a discretionary analysis tool intended to support your own
judgment, not a mechanical, guaranteed-signal system. No combination
of settings eliminates false signals entirely, which is why several
independent, adjustable filters (bar-close confirmation, cooldown,
hysteresis buffer, volume confirmation, regime confidence threshold)
are provided rather than relied on individually.
============================================================
RISK DISCLAIMER
============================================================
This script is provided for educational and informational purposes
only. It is not financial advice, and it is not a recommendation to buy
or sell any security or instrument. Trading and investing involve
substantial risk of loss and are not suitable for every investor. Past
performance — whether real, simulated, or shown via the on-chart Signal
Track Record — is not indicative of future results. Always do your own
research and consider consulting a licensed financial advisor before
making trading decisions. Use this indicator, and any alerts it
generates, entirely at your own risk. อินดิเคเตอร์

EMA Reversal Squeeze K8EEMA Reversal Squeeze K8E
The EMA Reversal Squeeze K8E is designed to identify potential momentum reversals by detecting a specific sequence of EMA compression and directional flipping.
Works on lower time frames only
The indicator monitors the 9 EMA, 20 EMA, and 50 EMA internally and looks for situations where the three averages come tightly together before reversing their order.
How LONG signals work
A LONG setup begins when:
EMA 9 < EMA 20 < EMA 50
All three EMAs are within 1 point of each other
The EMAs compress further to within 0.5 points
The EMA structure then flips to EMA 9 > EMA 20 > EMA 50
The final flip occurs while the EMAs remain within 1 point
The indicator then prints a LONG signal on the first qualifying candle.
How SHORT signals work
A SHORT setup is the exact opposite:
EMA 9 > EMA 20 > EMA 50
All three EMAs are within 1 point
The EMAs compress to within 0.5 points
The EMA structure flips to EMA 9 < EMA 20 < EMA 50
The final flip occurs while the EMAs remain within 1 point
The indicator then prints a SHORT signal on the first qualifying candle.
Why the squeeze matters
The idea behind the setup is that when the 9, 20, and 50 EMAs become extremely compressed, the market is showing a period of reduced separation between short-, medium-, and longer-term momentum.
When that compression is followed by a complete EMA order reversal, it can indicate that momentum is transitioning to the opposite direction.
The EMA lines are intentionally hidden from the chart so the indicator provides clean LONG and SHORT signals without clutter.
Note: This indicator is a technical analysis tool and should not be considered financial advice. Signals should be evaluated alongside price action, market structure, volatility, session levels, and your own risk-management rules. อินดิเคเตอร์

BearScope Pattern RadarBearScope - Bearish Pattern Scanner
OVERVIEW
BearScope is a bearish chart-pattern research indicator that identifies five commonly followed bearish formations on the current symbol and timeframe.
The indicator displays pattern-shaped outlines directly over the price chart and provides a separate lower panel showing when each formation was identified throughout the available chart history.
PATTERNS IDENTIFIED
• Classic Bear Flag
• Descending Triangle
• Rising Wedge
• Double Top
• Inverse Cup and Handle
HOW IT WORKS
Classic Bear Flag
BearScope searches for a strong downward flagpole followed by a controlled, upward-sloping consolidation channel. The upper and lower channel slopes must be reasonably parallel, and the consolidation must remain within the selected maximum retracement.
Descending Triangle
The indicator looks for approximately horizontal support combined with descending resistance and repeated tests near the support area. The pattern is identified when price confirms a downside breakdown beneath the fitted support line.
Rising Wedge
BearScope searches for rising upper and lower boundaries that converge as the pattern develops. The lower boundary must rise faster than the upper boundary, creating a narrowing structure. Identification requires a confirmed downside breakdown.
Double Top
Two confirmed pivot highs must occur within the selected price tolerance and bar-separation limits. A meaningful decline must appear between the two tops.
Because pivot highs require subsequent candles for confirmation, a Double Top is recognized only after the selected pivot-strength period has elapsed.
Inverse Cup and Handle
The indicator searches for two similar lower rim areas separated by a rounded price advance, followed by a smaller upward handle. Identification requires price to break below the rim area.
CHART DISPLAY
Pattern-shaped outlines are drawn directly on the main price chart:
• Red — Classic Bear Flag
• Yellow — Descending Triangle
• Orange — Rising Wedge
• Purple — Double Top
• Aqua — Inverse Cup and Handle
LOWER PATTERN PANEL
The lower panel contains five permanently labeled rows corresponding to the five pattern types.
• Faint dotted lines identify each pattern row.
• Thick colored segments show the complete historical duration of identified patterns.
• Colored confirmation markers identify the candle on which the script confirmed the pattern.
• Pattern names remain positioned at the left edge of the visible chart and automatically adjust when the chart is scrolled or zoomed.
ALERTS
Individual alert conditions are available for:
• Bear Flag
• Descending Triangle breakdown
• Rising Wedge breakdown
• Double Top
• Inverse Cup and Handle breakdown
IMPORTANT INFORMATION
BearScope evaluates only the symbol and timeframe currently displayed on the chart. It does not scan the entire stock market or a TradingView watchlist.
Pattern detection is based on mathematical approximations of price structure. Real-world formations are subjective, and no automated method will identify every valid pattern or exclude every questionable one.
Historical markings show when the script’s programmed conditions were satisfied. They are not evidence that a trade would have been profitable.
Double Top detection uses confirmed pivots and therefore occurs after the actual pivot candle. Pattern drawings may extend back to the formation’s earlier bars, but the information was not available until confirmation occurred.
DISCLAIMER
BearScope is provided solely for educational, informational and historical research purposes. It is not financial or investment advice and does not constitute a recommendation to buy, sell or short any security.
A detected pattern does not guarantee a downside move. Bearish formations can fail, reverse or break upward. Users should independently evaluate trend, volume, liquidity, market conditions, news, risk tolerance and position sizing before making any trading decision.
Past performance and historical chart patterns are not reliable indicators of future results. อินดิเคเตอร์

Red Light / Green LightRed Light / Green Light (ATR Distribution & FTD Signals)
Pressing the gas when momentum favors you is easy, but the hard part is knowing when to hit the brakes before getting caught in a sharp distribution drop.
Red Light / Green Light is an overlay indicator designed to keep you on the right side of heavy market moves. It combines ATR-based volatility expansion on down days with Follow-Through Day (FTD) breakout logic to give clear visual entry and exit cues right on your chart.
How It Works
Red Light (Bearish Exit Signal): Triggers on down-bars where the body size expands beyond a customizable ATR threshold (default: 1.5x 10-period ATR). This flags heavy institutional selling or distribution before a deeper pullback unfolds.
Green Light (Bullish Entry Signal): Triggers on a custom Follow-Through Day setup requiring a minimum +1.5% single-day gain, higher volume than the prior bar, and structural price support off a 10-day lookback low.
Key Features & Customization
Custom Emojis or Text: Choose from preset emojis (e.g., 🍆 / ☠️, 🚀 / 💥) or type in your own custom text labels (e.g., "BUY", "SELL", "GTFO", "DONT BE A HERO").
Smart Wick Clearance: Uses ATR-based dynamic positioning so labels remain readable across all timeframes without crowding candle wicks.
Directional Arrows: Optional toggleable pointer arrows (↑ / ↓) pointing directly at signal candles.
Alert Ready: Includes native alertcondition triggers for both Red Light and Green Light signals so you can route them to webhooks, pop-ups, or SMS.
How to Use
1. Add to Chart: Works across standard timeframes (Daily recommended for standard swing trading logic).
2. Adjust Inputs: Fine-tune ATR length, percentage gain thresholds, or lookback periods in the settings menu to fit your asset class (Equities, Crypto, Futures).
3. Set Alerts: Create a TradingView alert selecting "Red Light Alert" or "Green Light Alert" for real-time notification.
Disclaimer: For educational and informational purposes only. Always manage risk and conduct your own analysis before entering any trade. อินดิเคเตอร์

OLS Slope For Loop [MiesOnCharts]Ordinary Least Squares Slope For Loop
An ensemble of least squares regression lines, one for every window length in a range. Each fits a straight line to recent price and votes on whether that line points up or down. The plotted score is the margin of the vote, running from -1 when every window is falling to +1 when every window is rising.
Built and tuned for the daily timeframe. The inputs adjust for others.
Why an ensemble
Any single regression length is an arbitrary pick, and the best one is only obvious afterwards. Short windows turn fast and catch noise. Long windows are steady and late. This runs the whole range at once and treats direction as a vote, so no single length decides the answer.
Why a slope instead of a crossing
Price above a moving average, or price above where it sat some bars ago, both compare one number against one other number. A single violent bar can push either across the line.
A regression slope is fitted to every bar in its window. One outlier is one point among many, so the fit barely moves. A wick, a gap or a liquidation candle does not get a vote of its own.
That resistance is the whole trade, and it cuts both ways. The reading holds steady when price is chopping inside a range, which is where crossing based tools whipsaw. It is also slower to commit during a clean fast run, where a simple moving average vote will usually be ahead of it. This is meant to sit beside those tools rather than replace them.
How it works
A loop steps from the min window to the max window. Each step fits a least squares line over that many bars and votes +1 if the line rises, -1 if it falls. The votes are averaged into the score.
Every member keeps two running totals that update once per bar, so its slope comes out at a fixed cost no matter how long its window is. Re-summing every window on every bar would not survive a long chart.
A second line shows the average move the fitted lines imply, as a percent of price. It is rescaled to share the vote's axis and clipped at the edges, so if it sits pinned at the top it has run off the scale rather than maxed out. The exact figure is in the data window as Consensus Slope %.
Signals
Score at or above the threshold turns the state to uptrend and everything green. Score at or below the mirror of it turns the state to downtrend and everything red. In between, the previous state holds.
Holding between the thresholds is deliberate. A brief loss of agreement does not end a regime, and the state only turns when the other side wins outright. Triangles mark each flip, and both flips have alerts.
Inputs
Source: the price series the lines are fitted to.
Min Window and Max Window: the shortest and longest lookbacks in the ensemble. A wider span mixes more timescales and gives a smoother, slower score.
Window Step: the spacing between members. Smaller packs in more lines, finer but heavier. Larger uses fewer, coarser ones.
Trend Threshold: how much agreement is needed before the state flips. Higher is more selective and later. Lower reacts sooner and flips more often.
Show Consensus Slope and Fill To Zero: display toggles.
How to use it
Read the colour as a regime filter. A score near an extreme means every horizon agrees. A score near the middle means they are split and directional trades have less behind them.
Watch it beside a faster tool. When that one has flipped and this has not, the move so far rests on the newest bars rather than on the shape of the whole window.
Check the slope as well as the score. A full vote on a shallow drift and a full vote on a steep run look identical in the score.
Limits
It is reactive. It describes the trend price is already in and will lag turns. It does not forecast.
Nearby window lengths give similar answers, so a narrow range delivers less of the averaging benefit than a wide one.
The score moves in steps set by how many members there are. A small ensemble gives a coarse, stair stepped reading, and one member changing its mind moves the score a long way. Wider spans and smaller steps smooth this out.
Runtime grows with the number of members.
No setting is right everywhere. Test on your own market and timeframe.
Disclaimer
This indicator is provided for educational and informational purposes only and does not constitute financial, investment, or trading advice, nor a recommendation to buy or sell any asset. อินดิเคเตอร์

อินดิเคเตอร์

Confirmed Structure Transition Map [Pineify]Confirmed Structure Transition Map
Overview
This Pine Script v6 indicator separates confirmed swings, break-of-structure events, and direction candidates. A finite state appears as a stepped price corridor.
Problem Definition
A common baseline finds fractal highs and lows, then labels any crossing BOS or CHoCH. It hides the pivot bar, the later confirmation bar, and the still later break. One level may emit repeated labels, while one counter-break may be called a reversal. Label density replaces a distinction between swing formation, continuation, and transition. This script separates those events and never triggers an earlier break with future information.
Design Rationale
Confirmed pivots provide stable levels; a moving extreme has no fixed identity. Each high and low becomes a one-use rail. A break with the bias is BOS; the first qualified counter-break is only a potential CHoCH. Bias changes after a fresh rail breaks again in that direction. Crossing the frozen opposite rail or age limit cancels the candidate. This rejects immediate reversal on one counter-break. The tradeoff is lag for explicit evidence. ATR scaling filters tiny overruns but does not estimate probability.
Key Features
Optional confirmed HH, LH, HL, and LL labels.
One-use rails that suppress duplicate breaks.
BOS, potential CHoCH, shift, invalidation, and expiry states.
ATR displacement, state corridor, alerts, and dashboard.
How It Works
The script reads chart OHLC and a symmetric pivot window. A pivot is accepted after its right-side bars close. Its price and index are stored, compared with the prior same-type pivot, and armed as a rail. If price already exceeded the required displacement when it became knowable, that rail is consumed without a hindsight event.
Each confirmed bar compares the Close or Wick probe with both rails. Distance beyond a rail is divided by ATR and must meet Minimum Break Displacement. On a two-sided outside bar, the larger normalized wick defines one event. The first event sets bias; a same-direction event is BOS. A counter-event freezes break rail, invalidation rail, displacement, and start bar. Confirmation needs a fresh rail and second break in the candidate direction. Invalidation or expiry ends the candidate. The corridor shows bullish, bearish, pending, or neutral state; early bars stay neutral.
How Multiple Indicators Work Together
This is one dependent state model, not a mashup. Pivot confirmation supplies stable rails; otherwise levels move while tested. ATR displacement separates a tiny overrun from a range-scaled break. The ordered state machine consumes those qualified breaks; otherwise crossings remain a label stream. The corridor encodes the resulting state instead of adding an unrelated signal.
Trading Ideas and Insights
Read BOS as evidence that price cleared a rail with the established bias, not as an entry command. Violet marks a candidate; amber shows why it ended. A wide corridor requires a larger absolute move. Apply separate risk, liquidity, and execution rules: the map does not select stops, size positions, or forecast events.
Unique Aspects
The contribution is an ordered lifecycle. Rails arm only when knowable, each fires once, a counter-break stays provisional, and a second newly armed break is required before bias changes. Invalidation level and age limit freeze at candidate start, so later pivots cannot rewrite the test. One corridor carries bias and transition while labels, wash, bar colors, and table remain optional. This is more than a renamed fractal plot.
How to Use
Begin with Close and default pivots, then check swing density for the market and timeframe. Read rails first: BOS continues state, P-CH opens a candidate, and SHIFT completes the two-break transition. HH/HL locations are revealed after the right-bar delay, not known on their historical bars. Use BOS and shift alerts only within an existing process.
Customization
Pivot Left/Right Bars control granularity and delay: smaller values add noise; larger values add lag. Close requires settlement beyond a rail. Wick uses extremes and resolves outside bars by larger excursion. Minimum Break Displacement sets ATR clearance; Candidate Expiry limits age. Corridor, labels, wash, bar colors, and dashboard are independently configurable.
Assumptions and Limitations
Pivots need future bars for confirmation, so markers appear on pivot bars only after the right-side delay; breaks and shifts remain on confirmation bars. Probes move live, but state and alerts require bar close. ATR and pivot settings are market-sensitive. Gaps can jump rails, Wick mode reduces an outside bar to one event, and chop can repeat candidates. The model reads chart prices, not order flow, news, higher timeframes, or execution quality. A shift is an ordered event, not a guaranteed reversal or profitable trade.
Conclusion
The map turns delayed pivots and breaks into an auditable sequence: location, one-use break, provisional counter-break, then confirmation or invalidation. It provides structural context; interpretation and risk remain with the user.
อินดิเคเตอร์

Dynamic Oscillator (RSI, MACD, Stoch, Stoch RSI)Description:
This indicator combines four of the most widely used momentum and trend oscillators—RSI, MACD, Stochastic RSI, and Stochastic—into a single, unified pane.
Originality and Usefulness:
The primary issue with combining multiple bounded (0-100) and unbounded (MACD) oscillators into a single pane is overlapping, which creates an unreadable chart. This script solves that problem by introducing a Dynamic Auto-Scaling and Stacking Algorithm.
Instead of rendering all indicators on the same axis, the script dynamically assigns a visual 100-point tier (base level) to each activated indicator. If an indicator is toggled off in the settings, the script automatically recalculates the bases and shifts the remaining active indicators down to fill the void (auto-scale). This ensures a clean, non-overlapping visualization that saves valuable chart space, especially for users who rely on multiple momentum confirmations.
To achieve this, the script utilizes invisible base plots and custom helper functions drawing extended dashed lines (line.new with extend.both) to act as smart visual separators that adapt dynamically based on how many indicators are currently active.
Underlying Concepts & How It Does It:
1. MACD Normalization (Unbounded to Bounded):
Since the MACD does not have a fixed upper or lower bound, directly overlaying it with bounded oscillators is impossible without distortion. This script uses a mathematical workaround: it calculates the highest absolute value among the MACD line, Signal line, and Histogram over a 100-bar lookback window using ta.highest(). It then generates a proportional scaling factor to compress the MACD data precisely into a 100-point visual zone. The visual crosses, trend direction, and histogram shapes remain mathematically accurate to a traditional MACD, but scaled to fit the stacking environment.
2. Relative Strength Index (RSI) & Divergence:
The script includes a standard RSI (default 14-period). It is equipped with an automated Regular Divergence detection system. The logic uses ta.pivotlow and ta.pivothigh with customizable lookback windows (left and right) to identify price extremes compared to RSI extremes. Furthermore, users can enable a moving average smoothing line directly applied to the RSI calculation (SMA, EMA, WMA, VWMA, or Bollinger Bands).
3. Stochastic & Stochastic RSI:
The script calculates the traditional Stochastic Oscillator (%K and %D) using the standard ta.stoch() function based on Close, High, and Low. Additionally, it provides the Stochastic RSI, applying the Stochastic formula directly to the RSI values rather than price data, increasing sensitivity for identifying short-term overbought/oversold conditions.
How to Use It:
● Toggle System: Open the indicator settings and use the checkboxes to turn specific oscillators ON or OFF. The layout will adapt automatically.
● Confluence Trading: Use this stacked view to spot confluences. For example, spotting a Regular Bullish Divergence on the RSI occurring simultaneously with a MACD zero-line cross and a Stochastic %K/%D crossover in the oversold zone.
● Clean Visualization: The indicator uses custom transparent boundaries and dashed separator lines to keep your workspace structured.
(Note: This script is published for educational purposes to demonstrate dynamic vertical scaling of mixed-bound arrays).
Disclaimer:
This script is strictly an analytical tool for educational and informational purposes only. It does not constitute financial advice, nor is it an invitation, solicitation, or recommendation to buy or sell any financial instrument. The developer of this indicator assumes no responsibility or liability for any trading decisions, financial losses, or actions you take based on this tool. Trading in financial markets involves a high degree of risk, and all trading decisions are entirely in your own hands. Past performance of any trading system is not indicative of future results. Always Do Your Own Research (DYOR) and test strategies on a paper trading account before risking real capital. อินดิเคเตอร์

TRADLEWARE-DCA+Trend ETF
DCA + Trend: Monthly Contributions with a Bear-Market Exit and Dip-Ladder Re-entry
This strategy treats "putting money in every month" and "managing the pile of money already invested" as two separate jobs. A fixed monthly contribution never stops, even in a bear market — but the accumulated stack gets pulled out entirely when the long-term trend breaks, and put back to work gradually as the market recovers rather than all at once.
The target here is beating plain monthly dollar-cost averaging, not simple buy-and-hold. On broad-market ETFs, which tend to trend upward over long horizons, DCA already captures much of the benefit of buying dips just by staying systematic — a real bar to clear, not a strawman. It's also the one this strategy has consistently cleared across every asset tested so far (see Known limitations for where it falls short of buy-and-hold's raw return instead).
How it works
Every calendar month, a fixed dollar amount is invested, regardless of what the trend is doing — this means fixed dollars buy more shares exactly when the market is cheap, which is the whole point of dollar-cost averaging. Separately, a 200-day SMA acts as a trend filter for the accumulated position: when price closes below it, the entire stack built up so far is sold. When the trend recovers, that money doesn't necessarily go back in all at once — instead it can be split into tranches that buy in stages as price falls further below its prior peak during the bear market, so more of the recovery budget lands at genuinely lower prices instead of guessing the exact bottom.
Entry
Three separate mechanisms add to the position:
Monthly DCA: on the first bar of every calendar month, a fixed dollar amount is invested — by default, this keeps happening even during a bear market (can be turned off to pause contributions below the trend line instead)
Dip-ladder tranches: after a bear-market exit, the re-entry budget is split equally across up to three pieces, regardless of how deep each one triggers — each buys when price falls a further fixed percentage below the running all-time high (15%, 20%, and 30% below, by default) — this uses the all-time high as the reference level specifically because, unlike the moving average, it does not sink during the bear market
Lump sum recovery: any part of the re-entry budget that wasn't already spent by the dip-ladder tranches is deployed in one shot on the first bar the trend recovers
Exit
The entire accumulated position (not the monthly contributions still to come) is sold in full the moment price closes below the 200-day SMA — a trend-broken event, not something that unwinds gradually. An optional "death cross" confirmation (50-day SMA also below the 200-day SMA) can be required before treating a dip as a genuine bear market, which reduces false exits during brief pullbacks.
Parameters
SMA period: 200 days (the trend filter for the exit)
SMA hysteresis band: a dead zone around the SMA, on by default. The regime only flips bullish above SMA×(1+band) or bearish below SMA×(1-band); price sitting between those two lines just holds whatever state it was already in. This filters out marginal SMA crossings that would otherwise trigger an exit and re-entry over a move that never became a real trend break — most such round trips re-buy at close to the same price they sold at, paying costs without capturing anything. Set to 0 to require only a plain SMA cross.
Monthly DCA amount: fixed dollar amount invested on the first bar of each month
Lump re-entry percentage: how much of the value that was sold at the exit gets redeployed on recovery (0 = skip lump entirely and resume monthly DCA only; higher = more of the recovery captured, at the cost of more drawdown if the recovery turns out to be a false one)
Death cross confirmation: off by default; when enabled, requires the 50-day SMA below the 200-day SMA before treating the market as unsafe
DCA during bear regime: on by default; contributions keep buying through the bear market instead of pausing
Dip-ladder toggle and three rung levels (percentage below the running high): default 15%, 20%, 30% below; any rung can be set to 0 to disable it
Whole-share DCA: off by default. A fractional monthly quantity (contribution amount smaller than one share) rounds down to zero on most equity brokers and never fills or fires an alert. Turning this on banks any unspent contribution and carries it to the next month, firing a whole-share order once enough has accumulated
Label offset: how far the buy/sell trade labels sit from the bar, in multiples of ATR(14)
Chart labels
Every fill is marked directly on the chart: a green label below the bar for each buy (tagging which mechanism fired — DCA, LUMP, or RUNG 1/2/3, combined if more than one lands on the same bar) and a red label above the bar for each exit (CRASH EXIT or PERIOD END), showing the blended profit/loss across everything that closed on that bar. Since one crash exit can unwind dozens of separate monthly contributions and dip-ladder buys at once, the P&L shown is the combined result of all of them, not just one trade. Both label types also show the cash left in the account after that fill — useful for keeping an eye on how close the pool is to running dry, since TradingView blocks an order it can't cover and DCA/lump/rung buys stall until the next sale refills it.
Costs modelled
0% commission (typical for US equity brokers), 1 tick slippage, fills at next bar's open.
Intended assets and timeframe
Daily bars, US equity ETFs. Built and tested on MGK specifically, using the settings published as its defaults (death-cross confirmation off, rungs at 15/20/30% below the running high) — that combination is the only one checked end-to-end against a live TradingView run. Seven other broad-market, growth, value, equal-weight, and momentum funds — QQQ, VOO, IVW, IVE, RSP, SPYM, and SPMO — were also tested, each with its own settings rather than MGK's defaults left unchanged, and are very likely to beat plain monthly DCA too: that pattern held without exception on every asset checked so far. Their validated combination is different from what's published here — death-cross confirmation on and wider rungs at 20/30/40% — which is the better starting point if you switch tickers, with QQQ as the one exception even to that (see Known limitations): it pairs better with death-cross confirmation off and the hysteresis band set to 2% instead. Parameter choices matter more than they might look — death-cross on/off, the lump percentage, and the rung spacing have each swung the outcome by a wide margin in testing — so tuning for whichever asset and regime you're actually using, rather than leaving the MGK-tuned defaults unchanged, is worth the effort.
Known limitations
The exit reacts at the next bar's open after the trend breaks, so it lags fast crashes rather than anticipating them. In a slow, grinding bear market, the dip ladder's fixed rungs can all fire and the market can keep falling anyway, leaving a larger paper loss than the version without a ladder — the extra return the ladder aims to capture on recovery is paid for with real, and sometimes severe, worst-case pain during a prolonged decline. Size the lump and rung percentages to a drawdown you could actually hold through, not just a comfortable one. Bear-market DCA contributions can sit on paper losses for a long time before a recovery arrives. Switching to one of the other seven validated funds calls for different settings than the published MGK defaults — see Intended assets and timeframe above. QQQ specifically pairs better with the death-cross confirmation off and the hysteresis band at 2% rather than either of the other two combinations. For VOO, turning death-cross confirmation on is a genuine trade-off rather than a clear-cut fix: it gives a smaller drawdown and better Calmar ratio at the cost of slightly lower return and Sharpe. TradingView's own chart price does not include dividends, so a live TradingView backtest will differ somewhat from a dividend-adjusted one, though trade dates should still match. Over the published defaults' validated window, trade count sits below the sample size usually wanted for stable statistics — treat this as a directional result to build on, not a confirmed edge, until it's been checked over a longer window or across more of the validated assets.
If you already hold a lump-sum position and plan to add ongoing contributions on top of it, don't feed the lump into this strategy's own trading — a crash exit sells everything it holds at once, lump included, and testing found that dragged results down noticeably compared to keeping an existing lump in a separate buy-and-hold position and only running new contributions through this strategy. Even limited to just the ongoing contributions, though, this strategy's trading is not guaranteed to beat simply holding those same contributions — in the scenarios tested so far, plain buy-and-hold of the contributions matched or outperformed running them through the strategy's exit/re-entry logic. Treat this as a tool for managing how an existing trend-following thesis gets traded, not as a proven improvement over doing nothing.
กลยุทธ์

Artillery EliteArtillery Elite is a session momentum-pullback signal indicator for intraday index futures. It marks BUY/SELL candidates only when several independent conditions line up at once - trend structure, VWAP bias, a completed pullback, momentum strength and the time of day - and then draws the full trade context (entry, stop, target zones) so you can judge each signal against your own plan. This canonical publication consolidates the earlier Artillery Elite variants (two strategy versions and an older indicator build) into one script.
WHAT IT DOES
A signal prints only when ALL of these agree:
1) Trend structure - the 9 EMA above the 21 EMA for longs (below for shorts), with a 50 EMA plotted for wider context.
2) VWAP bias - price on the trend side of the session VWAP: longs only above it, shorts only below it.
3) Pullback and resume - one of the last two bars dipped through the 9 EMA (the pullback), and the signal bar closes back beyond the 9 EMA in the trend direction with a real body.
4) Momentum floor - ADX (computed from the classic DMI recursion) above a configurable minimum, so signals are skipped in driftless tape.
5) Session windows - signals fire only inside the configurable AM (9:45-11:30 ET) and PM (14:00-15:30 ET) windows, with a separate highlighted mid-morning focus window. A cooldown gate spaces consecutive signals.
WHY THESE FILTERS TOGETHER
Each filter fails in a different way on its own: EMA crosses whipsaw in chop, VWAP bias alone is late, pullbacks against momentum keep pulling. Requiring structure + bias + a finished pullback + a momentum floor + the right session is what turns five ordinary conditions into one selective checklist. All code is original and uses only Pine built-ins.
WHAT YOU SEE ON THE CHART
- BUY / SELL labels on qualifying bars, with gold-highlighted signal bars
- Optional projection lines and shaded zones for the reference entry, stop and target (point-based inputs, drawn for study - not advice)
- Session VWAP (gold), the 9/21 EMA pair with a trend-tinted fill, and the 50 EMA
- Background shading for the AM window, PM window and the mid-morning focus window
- A dashboard with trend state, VWAP bias, live ADX, current signal, active session and the configured reference R:R
- Eight visual themes
INPUTS
Reference TP/SL in points (defaults scaled for MNQ - rescale for other symbols), signal cooldown, ADX minimum, short-signal toggle, the three session windows, per-layer visual toggles and the theme picker.
ALERTS
Two alert conditions: BUY signal and SELL signal.
BEHAVIOUR NOTES
Conditions are evaluated on the live bar and confirm at bar close, so a forming signal can appear and disappear until its bar closes. The script uses no higher-timeframe requests and no lookahead. This is a signal-study tool: it does not measure or display any historical win rate, and drawn targets are geometric references, not predictions.
This is an educational and analytical tool. It is not financial advice. อินดิเคเตอร์

Pattern Echo - Market Outcome ForecasterOVERVIEW
EchoEdge is a historical-analog research indicator that compares the current confirmed market environment with similar conditions previously observed on the same symbol and timeframe.
Rather than producing a conventional buy or sell signal, the indicator asks:
“What happened after this symbol previously displayed comparable technical conditions?”
It identifies independent historical matches, studies their subsequent price behavior, and summarizes those outcomes in an on-chart dashboard and forward projection.
METHODOLOGY
Each historical comparison uses a normalized collection of technical characteristics:
• 20-bar price momentum
• RSI
• ATR-based volatility
• Relative volume
• Distance from the 20-period EMA
• Position within the 52-week price range
• ADX trend strength
• Relative strength versus the selected benchmark
• EMA 20/50/200 trend alignment
• 20-period EMA slope
The script calculates a similarity score between the current confirmed market state and eligible historical observations.
Potential matches are ranked by similarity. A user-adjustable minimum separation prevents neighboring candles from the same historical event from being counted as multiple independent matches.
Historical observations without a completed forward evaluation period are excluded.
DASHBOARD
The dashboard displays:
• Analyzed candle — the confirmed candle being evaluated
• Best similarity — similarity of the closest historical match
• Average similarity — average across all accepted matches
• Independent matches — accepted matches meeting the similarity and spacing requirements
• Target reached first — percentage that reached the selected target before the stop
• Stop reached first — percentage that reached the selected stop before the target
• Neither reached — percentage that reached neither level during the evaluation period
• Median forward return — median closing return after the selected number of bars
• Median maximum upside — median highest favorable excursion
• Median maximum drawdown — median largest adverse excursion
• Entry, target and stop — reference levels derived from user-selected percentages
• Reward/risk — mathematical ratio between the selected target and stop distances
• Historical verdict — descriptive summary of the accepted historical outcomes
• Closest historical dates — dates of the three closest accepted matches
The verdict can be Favorable, Mixed, Unfavorable or Insufficient Matches. It summarizes the selected historical sample and is not a trading recommendation.
CHART COLORS
• Solid blue projection — median path followed by the accepted historical matches
• Dashed green projection — upper-quartile historical path
• Dashed red projection — lower-quartile historical path
• Green dotted horizontal line — user-defined target reference
• Red dotted horizontal line — user-defined stop reference
• Blue “DNA” labels — locations of the five closest historical analogs
• Green dashboard cells — comparatively favorable historical values
• Amber dashboard cells — mixed, intermediate or cautionary values
• Red dashboard cells — comparatively unfavorable historical values
• Gray dashboard cells — neutral, informational or unavailable values
The projected paths are distributions of historical outcomes. They are not forecasts of exact future prices and should not be interpreted as support, resistance or guaranteed destinations.
IMPORTANT LIMITATIONS
Historical similarity does not establish causation and does not ensure that future price behavior will resemble prior outcomes.
Results can vary substantially by symbol, timeframe, available history, benchmark, similarity threshold, forward period, target, stop and minimum match-separation settings.
Small samples may be statistically unreliable. A high similarity score means that the selected technical measurements were alike; it does not mean that the subsequent outcomes will also be alike.
Target-first and stop-first statistics use historical bar highs and lows. When both levels occur within the same candle, their actual intrabar order cannot be determined. The script therefore applies the conservative assumption that the stop occurred first.
The indicator uses standard OHLCV candles for its calculations, even when displayed on a synthetic chart type. When “Use last confirmed candle” is enabled, the current unconfirmed candle is excluded from the analysis.
This indicator does not account for commissions, slippage, bid/ask spreads, liquidity, taxes, news, earnings events or changes in market structure.
DISCLAIMER
EchoEdge is provided solely for educational, informational and historical research purposes. It is not financial, investment, legal or tax advice and does not constitute a recommendation or solicitation to buy or sell any security or financial instrument.
No result, projection, target, stop, similarity score, alert or historical verdict guarantees future performance. Users are responsible for conducting their own research, evaluating risk and determining whether any trade is appropriate for their circumstances.
Past performance and historical analogs are not reliable indicators of future results. อินดิเคเตอร์

อินดิเคเตอร์

Momentum Bands | BreakoutThis strategy hunts for N-bar breakouts confirmed by volume expansion — but instead of trading every breakout blindly (like a standard Opening Range or Donchian breakout), it runs price through a trend filter and an RSI momentum check first. Breakouts that align with the EMA trend and show accelerating RSI get traded as genuine continuation moves. Breakouts that fire against the prevailing trend, with RSI already rolling over, get treated as exhaustion — and faded instead of chased. Built-in ATR-based position sizing and a trailing stop round it out into a complete, risk-managed system rather than just a signal generator.
Key Features
Trend-gated entries — EMA fast/slow cross defines regime; longs only trade with the trend, fades only trade against it
Volume-confirmed breakouts — requires expansion above the rolling volume average, not just a price poke
RSI momentum-exhaustion filter — distinguishes accelerating momentum (real breakout) from divergence (fakeout)
ATR-based risk sizing — position size auto-scales to a fixed % of equity risked, using ATR-derived stop distance
ATR trailing stop — lets winners run instead of capping them at a fixed target
Glowing ATR bands — layered, fading visual bands around trend basis for at-a-glance regime read
Breakout candle highlighting — candles color-shift on signal and while a position is open
Live + archived trailing-stop path — see the stop while a trade is open, and its full trail once closed
How It Works
Price breaks above the highest high of the last N bars with volume above its rolling average — that's the breakout trigger.
EMA fast vs. slow defines trend direction.
RSI and its rate of change are checked at the breakout bar: still climbing and near its own recent peak = momentum confirms. Already fading or below its recent peak = momentum diverges.
Confirmed + with-trend → long. Diverging + against-trend → short (fade).
Every entry is sized off account risk %, not a fixed share count, and exits on an ATR stop plus ATR trailing stop.
Tips
Backtest across multiple symbols and volatility regimes before trusting the defaults — breakout/fade systems behave very differently in trending vs. choppy markets
Widen nLen (breakout lookback) on lower timeframes to reduce noise-driven false breakouts
If fades are underperforming, try disabling allowShorts and running long-only to isolate performance
Tighten rsiConfirmLvl for higher-conviction (fewer, cleaner) long signals
Use the glowing bands as a quick visual regime check even when not actively watching signals
กลยุทธ์
