Penunjuk

Relative Strength (RS) - Mansfield StyleRelative Strength (RS) measures how a symbol performs against a chosen
benchmark. Instead of plotting the raw price ratio — whose scale differs
from one symbol to another and makes comparison difficult — this script
normalizes the ratio (symbol close / benchmark close) against its own
simple moving average over a configurable lookback "Period". The result
is a zero-centered line that reads the same way on any symbol:
- RS above 0 and rising → the asset is outperforming the benchmark
- RS below 0 and falling → the asset is underperforming
- Zero-line crossings → shifts in relative leadership
Only the direction and the position relative to zero matter, not the
absolute value.
█ HOW IT WORKS
1. The script requests the benchmark's close on the selected timeframe.
2. It computes the raw ratio: symbol close / benchmark close.
3. The ratio is divided by its SMA over the "Period" lookback, minus 1 —
expressing how far the current relative strength stands above or
below its recent average.
4. An optional moving average of RS can be displayed as a signal line.
█ INPUTS
- Comparative Symbol: the benchmark (an index such as SPX, a sector
index, or any peer symbol — e.g. compare gold against silver).
- Period (default 50): normalization lookback. Shorter = more reactive,
longer = smoother and slower.
- Show Moving Average / Moving Average Period: optional smoothing line.
- Timeframe: leave empty to use the chart's timeframe, or select a
higher timeframe for multi-timeframe analysis.
█ HOW TO USE
Apply the indicator to any symbol. When RS holds above zero, the asset
is leading its benchmark — favor it for relative-strength strategies
(buy strength). When RS holds below zero, the asset is lagging — avoid
it or rotate out. Zero-line crossovers flag early changes in relative
leadership, and two built-in alerts fire on these crossings.
RS is a relative tool, not a timing tool: an asset can outperform a
falling benchmark while still declining in absolute terms. Combine it
with your own trend or entry criteria.
█ CREDITS
The normalization method follows the Mansfield Relative Strength
concept popularized by Stan Weinstein in "Secrets for Profiting in
Bull and Bear Markets".
█ NOTE ON HIGHER TIMEFRAMES
When a higher timeframe is selected in the Timeframe input, the value
of the current forming bar updates until that bar closes. Historical
values do not repaint. Penunjuk

Forex: Custom Index Widgets [invincible3]Forex: Custom Index Widgets
Forex: Custom Index Widgets is a professional currency-strength dashboard designed to visualize real-time strength, weakness, momentum quality, and market rotation across the eight major forex currencies: USD, EUR, GBP, JPY, AUD, NZD, CAD, and CHF.
Unlike a simple EMA-based strength meter, this indicator builds custom currency indices from the 28 major FX crosses and displays them as compact mini index widgets directly on the chart. Each currency index is reconstructed from its related currency pairs, allowing traders to observe the independent behavior of each currency rather than relying only on the chart symbol.
The indicator combines two major components:
1. Custom Currency Index Widgets
2. Professional Composite Force Table
The custom index widgets show the short-term structure of each selected currency index using mini candles. This makes it easier to visually compare whether a currency is trending, drifting, compressing, or impulsively expanding. The widget section also includes a volatility smart layer, which adjusts candle appearance according to volatility conditions such as quiet movement, expansion, or extreme impulse.
The table section ranks currencies using a composite force model. Instead of using EMA direction alone, the table evaluates multiple strength components, including relative strength, breadth, efficiency, impulse, acceleration, and phase. This gives a more complete view of currency behavior and helps identify clean strength, weak currencies, rotation conditions, and potential strongest-versus-weakest pair opportunities.
Key Features
* Builds custom indices for USD, EUR, GBP, JPY, AUD, NZD, CAD, and CHF.
* Uses 28 major forex crosses to construct currency strength.
* Displays mini custom index widgets directly on the chart.
* Optional EMA overlay on the custom index widgets.
* Volatility-aware widget candles.
* Composite force ranking table.
* Measures strength beyond simple EMA direction.
* Includes breadth, efficiency, impulse, acceleration, and phase logic.
* Highlights strongest and weakest currencies.
* Suggests the best strongest-versus-weakest pair bias.
* Professional table design for both dark and light TradingView themes.
* Theme-adaptive colors for improved readability.
* Adjustable widget layout, table position, and display options.
* Designed to remain lightweight by avoiding unnecessary multi-timeframe request overload.
How the Custom Indices Work
Each currency index is calculated by combining its related FX pairs. For example, USD strength is derived from pairs such as EURUSD, GBPUSD, AUDUSD, NZDUSD, USDCAD, USDCHF, and USDJPY. When USD is the quote currency, the pair movement is inverted; when USD is the base currency, the movement is used directly.
This directional aggregation allows the indicator to estimate the independent strength of each major currency.
For example:
* If EURUSD falls, USD strength increases.
* If USDJPY rises, USD strength increases.
* If GBPUSD rises, GBP strength increases.
* If AUDJPY falls, JPY strength increases.
This approach gives a broader currency view than looking at one forex pair alone.
Composite Force Table
The table is designed to act as the main decision dashboard. It ranks all currencies from strongest to weakest using a multi-factor force score.
The force model includes:
Relative Strength
Measures how strongly a currency index has moved compared with others.
Breadth
Checks whether the currency strength is broad-based across its related pairs or caused by only one or two pairs.
Efficiency
Measures how clean the move is. A currency that trends smoothly receives a stronger quality score than one that moves in a choppy manner.
Impulse
Detects whether current movement is expanding with force compared with recent movement.
Acceleration
Shows whether strength is increasing or fading.
Phase
Classifies the current currency condition into practical market states such as bullish expansion, bearish expansion, build-up, drift, exhaustion, or rotation.
Market Phase Interpretation
The phase column helps traders understand the quality of the move:
Bull Expand
The currency is strong, broad, and moving with impulse.
Bear Expand
The currency is weak, broad, and moving lower with impulse.
Bull Build
Strength is developing, but the move may still be in an early stage.
Bear Build
Weakness is developing, but downside pressure may still be forming.
Bull Drift / Bear Drift
The currency has directional bias, but the movement is not yet highly aggressive.
Bull Exhaust / Bear Exhaust
The currency is still strong or weak, but acceleration is fading. This can warn of possible rotation or pullback.
** Rotation **
No clear dominant force. Market conditions may be mixed or neutral.
Strongest vs Weakest Logic
One of the most useful ways to apply a currency strength meter is to compare the strongest currency against the weakest currency.
For example:
* If USD is strongest and AUD is weakest, the dashboard may highlight a USD/AUD long bias where available, or an AUD/USD short bias.
* If EUR is strongest and JPY is weakest, EURJPY may become a high-priority pair to watch.
* If GBP is weakest and CHF is strongest, GBPCHF may become a short-bias candidate.
This does not mean traders should enter immediately. The table is designed to identify directional bias and currency selection. Entry timing should still be confirmed with market structure, price action, support/resistance, liquidity zones, session timing, or the trader’s own strategy.
Widget Section
The mini index widgets provide a visual snapshot of each currency index. They allow traders to see whether the index is pushing higher, selling off, compressing, or moving with volatility expansion.
Widget features include:
* Mini candle visualization of selected currency indices.
* Optional EMA overlay.
* Customizable widget height and spacing.
* Volatility-based candle width and transparency.
* Labels showing index name, current movement, timeframe, and volatility state.
* Clean theme-adaptive styling for professional chart layouts.
EMA Usage
EMA is included as an optional visual guide on the custom index widgets. It should be treated as a secondary confirmation tool, not the main strength engine.
The main ranking logic comes from the composite force model, while EMA helps visually confirm whether the mini index structure is trending or flattening.
Suggested Usage
This indicator can be used for:
* Finding the strongest and weakest currencies.
* Selecting high-probability forex pairs.
* Confirming directional bias before entering trades.
* Avoiding weak or conflicting currency combinations.
* Detecting currency rotation.
* Monitoring whether strength is broad or narrow.
* Comparing currency behavior across all major FX groups.
* Supporting intraday, swing, and session-based trading workflows.
A common workflow is:
1. Check the table for the strongest and weakest currencies.
2. Confirm that the force gap is meaningful.
3. Check the phase column for expansion, build-up, or exhaustion.
4. Use the mini widgets to visually confirm index direction.
5. Move to the actual forex pair chart for entry confirmation.
6. Use your own price-action or risk-management rules for execution.
Important Notes
This indicator is a market analysis tool, not an automatic buy/sell system. It is designed to show currency strength, weakness, rotation, and relative force. The strongest currency can remain strong for a long period, but it can also become exhausted. The weakest currency can continue falling, but it can also sharply reverse during rotation phases.
Always combine this tool with proper risk management and independent trade confirmation.
Best For
Forex traders
Currency strength analysis
Intraday trading
Swing trading
Strongest-versus-weakest pair selection
Market rotation analysis
Multi-currency dashboard workflows
Traders who want more than a basic EMA strength meter
Summary
FX Custom Index Force Meter PRO is designed to give traders a complete view of major currency behavior. It combines custom-built currency index widgets with a professional multi-factor force table, allowing traders to see not only which currency is strong or weak, but also whether that strength is broad, efficient, impulsive, accelerating, or fading.
The goal is to help traders move beyond simple EMA-based analysis and toward a more structured, professional currency selection process.
Penunjuk

Penunjuk

DAX Universe Relative Strength & Volume Quality [JS]DAX Universe RS & Volume Quality is a relative strength and pullback quality indicator designed for German stocks from the DAX, MDAX, SDAX and TecDAX universe.
The indicator measures a stock’s weighted relative performance against an equal-weighted German equity benchmark made from DAX, MDAX, SDAX and TecDAX. The relative strength model is inspired by IBD / Minervini-style momentum analysis, giving more weight to recent performance while still considering the medium- and longer-term trend.
Relative Strength Model:
• 40% weight: approx. 3-month performance
• 20% weight: approx. 6-month performance
• 20% weight: approx. 9-month performance
• 20% weight: approx. 12-month performance
The result is displayed as a percentage relative to the German stock universe benchmark:
• RS above 0% = the stock is outperforming the benchmark
• RS below 0% = the stock is underperforming the benchmark
• RS above the user-defined strength threshold = RS STARK / strong relative strength
In addition to relative strength, the indicator includes a High-Volume Down-Day filter. This helps assess whether a pullback is still constructive or whether distribution pressure may be increasing. The user can define:
• Lookback period
• Minimum loss required for a down-day to count
• Volume moving average length
• High-volume factor
• Maximum allowed High-Volume Down-Days
The simplified status box highlights the current setup condition using color:
• Green = strong relative strength and acceptable volume quality
• Yellow = positive or improving relative strength, but not yet ideal
• Red = weak relative strength or too many High-Volume Down-Days
The textbox position, size, width and height can be adjusted in the indicator settings.
This indicator is designed as a decision-support and screening tool for relative strength, pullback quality and German stock leadership analysis. It is not an official IBD RS Rating and does not provide financial advice or automatic buy/sell recommendations. Always combine it with your own chart analysis, risk management and market context. Penunjuk

Penunjuk

Ultimate RSIHere is a breakdown of its core features and how they work together:
1. Volatility-Adaptive RSI Length
How it works: Instead of using a static length (like the traditional 14-period RSI), the script calculates the market's standard deviation (volatility).
The Benefit: When the market is highly volatile, the RSI length dynamically shortens, making the indicator more responsive so you can catch quick reversals. When volatility drops (consolidation), the length expands, smoothing the RSI line to filter out "chop" and false signals.
2. Dynamic Overbought / Oversold Zones (Bollinger Bands)
How it works: Standard RSIs use static horizontal lines at 70 and 30. This script applies Bollinger Bands directly to the RSI values themselves.
The Benefit: A reading of 70 isn't always overbought in a strong trend. By wrapping the RSI in a standard deviation channel, you get a dynamic zone. If the RSI breaks above its upper dynamic band, you know momentum is genuinely extreme relative to recent conditions, rather than a fixed arbitrary number.
3. Automated Divergence Detection
How it works: The script constantly scans for discrepancies between price action and RSI momentum.
The Benefit: It automatically plots visual markers on the RSI pane when it detects:
Regular Divergences (Reversals): E.g., Price makes a Lower Low, but RSI makes a Higher Low (Bullish Divergence).
Hidden Divergences (Trend Continuations): E.g., Price makes a Higher Low, but RSI drops to a Lower Low (Hidden Bullish).
4. RSI Moving Average (Signal Line)
How it works: An additional moving average (you can choose between SMA, EMA, RMA, WMA, or HMA) is plotted alongside the RSI.
The Benefit: This acts as a trigger line. An RSI crossing above its EMA can be used as an early entry signal, or as confirmation that momentum has definitively shifted.
5. Multi-Timeframe (MTF) Support
How it works: You can configure the indicator to calculate RSI based on a higher timeframe (e.g., pulling 4-Hour RSI data while you are looking at a 15-minute chart).
The Benefit: This ensures your lower timeframe entries are always aligned with the macro momentum, preventing you from trading against the larger trend.
6. Visual Confluence & Alerts
The RSI line itself is color-coded. For example, it turns bright green when momentum is both above 50 and rising, and dark red when below 50 and falling.
It includes a full suite of alert conditions (divergences and MA crossovers) so you can automate your trading or get pinged when a setup occurs.
In summary, it's designed to replace 3 or 4 different indicators on your chart by giving you adaptive momentum, dynamic exhaustion zones, trend direction, and divergence signals all natively in one branded, professional package. Penunjuk

Directional Strength OscillatorDirectional Strength Oscillator
A signed trend-strength oscillator that reads the tug-of-war between upward and downward movement and prints one line — positive in uptrends, negative in downtrends, crossing zero at trend changes. Unlike a plain directional reading, it dims itself when price is only chopping, flags weakening trends through divergence, and scores its own signals forward on your chart in plain language.
Why these parts are combined (not a mashup for show). Each part answers what the previous one leaves open. Up-movement vs down-movement relative to true range gives a clean, bounded read of who's winning and by how much — but it can read "strong" inside noisy, non-trending chop. A trend-efficiency filter (net travel over total path) measures whether price is actually going somewhere; folding it into the line removes the false-strong chop. A divergence check (price makes a new extreme while strength does not) flags weakening trends the raw line would miss. Together they form one directional-strength tool.
How it works. Up-movement = |high − prior low|, down-movement = |low − prior high|; each is summed over the length and divided by summed true range to get the up and down lines. Their difference is the raw strength; it's standardized, soft-bounded to ±100, then scaled by a 0–1 trend-efficiency factor. Signals are zero-crosses gated by a minimum quality, plus divergence against price (measured on the undimmed strength). Each signal is then labelled by a triple barrier — a profit target and equal stop in ATR units plus a time limit — so a "win" means the target hit before the stop. Results split into in-sample and recent out-of-sample, with a confidence interval and a multiple-testing check.
How to use. Read the Verdict row (Long/Short signal, Watch, or Wait) and the Conviction row, which reads "High" only when that signal type shows a positive edge that survives the test on this symbol. Green line above zero = uptrend in control, red below = downtrend; shaded bands = strong trend; the trend-quality % tells you how clean the move is. Best used with your own entry and risk plan, not alone.
What's original. The trend-quality gate that removes false-strong chop, integrated divergence on the undimmed line, the forward triple-barrier calibration with an out-of-sample split, and a conviction read that openly admits when there's no proven edge.
Inputs. High/Low sources (change them for any market), reading mode (Simple/Pro), engine, quality-gate, divergence and full calibration settings, and an auto-adapting dashboard legible on dark or light charts. Defaults are tuned for NSE:NIFTY1! intraday.
Honesty & limitations. Edge figures are computed on this chart's own history with overlapping windows and no costs — context, not a guaranteed backtest; past behaviour doesn't predict the future.
Disclaimer: for research and education only. Not financial advice. Trading carries risk of loss; manage your own positions. Penunjuk

RX: Dual RSI Fusion 14/50 Compression Framework## RX: Dual RSI Fusion 14/50 Compression Framework
Is an advanced momentum framework designed to identify potential market exhaustion, compression phases, and high-probability reversal conditions by combining two Relative Strength Index structures into a single analytical model.
Unlike traditional RSI indicators that rely on a single momentum source, this framework integrates both a fast RSI (14-period by default) and a slow RSI (50-period by default) to provide a multi-layer view of market behavior.
### Core Concepts
• **Fast RSI (14):** Captures immediate momentum shifts, short-term exhaustion, and early divergence signals.
• **Slow RSI (50):** Represents the underlying market structure and helps identify broader momentum regimes.
• **Dynamic Compression Engine:** Measures the convergence between moving averages applied to the fast RSI, highlighting periods where momentum becomes increasingly compressed and potentially preparing for expansion.
• **Exhaustion Detection:** The indicator is specifically designed to monitor the sequence of events frequently observed near market turning points, including divergence development, momentum contraction, and structural breakout.
### Features
✔ Dual RSI architecture (Fast + Slow)
✔ Configurable moving averages applied directly to RSI values
✔ Compression detection between fast RSI moving averages
✔ Divergence memory engine with customizable validity period
✔ Momentum Delta histogram (Fast RSI - Slow RSI)
✔ Structural breakout detection from RSI compression zones
✔ Background state visualization for market context
✔ Alert conditions for potential exhaustion breakouts
### Interpretation
The framework is based on the premise that important market reversals are rarely caused by a single event. Instead, reversals often emerge from a succession of conditions:
1. Momentum divergence appears.
2. RSI structure begins to compress.
3. Market enters an exhaustion phase.
4. Fast momentum escapes the compression structure.
5. Expansion begins.
The indicator seeks to visualize this process and provide objective confirmation of potential exhaustion scenarios.
### Notes
This tool should not be interpreted as a standalone buy or sell system. It is intended to be used as a market structure and momentum exhaustion framework, ideally combined with price action, liquidity analysis, volume, or higher timeframe context.
Developed as part of the SXA analytical ecosystem by @Peter_n_n
Penunjuk

Sweep and Cluster [JOAT]SWEEP AND CLUSTER
A two-stage liquidity-sweep engine. Most public "sweep" indicators print a label on every wick that pokes past a recent high or low — which is mostly noise. Sweep and Cluster requires two separate events to register a tradeable signal: first a strict 5-condition sweep, then a confirming cluster of price action in the rejection direction. The label that actually appears on the chart is the rare intersection — the moments where institutional stop-running is followed by genuine commitment in the opposite direction.
Stage 1 — Strict 5-condition sweep detection
A sweep is registered only when all of these are true on the same bar:
Real pivot reference — the swept level is an actual minor pivot (ta.pivothigh / ta.pivotlow) from the rolling cache, not a rolling max/min. A scan-depth input controls how far back to look; a minimum-age gate prevents self-reference.
Wick magnitude — the wick that exceeds the pivot must be at least Wick ATR Multiplier × ATR(14) (default 0.8 ATR). The KB-published strict threshold.
Wick dominance — wick length must be at least Wick/Range Ratio of the candle's total range (default 35%). The wick must dominate the bar's shape, not be a side-effect of a large body.
Closing direction — close must be back inside the swept level. A clean wick that closed beyond the pivot is a breakout, not a sweep — and is filtered out by construction.
Cooldown — at least N bars (default 8) since the last same-side sweep. Prevents one stop-run from being counted as multiple sweeps when the wick prints over several bars.
If all five conditions are met a pending marker is placed (optional). Pending markers represent "a sweep happened" but not yet "the sweep was meaningful" — until the cluster confirms, the sweep is not actionable.
Stage 2 — Cluster confirmation
After a sweep fires, the next N bars (cluster window, default 5) are monitored for confirming follow-through. The cluster confirms only when:
At least M bars (default 1) close against the swept direction inside the window.
Average body/range across the qualifying cluster bars exceeds the Min Body Ratio (default 0.25) — the rejection candles must be impulsive, not micro-bodies.
Cumulative volume across the cluster window is at least Volume Multiplier × Average Volume (default 0.8×). Without volume the cluster is not commitment.
When all three confirm, the script fires the SAC (Sweep And Cluster) label — the actionable signal. A cluster strength badge (body sum / ATR) is rendered next to the label so you can rank one SAC vs another at a glance.
A failed sweep marker (toggleable, off by default) tracks sweeps that expired without confirming — useful for auditing the false-positive rate visually and for choosing thresholds.
Visual system
Sweep wick highlight — a thin coloured line at the swept reference price, extended right by a configurable number of bars. Makes the rejection unmistakable.
Reference level triangle — small glyph at the actual pivot level that was swept.
Cluster candle override — when SAC fires, the confirming cluster candles are repainted in the active-side theme colour via plotcandle so the move stands out from background.
Optional background tint — fading directional bgcolor for a few bars after a confirmed SAC.
Optional bar paint by active bias — every bar painted bull/bear based on the most recent SAC. Off by default to preserve chart neutrality.
A locked Quantum palette (cyan-quantum bull / pink-quantum bear on a deep void) gives the chart a distinctive sweep-and-reverse identity.
Dashboard + rolling statistics
A monospaced table, positionable to any of nine corners, with vertical row-fade for premium feel. Surfaces:
Total sweeps and total SACs since the last session/day/week reset (configurable reset frame).
Rolling Confirmation Rate (% of recent sweeps that became SACs) over a configurable window (default 50). The script's own success metric.
Pending sweep status with bars-remaining-in-cluster-window.
Last SAC direction with strength badge and bars-ago.
Last failed sweep tag (when failed markers are enabled).
Confirmation Rate is the headline read — it lets you see whether the current threshold settings are producing meaningful or sparse signals on the instrument you are trading.
Alerts
Three alert conditions, each independently controllable:
Pending Sweep (Stage 1 fires)
SAC Confirmed (Stage 2 confirms)
SAC Failed (Stage 2 expires without confirming) — off by default
How to read it
Two reads, in order of conviction:
SAC Confirmed alert with a high strength badge — the script's intended signal. Liquidity was swept, a real rejection followed inside the window, and the rejection had body and volume. This is the actionable read.
Pending Sweep at a known structural level (S/R, supply/demand) — useful as a "watch for the cluster" warning. If the cluster confirms, you have a high-conviction reversal at a structural location.
In persistent trends the failed-sweep rate climbs — that is the script telling you the regime does not currently favour sweep-and-reverse setups; stand aside or use the script in the trend direction only.
Suggested settings
Defaults (pivot lookback 8, wick ATR 0.8, body ratio 0.35, cluster window 5) are tuned for 15m–1H on liquid markets. For scalping (1m–5m), drop pivot lookback to 4 and cluster window to 3. For HTF macro reads (4H+), raise pivot lookback to 12–20 and cluster window to 8. The strict-threshold wick filters (0.8 ATR + 35%) are intentionally institutional — loosen for less liquid instruments.
Originality
The implementation — the five-condition strict sweep gate, the rolling minor-pivot cache with age and scan-depth filters, the three-condition cluster confirmation, the cluster-strength badge calculation, the pending → confirmed → failed state machine, the wick-level highlight render, the plotcandle override for confirming bars, the rolling confirmation-rate metric, and the session-reset counter — is JOAT-original. No third-party code reused. The "sweep + reaction" pattern is well-known to professional tape readers; the strict double-gate implementation is built specifically for chart-based Pine data.
Limitations
A confirmed SAC requires the cluster window to elapse — by definition the signal carries the cluster window bars of lag relative to the sweep. This is intentional; the cluster is what makes the signal meaningful. Failed sweeps are expected — the confirmation rate metric is there for you to see and tune accordingly. The script is structure-aware (uses real pivots) but does not know about HTF structure; combine with a higher-timeframe S/R indicator for best fit.
—
—
-made with passion by jackofalltrades
Penunjuk

Low-Lag Strength OscillatorLow-Lag Strength Oscillator
What this script does
LLSO is a bounded 0–100 momentum oscillator in the relative-strength family. It measures the balance between up-strength and down-strength in price, but smooths each side with a low-lag two-pole low-pass filter instead of the rolling/exponential average a classic strength index uses. The result keeps the familiar overbought/oversold behaviour and the 50 balance line, but turns several bars earlier — better measurement of the same momentum, not a different concept bolted on.
Why these components are combined (mashup justification)
This is not several indicators shown side by side. There is exactly one plotted value — the smoothed strength oscillator. Everything else is a decision-support layer built on that single value, and each layer answers one specific question about the same oscillator:
The low-lag smoother is the core. A short EMA reduces lag but overshoots and adds noise; a long average is smooth but late. The two-pole low-pass filter removes lag in the pass band without the overshoot, so the up/down strength legs are both responsive and stable. This is what makes the oscillator usable for early reads.
Divergence compares price pivots to oscillator pivots. Because the oscillator is a strength reading, a higher price high against a lower oscillator high is fading strength — information that the line alone doesn't make explicit. Regular and hidden divergences are detected from confirmed pivots only.
Reversal dots mark the moment the line turns back from inside the overbought/oversold bands — a context cue about where in the range the turn happened, which a bare line forces you to eyeball.
The calibration harness is the reason the rest is trustworthy. It logs every signal the oscillator produces and, a fixed horizon later, checks whether price actually moved at least k×ATR in the signal's direction — then reports Hit %, the unconditional Base %, and the Edge (Hit − Base). It scores the oscillator's own output against reality.
These belong in one script because they all operate on, and report about, the same single oscillator. Splitting them into separate studies would mean re-deriving the oscillator three times and losing the shared pivot/threshold context that ties them together.
What makes it original
Two things. First, the strength index is rebuilt on a low-lag low-pass smoother rather than the conventional average, which changes its timing without changing its bounded, mean-reverting character. Second — and more importantly — most oscillators emit signals and never tell you whether those signals lead anywhere. LLSO carries a built-in honesty layer: the calibration harness shows the realized hit rate of its own signals against the base rate on your instrument and timeframe. If the Edge sits near zero, the script says so plainly. That measurement-first design, not the oscillator alone, is the contribution.
How to use it
Add to a chart. Defaults target intraday index futures (e.g. NSE NIFTY); for other instruments simply change the chart, or set the Price / High / Low source inputs (group 01) to retarget the engine — you can even feed it another indicator's plot.
Read the line: green above the 50 balance line = net up-strength, red below = net down-strength; the gradient fill and color saturation scale with conviction (distance from 50). The dashed bands mark overbought/oversold.
Use divergences as early warning of fading strength and reversal dots as in-band turn cues — points to investigate, not automatic trades.
Read the Edge row in the panel before trusting signals. A positive Edge means the signal preceded a forward move more often than chance on this symbol/timeframe; near zero means it didn't. The panel shows "warming" until enough samples accumulate.
The smoother period, OB/OS levels, divergence pivots, and the calibration horizon/threshold are all configurable.
Limitations
Statistics are in-sample, close-to-close, without costs — a study aid, not a backtest. They describe past behaviour on loaded history, not a forward guarantee.
Lower lag is better measurement, not an edge; an earlier turn is still wrong if the turn leads nowhere.
Divergence prints a few bars after the pivot it confirms — that lag is inherent to honest, non-repainting pivot detection.
This is an analytical oscillator. It issues no automated buy/sell instructions and is not a strategy.
Concept credit
The low-lag two-pole low-pass smoother and the strength-index reformulation are based on the published work of John F. Ehlers (Technical Analysis of Stocks & Commodities, 2024).
The Relative Strength Index that this oscillator generalizes is by J. Welles Wilder (New Concepts in Technical Trading Systems, 1978).
The implementation, the calibration harness, the divergence/reversal layers and the packaging are original.
Disclaimer
For research and educational purposes only. This script is not financial advice, not a recommendation, and not a guarantee of future results. Indicators describe price behaviour; they do not predict the future. Trading carries risk of loss. Test on out-of-sample data and make your own decisions. The author accepts no liability for any use of this script. Penunjuk

Efficiency Divergence OscillatorEfficiency Divergence Oscillator
## Overview
The Efficiency Divergence Oscillator turns the **signed efficiency ratio** - net price displacement divided by the total path price actually travelled - into a standardized, bounded oscillator, and then looks for **divergence between price and the efficiency of its travel**. The idea it tests: when price makes a new extreme but reaches it on an increasingly choppy, inefficient path, the move is losing conviction.
It is a single-pane oscillator. It needs no external data and no volume. Every data input is user-configurable, so it runs on any symbol, asset class or timeframe, in any market and on any timeframe. Defaults target NSE NIFTY index futures on intraday charts.
## What it plots
- A z-scored **efficiency oscillator** (clean advance = up, clean decline = down, choppy travel = near zero), with a glow line and sigma-based overbought/oversold levels.
- **Extreme-zone bands** (default +/-3 sigma) with a gradient fill that deepens toward the edge.
- **Divergence lines and labels** on the oscillator - regular (reversal) and hidden (continuation), in two colors.
- **In-band reversal dots** where the oscillator turns inside an extreme zone.
- Optional **price-pane marks** at the confirmation bar (all generated by this one indicator).
- A **background-adaptive status dashboard** (oscillator value in sigma, zone, last divergence, last reversal, signed efficiency in %).
## Why these components are combined (mashup rationale)
This script combines a **derived measure**, a **normalization stage**, a **divergence engine** and a **reversal read**, because each answers a question the others cannot and none is useful here alone:
1. **Signed efficiency ratio (path quality).** Momentum tells you how FAR price moved; it does not tell you how DIRECTLY it got there. The signed efficiency ratio = (price - price ) / sum(|price - price |, len), a value in +/-1 that is positive for efficient up-moves and negative for efficient down-moves. It isolates path quality - a dimension a magnitude-only momentum oscillator cannot show.
2. **Standardization (rolling z-score).** efficiency differs in scale across instruments. The z-score expresses it in standard-deviation units, so "overbought/oversold" and the extreme bands mean the same thing on NIFTY, on a commodity future, or on a crypto instrument. Without this step the divergence thresholds would not transfer between symbols.
3. **Divergence engine.** The original payload is reading **price-versus-efficiency disagreement at confirmed pivots**. The engine pairs each new price pivot with the oscillator value, then requires: a genuine new price extreme; the measure failing to confirm it; a minimum oscillator gap scaled to the oscillator own stdev; the two pivots within a maximum bar distance; and optionally an overbought/oversold reading at the pivot. These gates make the combination produce signal rather than noise.
4. **Reversal read.** Independently, the engine flags oscillator turns that occur inside the extreme bands - a complementary exhaustion cue.
Together the components form one pipeline: **build the signal -> make it comparable (z-score) -> surface where price and that signal disagree (divergence) and where it exhausts (reversal).** Each is incomplete alone.
## How it works (method)
efficiency = (price - price ) / sum(abs(price - price ), len) over the efficiency window, a value in +/-1; this is standardized with a rolling z-score to the oscillator.
Regular and hidden divergence are detected from confirmed pivothigh/pivotlow pivots and filtered by the gates above; reversals are oscillator pivots that print inside the extreme bands. Pivots confirm a few bars after they occur, so a printed signal does not repaint. The confirmation lag equals the pivot length.
## How to use it
1. Add the indicator on any chart; no special data is required.
2. Read divergence as **context, not a trigger**: a bearish divergence (price higher high, efficiency lower high) says the advance is getting choppier; a bullish divergence says the decline is. Confirm with your own structure, levels and risk process.
3. Tune the **pivot length**, **max gap** and **min oscillator gap** to your timeframe; raise them for fewer, cleaner signals.
## Originality
This is an original implementation - not a efficiency line and not a generic divergence script, but the specific combination of efficiency, sigma-standardization that makes the read portable across markets, a multi-gate divergence engine (magnitude + distance + extreme-zone), hidden-divergence and in-band reversal detection, and a background-adaptive dashboard. The code is written from scratch; helper functions use only their arguments and built-ins.
## Credits
The Efficiency Ratio was introduced by **Perry J. Kaufman**. **Price/oscillator divergence** is a long-established, publicly documented technical-analysis technique. This script is not affiliated with, nor endorsed by, any third party.
## Notes / limitations
- Efficiency is a path-quality read, not a direction call; in strong clean trends it stays elevated without diverging.
- Divergence is descriptive context, never a guarantee of reversal.
- Confirmation lags each pivot by the pivot length.
## Disclaimer
Research and educational tool only. NOT financial advice and no guarantee of profitability or accuracy. Indicators describe past behaviour; they do not predict the future. Trading carries risk of loss. Test out-of-sample and make your own decisions. The author accepts no liability for any use of this script.
Penunjuk

Adaptive Momentum Strength Score (AMSS)There is a specific kind of frustration that every serious trader knows.
The setup looks right. The candle closes with conviction. The oscillator confirms. You enter and the move immediately stalls, reverses, or dissolves into noise. Later you realize the volume was weak, volatility never truly expanded, or directional pressure had already started fading before the entry.
That frustration is not a discipline problem. It is an information problem.
Most momentum indicators measure one piece of the puzzle. RSI measures price velocity. Volume indicators measure participation. Bollinger Bands measure volatility state. Each tells part of the story. The Adaptive Momentum Strength Score was built on the conviction that momentum quality can only be evaluated meaningfully when several complementary market forces are read together, not after the fact, but simultaneously, on every bar.
The Core Framework
The purpose of the composite score is straightforward: to answer not just whether price is moving, but whether the move is supported by the conditions that tend to give momentum its staying power.
The score is normalized between 0 and 100 and built from three independent components. The first measures candle impulse relative to ATR not raw candle size, but how decisive the current bar is in the context of what normal looks like for this asset right now. The second measures volume participation by comparing current volume against its moving average, distinguishing genuine momentum expansion from the kind of low-participation drift that precedes failed breakouts far more often than it precedes continuation. The third measures volatility expansion through Bollinger Band width relative to its own average, detecting the transition from compression into expansion as a market begins releasing stored energy.
Each component is independently normalized before combining. By default, volume participation carries the greatest weight of the three — a deliberate choice reflecting the observation that genuine participation tends to be the most reliable differentiator between momentum that follows through and momentum that fades. Candle impulse and volatility expansion carry equal secondary weight, acknowledging that decisive price movement and volatility expansion both contribute meaningfully to momentum quality without either being treated as a primary condition on its own. All weights remain fully adjustable for traders who prefer a different emphasis across different assets or timeframes.
What separates this framework from most traditional oscillators is that momentum strength, directional pressure, market regime, momentum acceleration, and signal confirmation are kept as independent layers that work together while remaining individually interpretable. The goal is not to compress everything into a single binary output but to provide a structured view of how momentum is developing and whether broader conditions are genuinely supportive.
Adaptive Thresholds
A composite score is only as useful as the threshold that determines when it becomes meaningful.
The indicator supports two threshold modes. Fixed mode works cleanly in stable trending environments where volatility expression is consistent. Adaptive mode the recommended default calculates the threshold dynamically using rolling score averages and standard deviation scaling, then clamps it within a defined range. As market character shifts, the threshold recalibrates automatically rather than forcing traders to manually adjust a static level every time volatility conditions change.
The practical consequence is worth understanding directly. In a static-threshold oscillator, a compression phase floods the chart with false crossovers while a genuine expansion phase can produce delayed or missed signals. The adaptive threshold adjusts to both conditions without intervention. The active level is always displayed as the orange reference line, there is never ambiguity about where the signal boundary sits.
The score is additionally classified into Weak, Moderate, and Strong states relative to the active threshold, allowing momentum quality to be evaluated quickly without relying on raw numerical values alone.
Directional Pressure
The score measures momentum magnitude. Direction is handled through a completely separate layer.
Directional bias is established through a two-part confirmation test on every bar. Price must sit on the correct side of a short-period directional EMA, and the average ATR-normalized candle direction over the recent lookback must clear a pressure threshold, meaning a single extended wick or isolated candle cannot flip the directional label on its own. The result is a three-state classification that updates in real time: Bullish, Bearish, or Neutral. This label colors the score line and feeds directly into the signal confirmation logic.
Regime Classification
Not all momentum signals carry equal weight. A score crossover during an expanding market is a categorically different event from the same crossover inside a compressed, coiling environment and treating them identically is one of the more common ways momentum-based approaches produce inconsistent results.
The indicator measures the range of the score over a lookback window and classifies conditions into three states. Compressed means the score has been operating within a narrow band, the market is coiling, energy may be building, and momentum signals in this state generally exhibit lower follow-through and greater variability, although strong expansions can emerge from prolonged compression. Balanced reflects normal trending or ranging conditions. Expanding means the score range has broken above the expansion threshold the market is releasing energy, and momentum signals carry stronger continuation characteristics during this state.
Regime classification can be applied as a filter to triangle signals or used purely as context within the dashboard.
Momentum Velocity
Knowing where the score is tells you the current momentum level. Knowing how fast it is changing tells you something more useful, where momentum is likely heading before price makes it obvious.
The velocity engine calculates the rate of change of the score relative to its own standard deviation, producing a normalized reading that classifies momentum as Accelerating, Decelerating, or Flat. When the score is rising rapidly against its recent volatility baseline, conditions are classified as Accelerating. When the score is fading even if it remains above the threshold the label shifts to Decelerating, and the score line renders at reduced opacity as a visual signal that underlying momentum may be exhausting before price visibly reacts.
For traders who have held into momentum reversals that showed no obvious price-level warning, this layer provides an early internal warning signal within the indicator's architecture that conditions are beginning to shift.
Two Signal Tiers
The indicator produces signals on two distinct levels, and the distinction between them is worth understanding precisely.
Threshold dots appear whenever the score crosses the active threshold while directional pressure is already aligned. They are intentionally sensitive as early directional momentum awareness signals indicating that conditions are beginning to strengthen, even though the broader filter stack may not yet be confirmed. Experienced traders use them to shift attention and begin evaluating whether a fuller setup is developing.
Triangle signals are the fully confirmed output. A triangle only appears when the score crosses the threshold, directional pressure agrees, and every enabled filter in the active gate stack also confirms simultaneously. This is not a smoothed version of the dot signal. It is a categorically different signal type representing the convergence of multiple independent conditions at the same moment.
The separation is deliberate. Dots keep traders informed of developing momentum. Triangles reserve the strongest visual output for the moments that genuinely earn it.
The Signal Gate Stack
Before any triangle reaches the chart it passes through up to four independent gates, stackable in any combination.
The current-timeframe EMA filter blocks signals running counter to local trend structure. The higher-timeframe EMA filter adds a structural second opinion from a broader timeframe, 4-hour by default with an option to use only confirmed closed bars to avoid incomplete higher-timeframe calculations. The regime filter restricts signals during compressed conditions or limits them to expanding phases only. The cooldown gate enforces a minimum bar gap between consecutive signals, suppressing the cluster of repeat triggers that commonly fire around a single momentum event and dilute signal quality.
The dashboard always displays exactly which gates are active. Traders never need to guess why a triangle did or did not appear, the filter logic is visible at all times.
Reading the Indicator: A Practical Workflow
1. Assess market regime first . Check the Info Table before anything else. Compressed conditions mean the score has been coiling in a tight range crossovers here often require greater selectivity, as follow-through tends to be less reliable until expansion begins, and participation should be approached more selectively. Expanding conditions deserve closer attention, as momentum signals generally carry stronger continuation characteristics during these phases.
2. Verify directional alignment. Confirm that the score line color and the Direction label in the dashboard match your intended trade direction. A technically valid score crossover against prevailing directional pressure is a lower-quality setup by design.
3. Watch for the threshold dot on the score pane . A small circle plots on the score line the moment momentum crosses the active threshold while directional pressure is already aligned. This is your early awareness signal. It means conditions are beginning to strengthen, but the broader confirmation stack may not yet be complete. Use it to shift attention to the price chart, not necessarily to trigger execution.
4. Wait for the triangle on the price chart . The triangle is the confirmed execution signal. It only appears when the score has crossed the threshold, directional pressure agrees, and every enabled gate in your active filter stack has confirmed simultaneously. Depending on your settings, this may include EMA alignment, regime validation, and cooldown logic. No triangle means at least one required condition has not been met, regardless of how the score looks in the pane below.
5. Check momentum velocity before entry. An Accelerating label at the point of the triangle adds meaningful weight to the setup. A Decelerating label on an otherwise valid triangle is a caution not necessarily a reason to avoid the trade, but a reminder that momentum quality may be less aggressive, follow-through may develop more gradually, or reversal risk may be beginning to increase.
6. Manage the trade with velocity as context, not as a standalone exit signal . If the score remains above or near the threshold but the line has dimmed signaling Decelerating momentum the move may be losing force even while price continues in the same direction. This does not automatically invalidate the trade or imply immediate exit. Instead, use velocity as an additional layer of context alongside price structure, trend conditions, and your existing risk-management framework.
What This Indicator Is Designed For
The Adaptive Momentum Strength Score is not a standalone trading system and does not attempt to be one. It is a momentum context engine — a structured framework for evaluating whether the conditions behind a price move reflect genuine strength and participation or whether they represent the kind of isolated, low-quality momentum that tends to produce less reliable continuation.
Every design decision in this script traces back to a single conviction: durable edge in trading does not come from reacting faster to a single signal. It comes from reading multiple independent market forces simultaneously and acting only when they converge. That is what this indicator was built to do and that is the only thing it claims to do well.
My Scripts/Indicators/Systems are for educational purposes only! Penunjuk

Artemis Wave Oscillator🟦 Artemis Wave Oscillator is a Pine v6 reimagination of the classical WaveTrend family, built on a Welford running-stdev channel and EMA-smoothed normalization. Unlike fixed-band WaveTrend variants that ship with hard-coded levels, the engine continuously rescales itself against its own dispersion — producing a momentum curve that stays perfectly bounded between visually consistent reversion bands on every asset and every timeframe, with no manual recalibration.
The indicator integrates six analytical layers — WaveTrend core, dynamic reversion bands, histogram momentum gauge, extremity reversion dots, regular + hidden divergence detection with a Smart AI Filter, and a theme-adaptive PRO dashboard — each operating independently and rendered on a single, clean oscillator panel.
🟦 HOW THE CORE ENGINE WORKS
**WaveTrend Channel**
Each bar, the engine builds an EMA-smoothed midline from the selected price aggregate over the Channel Length window. In parallel, a Welford single-pass running standard deviation measures the channel width — a numerically stable O(N) algorithm that updates the running mean and squared deviation simultaneously, preserving precision on long histories where naive sum-of-squares accumulators drift.
The raw wave is then computed as:
wave_raw = (src − chanMid) / chanDev × 100
This produces a z-score-like signal scaled to the ±100 range. Dividing by the running standard deviation normalizes the output regardless of asset volatility — BTC, EURUSD, SPY, and a small-cap stock all swing through the same band structure without parameter changes.
**EMA Smoothing**
The raw wave is then passed through an EMA of length Average Length to produce the visible `wave` line. This is the dominant responsiveness control — larger values produce a calmer curve with fewer reversion-zone touches.
**Signal Line**
An SMA of the wave (Signal Length) builds the trigger line. Crossovers between the wave and signal line mark momentum regime changes — the same convention used by classical MACD and Stochastic.
**Histogram**
The wave − signal delta is rendered as a filled area. Two opacity tiers distinguish rising momentum (brighter) from fading momentum (dimmer), so the eye picks up acceleration vs. deceleration at a glance.
**Source Selector**
Nine price aggregates are available:
| Source | Formula | Use case |
|---|---|---|
| Open | open | Open-of-bar bias |
| High | high | Top-of-range tracking |
| Low | low | Bottom-of-range tracking |
| Close | close | Standard, fastest reaction |
| OC2 | (open + close) / 2 | Body midpoint |
| HL2 | (high + low) / 2 | Body-independent midpoint |
| HLC3 | (high + low + close) / 3 | Typical mean — default |
| OHLC4 | (open + high + low + close) / 4 | Smoothest |
| HLCC4 | (high + low + 2×close) / 4 | Close-weighted |
🟦 REVERSION BANDS
The user picks a single Reversion Threshold (T) — the distance from zero (in normalized wave units) beyond which the wave is considered overbought (positive side) or oversold (negative side). Three proportional tiers render automatically:
| Tier | Level | Visual |
|---|---|---|
| Inner | ±T | Outer ring of the gradient fill |
| Middle | ±T × 1.25 | Boundary between outer ring and inner extreme |
| Outer | ±T × 1.5 | Hard outer boundary of the gradient fill |
Because the bands are derived from T, they always wrap the threshold no matter how the user tunes it. A trader scaling T from 80 (volatile assets) to 150 (trending assets) keeps the visual context intact without retuning the band levels.
The Reversion Threshold itself drives three downstream features:
- Extremity Dot triggers
- The "Extremities" bar-coloring mode
- The Dashboard Zone tag (OB / MID / OS)
🟦 EXTREMITY DOTS
OB / OS reversion markers — small dual-layer dots that fire when the wave crosses the signal line beyond the Reversion Threshold:
- **OS dot** (bull theme color) → wave crossed UP past −T
- **OB dot** (bear theme color) → wave crossed DOWN past +T
These are the highest-conviction mean-reversion triggers in the script. The dots use a two-track rendering — a pixel-perfect glow + core visual via `plot.style_circles`, paired with an invisible `label.style_circle` carrying a rich tooltip. Hovering on a dot surfaces:
- Direction (Crossed UP / DOWN through Signal)
- Active zone (Below −T / Above +T)
- Current wave value
- Current signal value
- Trading interpretation (mean-reversion long / short opportunity)
🟦 DIVERGENCE DETECTION
Pivots are calculated using `ta.pivothigh` and `ta.pivotlow` with an arm of `Channel Length / 2`. All divergence results appear `Channel Length / 2` bars late — this is standard Pine Script pivot behavior, not a bug.
**Four divergence types:**
| Type | Price | Wave | Signal |
|---|---|---|---|
| Regular Bull (D▲) | Lower Low | Higher Low | Potential reversal up |
| Regular Bear (D▼) | Higher High | Lower High | Potential reversal down |
| Hidden Bull (H▲) | Higher Low | Lower Low | Uptrend continuation |
| Hidden Bear (H▼) | Lower High | Higher High | Downtrend continuation |
Regular divergence uses solid lines (width 2). Hidden divergence uses dashed lines (width 1) — the thinner, dashed style makes the continuation signal visually quieter than the reversal signal, matching their respective conviction tiers. Labels use bracketed symbols (D▲ / D▼ / H▲ / H▼) and each carries a tooltip-rich hover with price + wave context.
**Smart Divergence Filter (AI)**
An optional pre-filter that rejects low-quality divergences before they render. Three independent gates:
1. **Min Wave Swing** — minimum oscillator swing between the two pivots (default: 5 units). Drops noise-level differences where the wave barely moved between pivots.
2. **Min Price Swing (%)** — minimum price swing between pivots as a percentage of the recent `Channel Length × 4` high-low range (default: 0.3%). Drops divergences where price barely moved relative to recent volatility.
3. **Zone Confirmation** — the wave at the current pivot must sit in the matching reversion half:
- Bullish divergence → wave at LL pivot ≤ −T × 0.5 (oversold half)
- Bearish divergence → wave at HH pivot ≥ +T × 0.5 (overbought half)
This encodes the classical "best divergences form at extremes" rule using the wave value itself as the gate — no MFI or volume input required.
When the master toggle is OFF (default), all detected divergences render. When ON, only divergences that clear all three gates survive. The filter applies identically to both chart rendering and alert conditions — no mismatch between visual and alert signals.
🟦 HISTOGRAM
The wave − signal histogram is rendered as a filled area between the histogram value and the zero line. Two opacity tiers per side:
| State | Color | Opacity |
|---|---|---|
| Bull, rising | thBull | Rising Opacity (default 60) |
| Bull, fading | thBull | Fading Opacity (default 40) |
| Bear, rising | thBear | Rising Opacity (default 60) |
| Bear, fading | thBear | Fading Opacity (default 40) |
Rising bars are the most actionable visual cue — they mark momentum that is accelerating in the active direction. Fading bars indicate momentum stalling.
🟦 BAR COLORING
Five mutually exclusive modes apply a wave-driven color to every price bar on the chart:
| Mode | Behavior |
|---|---|
| None | Leave bars untouched (default) |
| Midline Cross | Bull above zero, bear below zero |
| Extremities | Bull beyond +T, bear beyond −T, neutral elsewhere |
| Reversions | Bull on OS dot trigger, bear on OB dot trigger |
| Slope | Bull when wave > signal, bear when wave < signal |
Colors are pulled from the active theme — no per-mode color picker needed.
🟦 DASHBOARD
A compact 2-column, 7-row data panel renders on the last bar when enabled. Every value derives from variables already computed upstream, so the dashboard adds zero overhead until the final bar.
| Row | Left | Right |
|---|---|---|
| Header | Artemis Wave | ▲ BULL / ▼ BEAR / ■ NEUTRAL |
| Wave | Wave | Current value + trend arrow (▲ ▼ ■) |
| Signal | Signal | Current SMA trigger value |
| Strength | Strength | 10-block monospace bar gauge |
| Zone | Zone | OB / MID / OS tag |
| Div | Div | Most recent divergence within last 50 bars (▲ REG / ▼ REG / ▲ HID / ▼ HID / —) |
| Slope | Slope | ▲ UP / ▼ DOWN / ■ FLAT |
The strength gauge normalizes `|wave − signal|` against 50 (typical mid-amplitude swing) and buckets the result into 10 monospace blocks (`█` filled, `░` empty), giving an at-a-glance read of crossover conviction.
**Theme-Adaptive Chrome**
The dashboard auto-inverts its layout based on the active theme:
- **Dark themes** (Tropic, Amber, Pastel, Cyber, Helios, Electric, Candy, Bloomberg, Solar, Royal): header and footer use a faint `thBull` tint, middle rows stay solid dark, text uses full-saturation `thBull`. Border uses `thBull` at 20% transparency for strong theme presence.
- **Light themes** (Midnight, Graphite): backgrounds flip to white, text stays `thBull` (which is itself dark on these themes), border uses `thBull` at 40% transparency.
This guarantees text legibility against every palette without per-theme manual tuning.
**Position & Size**
Six anchor slots (Top/Middle/Bottom × Left/Right) and four text sizes (Tiny / Small / Normal / Large).
🟦 COLOR THEMES
Twelve cohesive palettes, each resolving to four axis colors:
| Theme | Character | Bull | Bear |
|---|---|---|---|
| Tropic | Cyan steel + deep orange | #00bcd4 | #ff6d00 |
| Amber | Warm amber + indigo blue | #ff9800 | #e53935 |
| Pastel | Sky blue + soft lavender | #4fc3f7 | #9575cd |
| Cyber | Neon lime + hot crimson | #00e676 | #ff1744 |
| Helios | Bright gold + scarlet | #ffd600 | #ef5350 |
| Electric | Electric aqua + magenta | #00e5ff | #e040fb |
| Candy | Neon green + hot pink | #69F0AE | #FF4081 |
| Bloomberg | Terminal orange + cyan | #ff8c00 | #00b0ff |
| Solar | Solarized olive + crimson | #859900 | #dc322f |
| Royal | Imperial gold + deep purple | #ffd700 | #6a0dad |
| Midnight | Deep navy + dark crimson | #0d47a1 | #b71c1c |
| Graphite | Near-black + silver grey | #1a1a1a | #757575 |
All four color roles (bull / bear / neutral / signal) change simultaneously when the theme changes. The whole script reads through these four variables — nothing below the resolver references a raw hex literal, so a single dropdown selection drives every plot, fill, dot, divergence line, dashboard cell and border.
🟦 ALERT SYSTEM
Ten alert conditions, all using `alert.freq_once_per_bar_close`:
| Alert | Condition |
|---|---|
| OS Reversion | Wave crossed UP through signal while wave < −T |
| OB Reversion | Wave crossed DOWN through signal while wave > +T |
| Regular Divergence | D▲ or D▼ detected (respects Smart Filter) |
| Hidden Divergence | H▲ or H▼ detected (respects Smart Filter) |
| Bullish Trend | Wave crossed above the midline (zero) |
| Bearish Trend | Wave crossed below the midline (zero) |
| Bullish Swing | Wave × signal upward cross, regardless of zone |
| Bearish Swing | Wave × signal downward cross, regardless of zone |
Each alert fires through `alert()` so the message body carries live context — direction, current wave value, and the threshold that triggered. Divergence alerts respect the Smart Divergence Filter — if the filter is ON and a divergence is rejected visually, the alert will also not fire.
🟦 SETTINGS REFERENCE
**WaveTrend Core**
- Source — 9 price aggregates. Default: HLC3
- Channel Length — EMA midline + Welford stdev lookback. Default: 10
- Average Length — EMA smoothing of the normalized wave. Default: 21
- Signal Length — SMA smoothing of the wave to build the trigger. Default: 4
**Reversion Bands**
- Reversion Threshold — 50–200, step 5. Default: 100
- Show Band Fills — Toggle. Default: ON
- Band Opacity — 0–100. Default: 30
**Histogram**
- Show Histogram — Toggle. Default: ON
- Rising Opacity — Default: 60
- Fading Opacity — Default: 40
**Extremity Dots**
- Show Extremity Dots — Toggle. Default: ON
**Divergence**
- Regular Divergence — Toggle. Default: ON
- Regular Opacity — Default: 80
- Hidden Divergence — Toggle. Default: ON
- Hidden Opacity — Default: 80
- Label Size — Tiny / Small / Normal / Large. Default: Tiny
- Smart Divergence Filter (AI) — Master toggle. Default: OFF
- Min Wave Swing — Default: 5.0
- Min Price Swing (%) — Default: 0.3%
- Require Zone Confirmation — Default: ON
**Bar Coloring**
- Bar Color Mode — None / Midline Cross / Extremities / Reversions / Slope. Default: None
**Dashboard**
- Show Dashboard — Toggle. Default: ON
- Panel Position — 6 anchor slots. Default: Middle Right
- Panel Text Size — Tiny / Small / Normal / Large. Default: Small
**Alerts**
- OS Reversion — Default: ON
- OB Reversion — Default: ON
- Regular Divergence — Default: ON
- Hidden Divergence — Default: OFF
- Bullish Trend — Default: ON
- Bearish Trend — Default: ON
- Bullish Swing — Default: OFF
- Bearish Swing — Default: OFF
🟦 COMPATIBILITY
Works on all asset classes and all timeframes in TradingView Pine Script v6.
- Crypto: Spot, futures, perpetual contracts
- Forex: All pairs
- Equities: Stocks, ETFs, indices
- Commodities: Metals, energy, agriculture
- Timeframes: 1m through Monthly
The Welford running standard deviation normalizes the wave against its own dispersion, making the engine fully volatility-agnostic. The same default settings work on a 5-second BTC chart and a weekly index chart without retuning.
🟦 TECHNICAL NOTES
- Pine Script v6
- `max_lines_count = 500`, `max_labels_count = 500` (divergence drawings + extremity dot hover labels)
- No repainting — all values calculated on bar close. Pivot-based divergence results appear `Channel Length / 2` bars late by design
- WaveTrend engine intentionally mirrors EliCobra's original Enhanced WaveTrend formulation — the value added by Artemis Wave is in the Pine v6 idioms, the dynamic band scaling, the divergence engine, the Smart Filter, the theme system, and the dashboard, not in altering the well-tested core curve
- UDT fields declared without defaults to comply with Pine v6's compile-time-literal requirement; objects constructed via `Bar.new(...)` and `WaveReading.new(...)`
- `var int x = int(na)` pattern used for safe persistent integer state (pivot bar indices)
- Reversion-band anchors rendered as hidden `plot()`s rather than `hline()`s — `hline()` only accepts compile-time constants, but the band levels are series values driven by the user-tunable Reversion Threshold
- Extremity Dots use a dual-track rendering: `plot.style_circles` for the pixel-perfect visual, plus a parallel invisible `label.style_circle` carrying the hover tooltip (since `plot()` does not support the `tooltip` argument)
🟦 DISCLAIMER
This indicator is provided for educational and informational purposes only. It does not constitute financial advice. Past performance does not guarantee future results. Always conduct your own analysis and apply proper risk management. Penunjuk

Normalized FX Majors Matrix FDP (8 Currencies)### Overview
The **Normalized FX Majors Matrix** is a premium Currency Strength Index designed to measure the absolute performance of the 8 major global currencies (USD, EUR, GBP, JPY, CHF, CAD, AUD, NZD).
Instead of looking at isolated currency pairs, this indicator processes a flawless mathematically symmetrical matrix of all 28 underlying cross-rates, extracting the true geometric equally-weighted strength of each individual currency.
### How It Works
1. **Mathematical Symmetry:** The indicator requests 28 major cross-rates to build an unbiased basket. Each currency is measured accurately against 7 other counterparties.
2. **Log Returns & Smoothing:** It calculates the logarithmic returns of each pair to handle volatility scaling properly, with an optional EMA smoothing parameter to filter out short-term market noise.
3. **Base 100 Rebase:** All 8 lines are re-anchored to a value of 100 at the beginning of the user-defined lookback window (`Normalization Window`). This allows for an instant visual comparison of cumulative returns.
4. **Dynamic Leaderboard:** A real-time dashboard ranks the currencies from strongest to weakest, color-coded dynamically to match the plot lines.
### How to Trade with It
- **Trend Following (Strong vs. Weak):** Look at the ranking table. Pair the strongest currency at the top with the weakest currency at the bottom (e.g., if USD is top and JPY is bottom, look for Long opportunities on USDJPY).
- **Crossover Signals:** When a currency line crosses above another, it indicates a shifting global capital flow.
- **Breakout Confirmation:** Use this matrix to confirm if a chart breakout is supported by true individual currency strength or if it is just a false move driven by the counter-currency. Penunjuk

RSI Optimized with Smoothings & Divergence (RSI Optimized)This indicator enhances the classic RSI by adding multiple smoothing layers, a dynamic background based on the average of six smoothings, an info table, and regular divergence detection.
🔹 **Core RSI**
Standard RSI calculation (Wilder) with fully adjustable length and source. Overbought/oversold levels (70/30) are highlighted with a gradient fill.
🔹 **Smoothing MA**
Optionally apply a moving average to the RSI line (SMA, EMA, SMMA, WMA, VWMA). The "SMA + Bollinger Bands" mode adds Bollinger Bands around the smoothed RSI.
🔹 **Six Smoothings (instead of a ribbon)**
Six independent moving averages of the RSI (customizable type and lengths) are plotted. Useful to visualise multiple timeframes or sensitivities at once.
🔹 **Background color (RSI vs Avg of 6 Smoothings)**
Compares the RSI value to the simple average of the six smoothings. Green background when RSI > average (bullish bias), red when RSI < average (bearish bias).
🔹 **Info Table**
Displays in real time:
- Current RSI value (color‑coded by overbought/oversold)
- Average of the six smoothings
- Ratio = (RSI + Avg)/2
- Trend direction (based on RSI vs average)
- Zone (Oversold / Overbought / Bull / Bear / Neutral)
- Smooth trend (fast smoothing 1 vs upper smoothing 6)
🔹 **Regular Divergences**
Detects regular bullish and bearish divergences between price and RSI. Pivot lookback is fixed to 5 bars left/right. An alert is available for each divergence type.
🔹 **All options are configurable via the Settings tab** – from lengths, colors, smoothing types to enabling/disabling the table or divergences.
📌 **How to use**
- Use the six smoothings to identify trend alignment (e.g., all above 50 = strong uptrend).
- The background turns green when RSI stays above the average of all smoothings.
- Watch for divergence signals (labelled "Bull" / "Bear") for potential reversals.
- The info table gives a quick snapshot of momentum and trend state.
This tool is ideal for traders who want a richer RSI experience without cluttering the chart.
NOTE PERSO :THANK TRADING VIEW FOR YOU WORKS , YOU ARE BEST !!! & ENJOY TEAM TRADING VIEW MAKE PEACE NOT WARS !!! STAY TUNED !! Penunjuk

Elaris RSI Pro [Divergence]Elaris RSI Pro is a professional-grade RSI momentum and divergence indicator built for traders who want cleaner market structure signals, smarter divergence detection, and a more refined trading workflow.
The indicator combines a responsive RSI engine with advanced bullish and bearish divergence detection to help identify potential reversals, continuation setups, and momentum shifts across all market conditions.
Designed with a clean visual experience and optimized performance in mind, Elaris RSI Pro delivers clear signals without unnecessary chart clutter, making it suitable for scalpers, swing traders, and intraday traders alike.
Key Features:
• Regular Bullish & Bearish Divergence Detection
• Hidden Bullish & Bearish Divergence Detection
• Configurable Pivot Detection Engine
• Adjustable Minimum & Maximum Pivot Distance Filters
• Dynamic RSI Momentum Coloring
• Signal Smoothing with EMA Filter
• Overbought / Oversold Zone Visualization
• Optional Divergence Lines & Labels
• Optional Pivot Markers for Advanced Analysis
• Professional Alert Conditions
• Non-Repainting Confirmed Pivot Logic
• Optimized Object Management for Better Performance
Elaris RSI Pro is built using confirmed pivot logic, meaning divergence signals are generated only after pivot confirmation to reduce repainting behavior and improve signal reliability.
The indicator is highly customizable, allowing traders to adapt the sensitivity and visual behavior to different trading styles, markets, and timeframes.
Works well with:
• Market Structure Analysis
• Trend Following Systems
• Support & Resistance Trading
• Smart Money Concepts (SMC)
• Liquidity Sweep Confirmation
• Multi-Timeframe Confluence Strategies
Best used alongside proper risk management and confirmation tools.
Non-Repainting:
This indicator uses confirmed pivot-based calculations. Signals appear only after pivot confirmation and do not repaint historically after confirmation. Penunjuk

Currency Strength MeterCurrency Strength Meter — 8 Majors
Track real-time relative strength across the 8 major currencies in a single panel: USD, EUR, JPY, GBP, AUD, CHF, CAD and NZD. Each currency is benchmarked against the average performance of the group, so you can instantly see which currencies are bid and which are offered — without flipping between a dozen FX charts.
What it shows
Each line represents a currency's strength relative to the basket average, expressed in basis points (bps) of percentage move since the anchor reset. A currency above the zero line is outperforming the average, below zero it's underperforming. The relative ranking matters more than the absolute values — if USD is at +40 bps and JPY is at -60 bps, you're looking at a 100 bps gap of relative momentum that typically shows up in USD/JPY price action.
The math: the script pulls EURUSD, GBPUSD, AUDUSD, NZDUSD, USDJPY, USDCHF, USDCAD, computes each currency's percentage move since the anchor (inverted for the quote currencies), then subtracts the basket mean so all 8 strengths sum to zero. This removes the USD bias inherent to most "strength meters" that just measure pairs against the dollar.
Why it matters
Currency strength meters cut through the noise of individual pair charts. When you see the same pattern repeated across multiple pairs (EUR weak vs USD, EUR weak vs JPY, EUR weak vs GBP), it's no longer about one pair — it's about EUR itself. This indicator surfaces that signal in one glance.
Particularly useful for:
Pair selection — long the strongest, short the weakest for maximum dispersion
Avoiding chop — when two currencies are clustered near zero, their cross is likely to range
Spotting regime shifts when a currency suddenly breaks away from the pack
Confirming or fading reactions to central bank decisions, CPI, NFP across the FX complex
Filtering out fake breakouts on individual pairs that aren't backed by broader strength
Viewport-following labels (the killer feature)
Unlike most strength meters where labels stick to the latest bar, the labels here follow the right edge of your visible viewport . Scroll back in history and the labels update to show the strength values at that point in time — not at the current bar. This lets you study historical setups with the same readability as the live state, no zooming and hovering required.
Labels are automatically positioned to avoid overlap when multiple currencies are clustered, with configurable spacing (auto or manual).
Anchor modes
Daily : reset at the start of each trading day (default — best for intraday)
Weekly : reset at the start of each week (best for swing trading)
Session (Lookback) : rolling N-bar window for continuous measurement (best for context-free relative strength)
Settings
Reset anchor : Daily, Weekly, or rolling Session lookback
EMA smoothing : optional smoothing to filter intrabar noise (1 = raw, no smoothing)
Line width : 1 to 4
Currency toggles : show or hide each of the 8 currencies independently
Custom colors : each currency line can be recolored
Label gap : auto (scales with range) or manual (fixed bps gap)
Zero line : visual reference for relative strength sign
Recommended setup
Apply on any forex pair, on a 15m to 1h timeframe for intraday work, or 4h to daily for swing analysis. The indicator uses the chart's symbol only as a time base — the strength calculation is independent of which pair you're viewing.
Best paired with the underlying price action: when a currency breaks out on the strength meter, look at its strongest/weakest counterpart to find the best pair to trade the move.
Notes
Strength is measured against the 7 majors using direct or inverted USD crosses. JPY, CHF and CAD are inverted (since they're quote currencies vs USD in their major pair), so a rising USDJPY shows as JPY weakness, not strength. The mean-subtraction step normalizes the basket so all 8 values sum to zero, giving you true relative momentum rather than dollar-skewed readings.
Feedback and suggestions welcome. Penunjuk

Crypto Beta Leadership Ladder [AGPro Series]Crypto Beta Leadership Ladder
🧠 Core Idea
When crypto risk appetite changes, who is actually leading the move: BTC, ETH, broad alt beta, or the active chart itself?
📌 Overview / What it does
Crypto Beta Leadership Ladder is a market leadership and relative beta map for crypto traders.
The script compares BTC, ETH, broad altcoin market-cap behavior, high-beta altcoin breadth, BTC dominance, ETH dominance, and the active chart into a single leadership framework.
It produces a right-side leadership ladder, a live leadership path, selective transition labels, optional compact markers, and an AG Pro dashboard panel. It does not predict price, automate trades, or tell users what to buy or sell.
🎯 Purpose & Design Philosophy
This script was built to solve a common crypto-market problem: price may move, but leadership often rotates underneath the move.
Sometimes BTC is leading defensively. Sometimes ETH begins to participate. Sometimes broad alt beta expands. Sometimes the active chart is outperforming the market. These are different market conditions, and they should not be interpreted the same way.
The goal is to help traders read crypto leadership quality instead of reacting only to candle direction.
⚡ Why This Script Is Different
Most tools focus on one symbol, one moving average, one dominance chart, or one relative-strength line.
This script does NOT draw liquidation zones, funding stress maps, stablecoin liquidity pulses, basis corridors, or open-interest commitment zones.
Instead, it builds a leadership ladder from multiple crypto-market proxies and ranks BTC, ETH, alt beta, and chart beta as a live market hierarchy.
⚙️ Methodology
1. Context Detection
The script reads BTC, ETH, TOTAL2, TOTAL3, BTC dominance, and ETH dominance sources.
2. Relative Beta Mapping
It compares performance, dominance change, chart beta versus BTC, and altcoin breadth versus BTC.
3. Leadership Ranking
BTC, ETH, ALT, and CHART scores are ranked into a leadership stack. The gap between the first and second rank controls whether leadership is clear or split.
4. Visual Output
The script displays a right-side rank ladder, a leadership path, selective event labels, optional rank markers, and a compact dashboard.
🗺️ How to Read the Chart
The top ladder rail shows the current leadership rank.
The middle rail shows the second rank and whether leadership is close or split.
The lower rail shows the third rank and the active beta spread context.
The leadership path moves with the market and changes color by active leadership state.
Event labels highlight major transitions such as BTC Shield Lead, ETH Leadership, Alt Beta Lead, Chart Beta Expansion, or Split Leadership.
The panel summarizes leader, score, edge, BTC relative change, ETH relative change, alt beta, chart beta, dominance shift, persistence, state, and grade.
🚦 Signals & States
• BTC Leadership → BTC is leading defensively versus the broader crypto market
• ETH Leadership → ETH participation is stronger than BTC and broad alt context
• Alt Beta Lead → high-beta altcoin breadth is leading the crypto market
• Chart Beta Expansion → the active chart is outperforming BTC with expanding beta
• Split Leadership → leadership is mixed and no single group has clear control
• Balanced Leadership → leadership is present but not strong enough to be dominant
• Data Missing → one or more reference sources are unavailable
🔔 Alerts Logic
Alerts can be enabled for BTC Leadership, ETH Leadership, Alt Beta Leadership, Chart Beta Expansion, and Split Leadership.
Alerts trigger when the relevant state becomes active and the leadership state changes.
Alerts are attention markers only. They are not trade instructions.
🧩 Confluence Logic
The ladder becomes more meaningful when rank edge, dominance shift, chart trend, and persistence align.
For example, an Alt Beta Lead state with positive chart beta and falling BTC dominance suggests a stronger risk-on leadership environment than a single isolated altcoin move.
📊 When to Use
• Crypto market rotation analysis
• BTC versus altcoin leadership checks
• ETH participation monitoring
• Altcoin beta expansion environments
• Market regime comparison across timeframes
⚠️ When NOT to Use
• Symbols with poor liquidity
• Very low timeframes with noisy dominance behavior
• Markets where reference symbols are unavailable
• During extreme news shocks without broader context
🎛️ Key Inputs
• Leadership Momentum Length → controls the main comparison window
• Leadership Baseline Length → controls slower leadership context
• Leadership Edge Threshold → controls how strong rank separation must be
• Beta Expansion Threshold → controls chart outperformance sensitivity
• Ladder Projection Bars → controls right-side ladder length
• Label Font Size / Panel Font Size → controls visual readability
🖥️ Interface & Visual Design
The interface is designed as a leadership stack rather than a zone map.
The ladder avoids white or pale-gray primary visuals so it remains visible on both dark and light chart backgrounds.
The panel uses the AG Pro blue header with a single merged title row and a compact information hierarchy.
🧪 Practical Usage Workflow
1. Read the panel state.
2. Check which asset group leads the ladder.
3. Compare edge and persistence.
4. Read the leadership path color.
5. Use event labels as attention markers, not trade signals.
🔍 Interpretation Guidelines
Clear leadership means one group is controlling relative market behavior.
Split leadership means the market may be rotating, pausing, or lacking conviction.
Chart Beta Expansion means the active symbol is outperforming BTC, but it still requires broader confirmation.
🚫 What This Script Is NOT
This script is not a prediction engine.
It is not a financial-advice tool.
It is not an automated trading system.
It does not guarantee that leadership will continue.
It does not replace risk management or broader market analysis.
⚠️ Limitations & Transparency
Reference-symbol availability may vary by exchange, region, and TradingView data feed.
Dominance data may behave differently from exchange-traded pairs on lower timeframes.
Leadership can rotate quickly during volatile crypto sessions.
Different timeframes may show different leadership states.
🧠 Market Context Notes
BTC leadership often reflects defensive crypto behavior.
ETH leadership can suggest higher participation in major smart-contract assets.
Alt beta leadership can suggest broader risk appetite, but it may also be more volatile.
Split leadership often appears during transitions, pauses, or uncertain market regimes.
🧾 Use Case Examples
When BTC leads while BTC dominance rises, the market may be defensive even if price is moving.
When alt beta leads while BTC dominance falls, broader risk appetite may be improving.
When the active chart expands versus BTC while rank edge improves, that symbol may deserve closer attention.
🧱 System Philosophy
Crypto markets are not led by one chart all the time.
This script treats leadership as a rotating hierarchy and visualizes that hierarchy directly on the chart.
🔐 Non-Promise Statement
No script can guarantee future price behavior.
This tool maps leadership context; it does not provide certainty.
📉 Risk Disclosure
Trading involves risk.
Users are responsible for their own decisions.
This script is provided for educational and analytical purposes only and does not constitute financial advice.
📚 Educational Note
Use the ladder to study how crypto leadership rotates between BTC, ETH, alt beta, and the active chart across different market regimes.
Penunjuk

Relative Strength Pullback Map [AGPro Series]Relative Strength Pullback Map
🧠 Core Idea
Is the pullback happening while the asset remains a relative leader against its benchmark?
📌 Overview / What it does
Relative Strength Pullback Map is a benchmark-relative price-action tool built to study whether an asset is pulling back from strength or breaking down into weakness.
The script compares the active symbol against a selected benchmark, builds a relative-strength baseline, evaluates leader status, measures pullback depth, maps a pullback pocket, marks the recovery rail, and summarizes the full context inside a compact AG Pro panel.
It does not predict future price, automate trades, or claim that every leader pullback must recover. It is a structured decision-support map for reading relative strength, benchmark leadership, pullback health, recovery readiness, and relative breakdown risk.
🎯 Purpose & Design Philosophy
Pullbacks are not all equal.
Some pullbacks happen while the asset continues to outperform its benchmark.
Other pullbacks happen because relative strength is already breaking down.
This script was built to separate those two conditions. The design goal is to help traders identify whether a pullback belongs to a still-strong relative leader or a weakening laggard.
⚡ Why This Script Is Different
Most pullback tools focus only on price.
Most relative-strength tools focus only on the ratio line.
This script does NOT treat pullback quality and relative strength as separate ideas.
Instead, it combines benchmark-relative leadership, price pullback depth, trend shelf behavior, recovery rail reclaim, and relative breakdown risk into one visual map.
The focus is not only whether price pulled back.
The focus is whether the asset remained a leader while pulling back.
⚙️ Methodology
1. Benchmark Comparison
The script compares the active symbol against a selected benchmark using a relative-strength ratio.
2. Relative Strength Baseline
The ratio is smoothed into a baseline so leadership can be evaluated against its own recent behavior.
3. Leader Status Scoring
Leader status combines relative-strength distance, relative-strength slope, and price trend structure.
4. Pullback Depth Measurement
The script measures how far price has pulled back from the recent high using ATR-normalized depth and percentage depth.
5. Pullback Pocket Mapping
The pullback pocket is mapped between the fast recovery rail and the deeper trend shelf.
6. Recovery Evaluation
The script checks whether price is reclaiming the recovery rail while relative strength remains constructive.
7. Visual Output
The chart displays the pullback pocket, recovery rail, relative-strength rail, leader/laggard labels, right-side context tags, alerts, and a compact AG Pro panel.
🗺️ How to Read the Chart
Relative Pullback Pocket = the area where a leader pullback can remain structurally constructive.
Recovery Rail = the fast trend rail used to evaluate whether price is starting to recover from the pullback.
RS LEADER tag = the active symbol is outperforming the selected benchmark with constructive relative strength.
PULLBACK tag = the current pullback depth measured in ATR.
LEADER PULLBACK = the asset remains a relative leader while pulling into a meaningful pullback area.
RS HOLD = relative strength remains constructive during the pullback.
RECOVERY READY = price reclaimed the recovery rail while relative strength remained constructive.
RS BREAK = relative strength weakened or price broke the deeper pullback shelf.
Panel = summarizes relative state, quality score, leader status, pullback depth, recovery trigger, benchmark, and next context.
🚦 Signals & States
• LEADER PULLBACK → the asset remains a relative leader while pulling back.
• RS HOLD → relative strength is still holding during the pullback.
• RECOVERY READY → price reclaimed the recovery rail with constructive relative strength.
• RS BREAK → relative strength weakened or the pullback shelf broke.
• LAGGARD RISK → price is pulling back while the asset is no longer a clear relative leader.
🔔 Alerts Logic
Alerts can trigger when a leader pullback appears, relative strength holds, recovery becomes ready, or relative breakdown appears.
These alerts are attention markers only.
They are not trade instructions, entry signals, exit signals, or guaranteed outcomes.
🧩 Confluence Logic
The context becomes stronger when the active symbol remains above its relative-strength baseline, relative-strength slope is constructive, pullback depth is meaningful but not too deep, and price starts reclaiming the recovery rail.
The context becomes weaker when relative strength drops below its baseline, the slope turns down, or price breaks below the deeper trend shelf.
📊 When to Use
• During trend pullbacks
• When comparing an asset against a benchmark
• In crypto rotation analysis
• In stock or ETF relative-strength review
• When looking for leader pullbacks rather than weak pullbacks
• When filtering pullbacks by benchmark-relative performance
⚠️ When NOT to Use
• On symbols with poor benchmark fit
• During extremely noisy sideways markets
• In low-liquidity markets with unreliable candles
• When benchmark data is missing or unsuitable
• As a standalone buy or sell system
🎛️ Key Inputs
• Benchmark Symbol → defines the market used for relative comparison.
• Relative Strength Baseline → controls the smoothing length of the RS ratio.
• RS Slope Lookback → controls how relative-strength direction is evaluated.
• Minimum Leader Score → controls how strict leader classification should be.
• Fast Trend Length → controls the recovery rail.
• Slow Trend Length → controls the deeper pullback shelf.
• Pullback Lookback → controls the recent high used to measure pullback depth.
• Maximum Healthy Pullback ATR → controls when a pullback becomes too deep.
• Label and Panel Font Size → controls chart readability.
🖥️ Interface & Visual Design
The visual design is built around one question:
Is this still a leader pullback?
The pullback pocket shows the structural area, the recovery rail marks the reclaim reference, the relative-strength rail keeps benchmark context visible, the labels mark state changes, and the AG Pro panel summarizes the current decision context.
🧪 Practical Usage Workflow
1. Select an appropriate benchmark.
2. Read the panel first.
3. Check whether the asset is a relative leader.
4. Review pullback depth.
5. Look at the pullback pocket.
6. Watch whether price reclaims the recovery rail.
7. Confirm the broader market structure independently.
🔍 Interpretation Guidelines
A leader pullback means the asset is pulling back while still holding relative strength.
An RS hold means relative leadership has not broken yet.
Recovery ready means price has started reclaiming the recovery rail while relative strength remains constructive.
An RS break means the pullback may no longer be a clean leader pullback.
None of these states guarantee what happens next.
🚫 What This Script Is NOT
This script is not a prediction engine.
It is not a financial advice tool.
It is not an automated trading system.
It does not guarantee recovery after a leader pullback.
It does not guarantee that relative leaders will continue outperforming.
It does not replace risk management or independent analysis.
⚠️ Limitations & Transparency
Relative strength depends heavily on benchmark selection.
Different benchmarks may produce different interpretations.
Different timeframes may show different relative-strength states.
Fast markets can move through the pullback pocket quickly.
Sideways markets may create unclear relative-strength readings.
🧠 Market Context Notes
Relative strength is most useful when combined with structure, trend, volatility, and market regime.
A pullback in a relative leader can be constructive if leadership remains intact.
A pullback with relative breakdown is a weaker context and should be interpreted with caution.
Benchmark choice matters: crypto pairs may use BTCUSDT, stock charts may use SPY, sector ETFs, or another relevant benchmark.
🧾 Use Case Examples
When ETH pulls back while still outperforming BTC, the script can identify whether the pullback remains constructive or starts losing relative strength.
When a stock pulls back against SPY but relative strength holds above baseline, the script can highlight a leader pullback context.
When price breaks the pullback shelf while RS weakens, the script can flag relative breakdown risk.
🧱 System Philosophy
Relative Strength Pullback Map is part of the AGPro Series approach:
Build visual tools that explain market context clearly, avoid hype, avoid prediction claims, and support structured decision-making.
The goal is not to tell users what to do.
The goal is to help users see whether a pullback belongs to a strong leader or a weakening asset.
🔐 Non-Promise Statement
No script can remove uncertainty from trading.
This tool does not promise accuracy, certainty, profitability, or future performance.
📉 Risk Disclosure
Trading involves risk.
Market conditions can change quickly.
Users are responsible for their own decisions, position sizing, risk management, benchmark selection, and interpretation.
This script is for educational and analytical purposes only and does not provide financial advice.
📚 Educational Note
Use this script as a structured way to study relative strength, benchmark leadership, pullback depth, and recovery context.
The most valuable output is not a single label.
The value is the full map: relative state, leader status, pullback pocket, recovery rail, and next context.
Penunjuk

Real Strength Scalper Overview
A momentum-continuation scalping strategy designed for the 5-minute timeframe. It uses a single custom oscillator — the Real Strength histogram — combined with a dual SMA trend filter to capture confirmed directional moves, while a static percentage stop loss and an adaptive, regime-dependent exit logic manage open trades.
Concept and Originality
Most momentum oscillators answer either *which direction* or *how strong*, rarely both in a way that requires real conviction. The Real Strength histogram fuses three independent components into one signed value:
- Price momentum** — Rate of Change of price over N bars (provides the sign)
- Volume confirmation** — current volume divided by its moving average (amplifier)
- Trend strength** — ADX scaled around a 20 reference (amplifier)
These three are multiplied together (with a small floor to prevent the amplifiers from zeroing out the result on quiet bars) and then smoothed with an EMA. The output is an oscillator where the sign tells direction and the magnitude reflects how much *real* force is behind the move. A high histogram reading requires all three components to align — price moving, volume present, ADX confirming.
This composite differs from a standalone ROC, MACD, or volume-weighted oscillator because none of those three on their own require simultaneous confirmation across price, participation, and trend strength.
Entry Logic
A long entry requires every condition below to be true on the same bar:
- Histogram above the positive threshold (default 1.0)
- Histogram rising vs. the previous bar (no entries on a fading peak)
- ADX above the minimum level (default 14)
- DI+ greater than DI− (directional confirmation)
- Volume ratio above minimum (default 1.2× average)
- *Optional:* Fast SMA above Slow SMA (default 30/60, toggleable)
Short entries mirror these conditions on the bearish side.
Exit Logic — Regime-Dependent
The exit behavior changes based on whether the SMA trend filter still confirms the position. This is the central design choice of the strategy:
While SMA still confirms the position:
The trade exits only when the histogram crosses through zero into the opposite zone past a defined flip threshold (default ±0.8). This allows winners to ride through pullbacks and consolidations as long as the larger structure (SMA cross) still favors the trade.
After SMA reverses against the position:
The trade exits on a classic peak-drop rule — if the histogram falls 25% or more from its peak value reached during the trade, the position is closed. This protects open profits when structure breaks down.
A hard static stop loss (default 1%) is always active and overrides both exit modes if reached first. A minimum hold of 3 bars prevents premature exits caused by noise immediately after entry.
Re-Entry Lock
After a stop loss is hit, the strategy refuses to re-enter in the same direction until the histogram returns to (or crosses) zero. This prevents immediately re-entering the same momentum that just stopped the previous trade out — a common cause of consecutive losses on choppy bars.
Settings Guide
- Strength threshold (1.0):** minimum histogram magnitude required for entry. Lower values produce more trades; higher values are more selective.
- Min ADX (14):** filters out low-trending environments.
- Volume Ratio (1.2):** requires above-average participation on the entry bar.
- SMA Fast / Slow (30 / 60):** trend regime filter; can be disabled to compare baseline performance.
- Stop Loss % (1.0):** static distance from entry. Adjust per instrument volatility.
- Peak drop % (25):** how much the histogram must fall from peak to trigger peak-exit.
- Flip exit threshold (0.8):** how far the histogram must travel into the opposite zone to trigger flip-exit.
- Min bars before peak/flip (3):** protects against same-bar noise exits.
Default Properties and Backtesting Realism
- Initial capital: 100,000
- Position size: 3% of equity per trade
- Commission: 0.04%
- Slippage: 3 ticks
- Process orders on close: true
- No pyramiding
These defaults reflect realistic crypto futures conditions. Users trading other instruments or venues should adjust commission and slippage to match their broker.
Intended Use
- Built and validated on the 5-minute timeframe
- Best suited for liquid markets with consistent volume profile
- One position at a time, both long and short
- Re-tune thresholds per instrument; defaults are starting points, not optimal values for every market
Notes
Past performance does not guarantee future results. Backtest outcomes depend strongly on the chosen instrument, time range, and parameter settings. This strategy is published as an educational tool to demonstrate a composite-momentum approach with regime-dependent exits — not as a turnkey trading system. Always test with your own data and risk parameters before any live use. Strategi

Sortino Ratio Oscillator [MarkitTick]💡 The Sortino Ratio Oscillator introduces a sophisticated, risk-adjusted performance metric typically reserved for portfolio analysis, adapting it into a highly responsive momentum oscillator. By strictly penalizing downside volatility while rewarding upside momentum, it provides a much clearer picture of market strength compared to traditional oscillators that treat all volatility equally.
✨ Originality and Utility
Standard momentum indicators measure the velocity of price movement based on general variance. However, traditional models penalize both upside and downside volatility. A massive bullish breakout creates "high volatility," which standard indicators often misinterpret as an overextended or risky market condition.
This script resolves that inherent flaw by migrating the academic Sortino Ratio into a technical trading framework. It isolates "bad" volatility (price drops) from "good" volatility (price gains). The utility here is immense: traders can identify trends where the price action is genuinely supported by positive risk-adjusted returns, filtering out noisy markets where the downside deviation is too high. Furthermore, this tool features an integrated divergence detection engine, dynamic histogram coloring, and built-in webhook alert formatting, making it a comprehensive suite for algorithmic and discretionary traders alike.
🔬 Methodology and Concepts
The core engine of this indicator relies on continuously assessing the bar-to-bar percentage return of the asset.
First, it calculates the raw percentage return between the current close and the previous close.
Next, it isolates the downside returns. If a return is positive, it is ignored for the risk calculation (treated as zero). If it is negative, it is squared to emphasize larger drawdowns, following standard variance practices.
The script then computes the Simple Moving Average of these squared negative returns over a user-defined lookback window, calculating the square root to determine the final Downside Deviation.
Simultaneously, the Simple Moving Average of the raw returns is calculated to find the mean return over the same period.
The final Sortino Ratio is produced by dividing the mean return by the downside deviation.
To smooth the output and generate actionable crossovers, a secondary Signal Line is derived by applying an average to the raw Sortino Ratio.
To enhance the analytical depth, the script incorporates a robust divergence engine that scans for pivot highs and lows over a customizable lookback window. By comparing price action pivots with the oscillator's momentum peaks and troughs, it systematically maps out both regular and hidden divergences.
🎨 Visual Guide
The visual presentation is meticulously structured to provide instant clarity on risk-adjusted momentum states.
• The Sortino Histogram
The core oscillator is plotted as a multi-colored histogram. It utilizes a four-state coloring system to indicate momentum shifts:
Solid Bull Color: The ratio is above zero and rising, indicating accelerating positive risk-adjusted returns.
Transparent Bull Color: The ratio is above zero but falling, suggesting positive momentum is decelerating.
Solid Bear Color: The ratio is below zero and falling, indicating accelerating downside risk.
Transparent Bear Color: The ratio is below zero but rising, showing that downside risk is waning.
• Signal Line and Cloud Fill
A highlighted Signal Line tracks the moving average of the Sortino Ratio. The space between the Sortino histogram and the Signal Line is filled with a dynamic cloud, helping traders easily spot shifts in immediate trend strength.
• Threshold Lines
Dashed lines represent the Overbought and Oversold thresholds. A solid gray line marks the Zero Level, acting as the primary baseline for positive versus negative risk-adjusted states.
• Divergence Mapping
Regular Bullish (RB): Displayed as a solid line connecting price lows to oscillator lows, complete with a label below the candle.
Hidden Bullish (HB): Displayed as a dashed line, indicating trend continuation.
Regular Bearish (RD): Displayed as a solid line connecting price highs to oscillator highs.
Hidden Bearish (HD): Displayed as a dashed line.
• Candle Coloring
When enabled, the price chart's candles are painted to match the four-state color logic of the Sortino Histogram, linking the oscillator's data directly to the price action on the main chart.
📖 How to Use
Traders can interpret the Sortino Ratio Oscillator through several distinct frameworks depending on their trading style.
• Zero-Line Crossovers
A baseline shift occurs when the histogram crosses the zero line. A cross into positive territory confirms that the average returns now outweigh the downside deviation, signaling a structurally sound bullish environment. Conversely, a drop below zero warns that downside volatility is dominating the asset's behavior.
• Signal Line Interactions
Watch for the histogram to cross the Signal Line. When the Sortino Ratio spikes above its signal line, momentum is expanding. When it crosses below, it often precedes a consolidation or a reversal, as highlighted by the cloud fill changing colors.
• Extremes and Reversals
The Overbought and Oversold threshold lines act as exhaustion markers. An asset sustaining a Sortino Ratio above the Overbought level is exhibiting unusually high, unpenalized upside movement. While strong, traders should watch for the histogram to peak and cross back below the Signal Line as an early warning of a pullback.
• Trading Divergences
Divergences are perhaps the most powerful signals generated by this tool. Look for Regular Bullish Divergences when the price makes a lower low, but the Sortino Ratio makes a higher low. This indicates that despite the price drop, the underlying downside volatility is shrinking relative to the mean return, hinting at a bottom. Hidden Divergences are excellent for trading pullbacks in the direction of the macro trend.
⚙️ Inputs and Settings
• Sortino Settings
Lookback Length: Defines the period used to calculate the mean return and downside deviation. A shorter length is highly reactive, while a longer length provides macroscopic trend stability.
Signal Length: Adjusts the smoothness of the Signal Line.
Overbought / Oversold Levels: Customizes the threshold lines for extreme readings.
• Candle Coloring
A simple toggle to enable or disable the dynamic coloring of the main chart price candles based on the oscillator's state.
• Divergence Settings
Enable Divergence: Master toggle for the divergence engine.
Show Regular / Hidden: Independent toggles to filter specific divergence types.
Pivot Lookback Left / Right: Determines the strictness of the pivot point detection. Higher values require more significant peaks and troughs to form a valid pivot, filtering out noise.
• Webhook Action Names
Customizable string inputs allowing algorithmic traders to map specific script events directly to JSON payloads for automated execution platforms.
🔍 Deconstruction of the Underlying Scientific and Academic Framework
The Sortino Ratio, developed by Dr. Frank A. Sortino, is a vital modification of the Sharpe Ratio. In Modern Portfolio Theory, the Sharpe Ratio evaluates the performance of an investment by adjusting for its risk, defined universally as the standard deviation of its returns. However, standard deviation measures total volatility, treating an unexpected positive gain exactly the same as a negative loss.
This oscillator resolves that mathematical paradox by isolating downside deviation. The scientific framework dictates that a minimum acceptable return—in this script's case, zero—must be established. Only returns falling strictly below this threshold are aggregated and squared to calculate the downside variance. By exclusively measuring the standard deviation of negative asset returns, the formula effectively removes the penalty for upside volatility.
In a purely academic sense, a high Sortino Ratio mathematically proves that the asset is generating its returns without suffering significant, erratic drawdowns. Translated into technical analysis, when the indicator rises, it mathematically proves that the ratio of upward momentum relative to downward variance is expanding. This makes it an incredibly robust statistical measure, completely immune to the standard look-around bias of typical mathematical oscillators that collapse under the weight of sudden, positive price shocks.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. I expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Penunjuk

Hull MA Trend Zones [AGPro Series]Hull MA Trend Zones
📌 Overview
Hull MA Trend Zones is a premium HMA trend overlay built for traders who want a cleaner way to read Hull Moving Average direction, slope quality, and pullback behavior.
The script is centered on one clear idea: a strong HMA trend should not only move above or below a moving average; it should show measurable slope, orderly ribbon structure, and controlled pullback behavior around the active HMA path.
Instead of presenting a crowded moving average wall, the script uses a focused three-line HMA structure, a subtle pullback band, and concept-native trend zones that are tied directly to the active Hull MA state.
⚙️ How It Works
The engine calculates a fast HMA, an anchor HMA, and a slow HMA.
The anchor HMA is the main decision line. Its slope is normalized with ATR so the script can judge whether the current Hull MA movement is weak, transitional, or directional.
The ribbon structure then checks whether the fast, anchor, and slow HMA lines are aligned. This separates clean trend movement from mixed or unstable movement.
Finally, the pullback layer evaluates whether price is extending away from the HMA, testing the HMA zone, holding the HMA zone, rejecting from the HMA zone, or failing the active trend path.
🧭 What The Script Shows
- HMA ribbon for clean trend direction.
- ATR-based HMA pullback band around the anchor HMA.
- Rectangular HMA slope zones created from active directional states.
- Confirmed, quality-gated Bull Turn and Bear Turn labels.
- Optional Hold and Reject labels for pullback events.
- A compact AGPro panel with HMA State, Slope Strength, Pullback Status, and Quality Score.
📊 AGPro Panel
The panel is designed for fast scanning without taking over the chart.
HMA State shows whether the active read is bullish, bearish, transitional, or neutral.
Slope Strength converts the anchor HMA slope into a clear percentage-style reading.
Pullback Status explains whether price is extending, testing, holding, rejecting, or failing the HMA trend zone.
Quality Score combines slope strength, ribbon alignment, and pullback behavior into a single 0-100 reading.
🎯 What Makes It Different
Hull MA Trend Zones is not a generic moving average ribbon, not a ribbon compression map, and not a broad support/resistance tool.
Its focus is narrower and more practical: HMA slope, HMA trend-zone behavior, and pullback-to-HMA quality.
The rectangular zones are not drawn as generic support or resistance. They are HMA slope zones created from the active trend state and the ATR-sized HMA pullback area. This keeps the script visually useful while avoiding overlap with broader zone, corridor, or compression-style indicators.
The default visual design is intentionally restrained. Pullback labels are optional, turn labels require confirmation and a minimum quality score, and old zones are capped so the chart keeps a cleaner premium look on both intraday and higher-timeframe charts.
🔧 Key Settings
Fast HMA Length controls the responsive side of the ribbon.
Anchor HMA Length controls the main trend path, slope state, pullback band, and panel logic.
Slow HMA Length helps identify whether the HMA ribbon is aligned or still transitional.
Slope Lookback and Trend Slope Threshold control how selective the HMA state engine is.
Zone Width ATR controls the height of the HMA pullback band and slope-zone area.
Zone Forward Bars controls how far the active slope zone projects while the same trend state remains valid.
Turn Confirmation and Minimum Turn Label Score control how selective the default turn labels are.
Label Cooldown Bars, Max Visible Labels, and Label Offset ATR keep chart density suitable for publication-quality screenshots.
Panel Location, Panel Theme, Label Font Size, and Panel Font Size are adjustable.
✅ Suggested Use
Use Hull MA Trend Zones to study trend continuation, Hull MA pullback quality, HMA slope transitions, and cleaner moving-average trend behavior.
It is especially useful when you want an HMA-focused overlay that remains readable on active charts and avoids the clutter of large multi-average systems.
The script is designed as a public-free AGPro Series tool with a clean visual identity, a focused HMA concept, and a TradingView-safe publication structure. Penunjuk
