Trendlines with Breaks Oscillator [LuxAlgo]The Trendlines with Breaks Oscillator is an oscillator based on the Trendlines with Breaks indicator, and tracks the maximum distance on price from bullish and bearish trendline breakouts.
The oscillator features divergences and trendline breakout detection.
🔶 USAGE
This tool is based on our Trendlines with Breaks indicator, which detects bullish and bearish trendlines and highlights the breaks on the chart. Now, we bring you this tool as an oscillator.
The oscillator calculates the maximum distance between the price and the break of each trendline, for both bullish and bearish cases, then calculates the delta between both.
When the oscillator is above 0, the market is in an uptrend; when it is below 0, it is in a downtrend. An ascending slope indicates positive momentum, and a descending slope indicates negative momentum.
Trendline breaks are displayed as green and red dots on the oscillator. A green dot corresponds to a bullish break of a descending trendline, and a red dot corresponds to a bearish break of an ascending trendline.
The oscillator calculation depends on two parameters from the settings panel: short and long alpha length. These parameters are used to calculate a synthetic EMA with a variable alpha for both bullish and bearish breaks. The final result is the difference between the two averages.
As shown in the image, using the same trend detection parameters but different alphas can produce very different results. The larger the alphas, the smoother the oscillator becomes, detecting bigger trends but making it less reactive.
This tool features the same trendline detection system as the Trendlines with Breaks indicator, which is based on three main parameters: swing length, slope, and calculation method.
As we can see in the image above, the data collected for the oscillator calculation will be different when using different parameters. A larger length detects larger trends. A larger slope or a different calculation method also impacts the final result.
🔹 Signal Line
The signal line is a smoothed version of the oscillator; traders can choose the smoothing method and length used from the settings panel.
In the image, the signal line crossings are displayed as vertical lines. As we can see, the market usually corrects downward after a bearish crossing and corrects upward after a bullish crossing.
Traders can choose among 10 different smoothing methods for the signal line. In the image, we can see how different methods and lengths give different outputs.
🔹 Divergences
The tool features a divergence detector that helps traders understand the strength behind price movements. Traders can adjust the detection length from the settings panel.
As shown in the image, a bearish divergence occurs when the price prints higher highs, but the momentum on the histogram prints lower highs. A bullish divergence occurs when the price prints lower lows, but the histogram prints higher lows.
By adjusting the length of the divergence detector, traders can filter out smaller divergences, allowing the tool to only detect more significant ones.
The image above depicts divergences detected with different lengths; the larger the length, the bigger the divergences are detected.
🔶 SETTINGS
🔹 Trendlines
Swing Detection Lookback: The size of the market structure used for trendline detection.
Slope: Slope steepness, a value of 0 gives horizontal levels, values larger than 1 give a steeper slope
Slope Calculation Method: Choose how the slope is calculated
🔹 Oscillator
Short Alpha Length: Synthetic EMA short period
Long Alpha Length: Synthetic EMA long period
Smoothing Signal: Choose the smoothing method and period
Divergences: Enable or disable divergences and select the detection length.
🔹 Style
Bullish: Select bullish color.
Bearish: Select bearish color.
M-oscillator
Algorithm Predator - ML-liteAlgorithm Predator - ML-lite
This indicator combines four specialized trading agents with an adaptive multi-armed bandit selection system to identify high-probability trade setups. It is designed for swing and intraday traders who want systematic signal generation based on institutional order flow patterns , momentum exhaustion , liquidity dynamics , and statistical mean reversion .
Core Architecture
Why These Components Are Combined:
The script addresses a fundamental challenge in algorithmic trading: no single detection method works consistently across all market conditions. By deploying four independent agents and using reinforcement learning algorithms to select or blend their outputs, the system adapts to changing market regimes without manual intervention.
The Four Trading Agents
1. Spoofing Detector Agent 🎭
Detects iceberg orders through persistent volume at similar price levels over 5 bars
Identifies spoofing patterns via asymmetric wick analysis (wicks exceeding 60% of bar range with volume >1.8× average)
Monitors order clustering using simplified Hawkes process intensity tracking (exponential decay model)
Signal Logic: Contrarian—fades false breakouts caused by institutional manipulation
Best Markets: Consolidations, institutional trading windows, low-liquidity hours
2. Exhaustion Detector Agent ⚡
Calculates RSI divergence between price movement and momentum indicator over 5-bar window
Detects VWAP exhaustion (price at 2σ bands with declining volume)
Uses VPIN reversals (volume-based toxic flow dissipation) to identify momentum failure
Signal Logic: Counter-trend—enters when momentum extreme shows weakness
Best Markets: Trending markets reaching climax points, over-extended moves
3. Liquidity Void Detector Agent 💧
Measures Bollinger Band squeeze (width <60% of 50-period average)
Identifies stop hunts via 20-bar high/low penetration with immediate reversal and volume spike
Detects hidden liquidity absorption (volume >2× average with range <0.3× ATR)
Signal Logic: Breakout anticipation—enters after liquidity grab but before main move
Best Markets: Range-bound pre-breakout, volatility compression zones
4. Mean Reversion Agent 📊
Calculates price z-scores relative to 50-period SMA and standard deviation (triggers at ±2σ)
Implements Ornstein-Uhlenbeck process scoring (mean-reverting stochastic model)
Uses entropy analysis to detect algorithmic trading patterns (low entropy <0.25 = high predictability)
Signal Logic: Statistical reversion—enters when price deviates significantly from statistical equilibrium
Best Markets: Range-bound, low-volatility, algorithmically-dominated instruments
Adaptive Selection: Multi-Armed Bandit System
The script implements four reinforcement learning algorithms to dynamically select or blend agents based on performance:
Thompson Sampling (Default - Recommended):
Uses Bayesian inference with beta distributions (tracks alpha/beta parameters per agent)
Balances exploration (trying underused agents) vs. exploitation (using proven winners)
Each agent's win/loss history informs its selection probability
Lite Approximation: Uses pseudo-random sampling from price/volume noise instead of true random number generation
UCB1 (Upper Confidence Bound):
Calculates confidence intervals using: average_reward + sqrt(2 × ln(total_pulls) / agent_pulls)
Deterministic algorithm favoring agents with high uncertainty (potential upside)
More conservative than Thompson Sampling
Epsilon-Greedy:
Exploits best-performing agent (1-ε)% of the time
Explores randomly ε% of the time (default 10%, configurable 1-50%)
Simple, transparent, easily tuned via epsilon parameter
Gradient Bandit:
Uses softmax probability distribution over agent preference weights
Updates weights via gradient ascent based on rewards
Best for Blend mode where all agents contribute
Selection Modes:
Switch Mode: Uses only the selected agent's signal (clean, decisive)
Blend Mode: Combines all agents using exponentially weighted confidence scores controlled by temperature parameter (smooth, diversified)
Lock Agent Feature:
Optional manual override to force one specific agent
Useful after identifying which agent dominates your specific instrument
Only applies in Switch mode
Four choices: Spoofing Detector, Exhaustion Detector, Liquidity Void, Mean Reversion
Memory System
Dual-Layer Architecture:
Short-Term Memory: Stores last 20 trade outcomes per agent (configurable 10-50)
Long-Term Memory: Stores episode averages when short-term reaches transfer threshold (configurable 5-20 bars)
Memory Boost Mechanism: Recent performance modulates agent scores by up to ±20%
Episode Transfer: When an agent accumulates sufficient results, averages are condensed into long-term storage
Persistence: Manual restoration of learned parameters via input fields (alpha, beta, weights, microstructure thresholds)
How Memory Works:
Agent generates signal → outcome tracked after 8 bars (performance horizon)
Result stored in short-term memory (win = 1.0, loss = 0.0)
Short-term average influences agent's future scores (positive feedback loop)
After threshold met (default 10 results), episode averaged into long-term storage
Long-term patterns (weighted 30%) + short-term patterns (weighted 70%) = total memory boost
Market Microstructure Analysis
These advanced metrics quantify institutional order flow dynamics:
Order Flow Toxicity (Simplified VPIN):
Measures buy/sell volume imbalance over 20 bars: |buy_vol - sell_vol| / (buy_vol + sell_vol)
Detects informed trading activity (institutional players with non-public information)
Values >0.4 indicate "toxic flow" (informed traders active)
Lite Approximation: Uses simple open/close heuristic instead of tick-by-tick trade classification
Price Impact Analysis (Simplified Kyle's Lambda):
Measures market impact efficiency: |price_change_10| / sqrt(volume_sum_10)
Low values = large orders with minimal price impact ( stealth accumulation )
High values = retail-dominated moves with high slippage
Lite Approximation: Uses simplified denominator instead of regression-based signed order flow
Market Randomness (Entropy Analysis):
Counts unique price changes over 20 bars / 20
Measures market predictability
High entropy (>0.6) = human-driven, chaotic price action
Low entropy (<0.25) = algorithmic trading dominance (predictable patterns)
Lite Approximation: Simple ratio instead of true Shannon entropy H(X) = -Σ p(x)·log₂(p(x))
Order Clustering (Simplified Hawkes Process):
Tracks self-exciting event intensity (coordinated order activity)
Decays at 0.9× per bar, spikes +1.0 when volume >1.5× average
High intensity (>0.7) indicates clustering (potential spoofing/accumulation)
Lite Approximation: Simple exponential decay instead of full λ(t) = μ + Σ α·exp(-β(t-tᵢ)) with MLE
Signal Generation Process
Multi-Stage Validation:
Stage 1: Agent Scoring
Each agent calculates internal score based on its detection criteria
Scores must exceed agent-specific threshold (adjusted by sensitivity multiplier)
Agent outputs: Signal direction (+1/-1/0) and Confidence level (0.0-1.0)
Stage 2: Memory Boost
Agent scores multiplied by memory boost factor (0.8-1.2 based on recent performance)
Successful agents get amplified, failing agents get dampened
Stage 3: Bandit Selection/Blending
If Adaptive Mode ON:
Switch: Bandit selects single best agent, uses only its signal
Blend: All agents combined using softmax-weighted confidence scores
If Adaptive Mode OFF:
Traditional consensus voting with confidence-squared weighting
Signal fires when consensus exceeds threshold (default 70%)
Stage 4: Confirmation Filter
Raw signal must repeat for consecutive bars (default 3, configurable 2-4)
Minimum confidence threshold: 0.25 (25%) enforced regardless of mode
Trend alignment check: Long signals require trend_score ≥ -2, Short signals require trend_score ≤ 2
Stage 5: Cooldown Enforcement
Minimum bars between signals (default 10, configurable 5-15)
Prevents over-trading during choppy conditions
Stage 6: Performance Tracking
After 8 bars (performance horizon), signal outcome evaluated
Win = price moved in signal direction, Loss = price moved against
Results fed back into memory and bandit statistics
Trading Modes (Presets)
Pre-configured parameter sets:
Conservative: 85% consensus, 4 confirmations, 15-bar cooldown
Expected: 60-70% win rate, 3-8 signals/week
Best for: Swing trading, capital preservation, beginners
Balanced: 70% consensus, 3 confirmations, 10-bar cooldown
Expected: 55-65% win rate, 8-15 signals/week
Best for: Day trading, most traders, general use
Aggressive: 60% consensus, 2 confirmations, 5-bar cooldown
Expected: 50-58% win rate, 15-30 signals/week
Best for: Scalping, high-frequency trading, active management
Elite: 75% consensus, 3 confirmations, 12-bar cooldown
Expected: 58-68% win rate, 5-12 signals/week
Best for: Selective trading, high-conviction setups
Adaptive: 65% consensus, 2 confirmations, 8-bar cooldown
Expected: Varies based on learning
Best for: Experienced users leveraging bandit system
How to Use
1. Initial Setup (5 Minutes):
Select Trading Mode matching your style (start with Balanced)
Enable Adaptive Learning (recommended for automatic agent selection)
Choose Thompson Sampling algorithm (best all-around performance)
Keep Microstructure Metrics enabled for liquid instruments (>100k daily volume)
2. Agent Tuning (Optional):
Adjust Agent Sensitivity multipliers (0.5-2.0):
<0.8 = Highly selective (fewer signals, higher quality)
0.9-1.2 = Balanced (recommended starting point)
1.3 = Aggressive (more signals, lower individual quality)
Monitor dashboard for 20-30 signals to identify dominant agent
If one agent consistently outperforms, consider using Lock Agent feature
3. Bandit Configuration (Advanced):
Blend Temperature (0.1-2.0):
0.3 = Sharp decisions (best agent dominates)
0.5 = Balanced (default)
1.0+ = Smooth (equal weighting, democratic)
Memory Decay (0.8-0.99):
0.90 = Fast adaptation (volatile markets)
0.95 = Balanced (most instruments)
0.97+ = Long memory (stable trends)
4. Signal Interpretation:
Green triangle (▲): Long signal confirmed
Red triangle (▼): Short signal confirmed
Dashboard shows:
Active agent (highlighted row with ► marker)
Win rate per agent (green >60%, yellow 40-60%, red <40%)
Confidence bars (█████ = maximum confidence)
Memory size (short-term buffer count)
Colored zones display:
Entry level (current close)
Stop-loss (1.5× ATR)
Take-profit 1 (2.0× ATR)
Take-profit 2 (3.5× ATR)
5. Risk Management:
Never risk >1-2% per signal (use ATR-based stops)
Signals are entry triggers, not complete strategies
Combine with your own market context analysis
Consider fundamental catalysts and news events
Use "Confirming" status to prepare entries (not to enter early)
6. Memory Persistence (Optional):
After 50-100 trades, check Memory Export Panel
Record displayed alpha/beta/weight values for each agent
Record VPIN and Kyle threshold values
Enable "Restore From Memory" and input saved values to continue learning
Useful when switching timeframes or restarting indicator
Visual Components
On-Chart Elements:
Spectral Layers: EMA8 ± 0.5 ATR bands (dynamic support/resistance, colored by trend)
Energy Radiance: Multi-layer glow boxes at signal points (intensity scales with confidence, configurable 1-5 layers)
Probability Cones: Projected price paths with uncertainty wedges (15-bar projection, width = confidence × ATR)
Connection Lines: Links sequential signals (solid = same direction continuation, dotted = reversal)
Kill Zones: Risk/reward boxes showing entry, stop-loss, and dual take-profit targets
Signal Markers: Triangle up/down at validated entry points
Dashboard (Configurable Position & Size):
Regime Indicator: 4-level trend classification (Strong Bull/Bear, Weak Bull/Bear)
Mode Status: Shows active system (Adaptive Blend, Locked Agent, or Consensus)
Agent Performance Table: Real-time win%, confidence, and memory stats
Order Flow Metrics: Toxicity and impact indicators (when microstructure enabled)
Signal Status: Current state (Long/Short/Confirming/Waiting) with confirmation progress
Memory Panel (Configurable Position & Size):
Live Parameter Export: Alpha, beta, and weight values per agent
Adaptive Thresholds: Current VPIN sensitivity and Kyle threshold
Save Reminder: Visual indicator if parameters should be recorded
What Makes This Original
This script's originality lies in three key innovations:
1. Genuine Meta-Learning Framework:
Unlike traditional indicator mashups that simply display multiple signals, this implements authentic reinforcement learning (multi-armed bandits) to learn which detection method works best in current conditions. The Thompson Sampling implementation with beta distribution tracking (alpha for successes, beta for failures) is statistically rigorous and adapts continuously. This is not post-hoc optimization—it's real-time learning.
2. Episodic Memory Architecture with Transfer Learning:
The dual-layer memory system mimics human learning patterns:
Short-term memory captures recent performance (recency bias)
Long-term memory preserves historical patterns (experience)
Automatic transfer mechanism consolidates knowledge
Memory boost creates positive feedback loops (successful strategies become stronger)
This architecture allows the system to adapt without retraining , unlike static ML models that require batch updates.
3. Institutional Microstructure Integration:
Combines retail-focused technical analysis (RSI, Bollinger Bands, VWAP) with institutional-grade microstructure metrics (VPIN, Kyle's Lambda, Hawkes processes) typically found in academic finance literature and professional trading systems, not standard retail platforms. While simplified for Pine Script constraints, these metrics provide insight into informed vs. uninformed trading , a dimension entirely absent from traditional technical analysis.
Mashup Justification:
The four agents are combined specifically for risk diversification across failure modes:
Spoofing Detector: Prevents false breakout losses from manipulation
Exhaustion Detector: Prevents chasing extended trends into reversals
Liquidity Void: Exploits volatility compression (different regime than trending)
Mean Reversion: Provides mathematical anchoring when patterns fail
The bandit system ensures the optimal tool is automatically selected for each market situation, rather than requiring manual interpretation of conflicting signals.
Why "ML-lite"? Simplifications and Approximations
This is the "lite" version due to necessary simplifications for Pine Script execution:
1. Simplified VPIN Calculation:
Academic Implementation: True VPIN uses volume bucketing (fixed-volume bars) and tick-by-tick buy/sell classification via Lee-Ready algorithm or exchange-provided trade direction flags
This Implementation: 20-bar rolling window with simple open/close heuristic (close > open = buy volume)
Impact: May misclassify volume during ranging/choppy markets; works best in directional moves
2. Pseudo-Random Sampling:
Academic Implementation: Thompson Sampling requires true random number generation from beta distributions using inverse transform sampling or acceptance-rejection methods
This Implementation: Deterministic pseudo-randomness derived from price and volume decimal digits: (close × 100 - floor(close × 100)) + (volume % 100) / 100
Impact: Not cryptographically random; may have subtle biases in specific price ranges; provides sufficient variation for agent selection
3. Hawkes Process Approximation:
Academic Implementation: Full Hawkes process uses maximum likelihood estimation with exponential kernels: λ(t) = μ + Σ α·exp(-β(t-tᵢ)) fitted via iterative optimization
This Implementation: Simple exponential decay (0.9 multiplier) with binary event triggers (volume spike = event)
Impact: Captures self-exciting property but lacks parameter optimization; fixed decay rate may not suit all instruments
4. Kyle's Lambda Simplification:
Academic Implementation: Estimated via regression of price impact on signed order flow over multiple time intervals: Δp = λ × Δv + ε
This Implementation: Simplified ratio: price_change / sqrt(volume_sum) without proper signed order flow or regression
Impact: Provides directional indicator of impact but not true market depth measurement; no statistical confidence intervals
5. Entropy Calculation:
Academic Implementation: True Shannon entropy requires probability distribution: H(X) = -Σ p(x)·log₂(p(x)) where p(x) is probability of each price change magnitude
This Implementation: Simple ratio of unique price changes to total observations (variety measure)
Impact: Measures diversity but not true information entropy with probability weighting; less sensitive to distribution shape
6. Memory System Constraints:
Full ML Implementation: Neural networks with backpropagation, experience replay buffers (storing state-action-reward tuples), gradient descent optimization, and eligibility traces
This Implementation: Fixed-size array queues with simple averaging; no gradient-based learning, no state representation beyond raw scores
Impact: Cannot learn complex non-linear patterns; limited to linear performance tracking
7. Limited Feature Engineering:
Advanced Implementation: Dozens of engineered features, polynomial interactions (x², x³), dimensionality reduction (PCA, autoencoders), feature selection algorithms
This Implementation: Raw agent scores and basic market metrics (RSI, ATR, volume ratio); minimal transformation
Impact: May miss subtle cross-feature interactions; relies on agent-level intelligence rather than feature combinations
8. Single-Instrument Data:
Full Implementation: Multi-asset correlation analysis (sector ETFs, currency pairs, volatility indices like VIX), lead-lag relationships, risk-on/risk-off regimes
This Implementation: Only OHLCV data from displayed instrument
Impact: Cannot incorporate broader market context; vulnerable to correlated moves across assets
9. Fixed Performance Horizon:
Full Implementation: Adaptive horizon based on trade duration, volatility regime, or profit target achievement
This Implementation: Fixed 8-bar evaluation window
Impact: May evaluate too early in slow markets or too late in fast markets; one-size-fits-all approach
Performance Impact Summary:
These simplifications make the script:
✅ Faster: Executes in milliseconds vs. seconds (or minutes) for full academic implementations
✅ More Accessible: Runs on any TradingView plan without external data feeds, APIs, or compute servers
✅ More Transparent: All calculations visible in Pine Script (no black-box compiled models)
✅ Lower Resource Usage: <500 bars lookback, minimal memory footprint
⚠️ Less Precise: Approximations may reduce statistical edge by 5-15% vs. academic implementations
⚠️ Limited Scope: Cannot capture tick-level dynamics, multi-order-book interactions, or cross-asset flows
⚠️ Fixed Parameters: Some thresholds hardcoded rather than dynamically optimized
When to Upgrade to Full Implementation:
Consider professional Python/C++ versions with institutional data feeds if:
Trading with >$100K capital where precision differences materially impact returns
Operating in microsecond-competitive environments (HFT, market making)
Requiring regulatory-grade audit trails and reproducibility
Backtesting with tick-level precision for strategy validation
Need true real-time adaptation with neural network-based learning
For retail swing/day trading and position management, these approximations provide sufficient signal quality while maintaining usability, transparency, and accessibility. The core logic—multi-agent detection with adaptive selection—remains intact.
Technical Notes
All calculations use standard Pine Script built-in functions ( ta.ema, ta.atr, ta.rsi, ta.bb, ta.sma, ta.stdev, ta.vwap )
VPIN and Kyle's Lambda use simplified formulas optimized for OHLCV data (see "Lite" section above)
Thompson Sampling uses pseudo-random noise from price/volume decimal digits for beta distribution sampling
No repainting: All calculations use confirmed bar data (no forward-looking)
Maximum lookback: 500 bars (set via max_bars_back parameter)
Performance evaluation: 8-bar forward-looking window for reward calculation (clearly disclosed)
Confidence threshold: Minimum 0.25 (25%) enforced on all signals
Memory arrays: Dynamic sizing with FIFO queue management
Limitations and Disclaimers
Not Predictive: This indicator identifies patterns in historical data. It cannot predict future price movements with certainty.
Requires Human Judgment: Signals are entry triggers, not complete trading strategies. Must be confirmed with your own analysis, risk management rules, and market context.
Learning Period Required: The adaptive system requires 50-100 bars minimum to build statistically meaningful performance data for bandit algorithms.
Overfitting Risk: Restoring memory parameters from one market regime to a drastically different regime (e.g., low volatility to high volatility) may cause poor initial performance until system re-adapts.
Approximation Limitations: Simplified calculations (see "Lite" section) may underperform academic implementations by 5-15% in highly efficient markets.
No Guarantee of Profit: Past performance, whether backtested or live-traded, does not guarantee future performance. All trading involves risk of loss.
Forward-Looking Bias: Performance evaluation uses 8-bar forward window—this creates slight look-ahead for learning (though not for signals). Real-time performance may differ from indicator's internal statistics.
Single-Instrument Limitation: Does not account for correlations with related assets or broader market regime changes.
Recommended Settings
Timeframe: 15-minute to 4-hour charts (sufficient volatility for ATR-based stops; adequate bar volume for learning)
Assets: Liquid instruments with >100k daily volume (forex majors, large-cap stocks, BTC/ETH, major indices)
Not Recommended: Illiquid small-caps, penny stocks, low-volume altcoins (microstructure metrics unreliable)
Complementary Tools: Volume profile, order book depth, market breadth indicators, fundamental catalysts
Position Sizing: Risk no more than 1-2% of capital per signal using ATR-based stop-loss
Signal Filtering: Consider external confluence (support/resistance, trendlines, round numbers, session opens)
Start With: Balanced mode, Thompson Sampling, Blend mode, default agent sensitivities (1.0)
After 30+ Signals: Review agent win rates, consider increasing sensitivity of top performers or locking to dominant agent
Alert Configuration
The script includes built-in alert conditions:
Long Signal: Fires when validated long entry confirmed
Short Signal: Fires when validated short entry confirmed
Alerts fire once per bar (after confirmation requirements met)
Set alert to "Once Per Bar Close" for reliability
Taking you to school. — Dskyz, Trade with insight. Trade with anticipation.
ATM Premium Difference (Call - Put) Plots call-put difference of two different option contracts. Inspired by @TailThatWagsDog work
Commodity Channel Index Trend | DextraOverview
A smart, noise-filtered CCI that transforms chaotic oscillations into clear trend states. Instead of flipping constantly, CCI Trend locks into bullish or bearish mode only when momentum truly breaks out — using hysteresis to eliminate false signals.
Instant visual feedback via fully colored candles:
- Emerald Green = Bullish trend locked
- Hot Pink = Bearish trend locked
How It Works
1. Calculates standard CCI using EMA and price deviation
2. Triggers trend only when CCI exits the neutral zone
3. Locks the state until CCI breaks the opposite threshold
4. Updates CCI line color and candle appearance in real time
Williams Percent Range + MAA modernized take on the classic Williams %R oscillator — enhanced with a configurable moving average (SMA, EMA, RMA, WMA, HMA, or KAMA) for trend confirmation. Overbought and oversold zones are fully adjustable, and background highlights appear when momentum shifts: green for bullish crosses in oversold areas, red for bearish crosses in overbought zones.
Squeeze Momentum Early In and Out CandlesJohn Carter presented some candles called "Early In and Out Candles". Although I couldn't imitate the exact candles and warnings I create better indications and bars in my opinion.
When the Candles are above Donchian MA then we have a bullish Momentum.
When the Candles are bellow Donchian MA then we have bearish momentum.
This indicator works best to get an WARNING to enter and close EARLY positions.
Bullish:
When the candles are Light Blue then we have early warning to enter.
When the candles are Dark Blue then we have early warning to close the position.
Bearish:
When the candles are Red then we have early warning to enter.
When the candles are Yellow then we have early warning to close the position.
IMPORTANT NOTES:
Always combine it with the Squeeze Pro indicator.
Suggested Donchian MA: 5 (You can adjust it).
Don't let candles only to be your closing indication once again there are EARLY WARNINGS therefore can move your stop loses to maximize your profits when you are exiting.
I tested my self and I found that is the best strategy when we get Dark Blue candle in the Bullish move I move my stop loss little bit bellow the candle.
Therefore here we go we have early warnings for In and Out.
Thank you and Good Luck.
Chande Momentum Oscillator Trend | DextraOverview
A momentum-driven trend filter that turns the powerful Chande Momentum Oscillator (CMO) into a clean, actionable trend signal. ChandeMO Trend uses hysteresis locking to stay in bullish or bearish mode only when true momentum confirms direction. Instant visual clarity with fully colored candles:
Emerald Green → Bullish momentum locked
Hot Pink → Bearish momentum locked
How It Works
Calculates Chande Momentum Oscillator using EMA-smoothed upside/downside momentum
Triggers trend only when CMO exits the neutral zone
Locks the state until opposite threshold is broken
Updates CMO line color and candle appearance in real time
DAO - Demand Advanced Oscillator# DAO - Demand Advanced Oscillator
## 📊 Overview
DAO (Demand Advanced Oscillator) is a powerful momentum oscillator that measures buying and selling pressure by analyzing consecutive high-low relationships. It helps identify market extremes, divergences, and potential trend reversals.
**Values range from 0 to 1:**
- **Above 0.70** = Overbought (potential reversal down)
- **Below 0.30** = Oversold (potential reversal up)
- **0.30 - 0.70** = Neutral zone
---
## ✨ Key Features
✅ **Automatic Divergence Detection**
- Bullish divergences (price lower low + DAO higher low)
- Bearish divergences (price higher high + DAO lower high)
- Visual lines connecting divergence points
✅ **Multi-Timeframe Analysis**
- View higher timeframe DAO on current chart
- Perfect for trend alignment strategies
✅ **Signal Line (EMA)**
- Customizable EMA for trend confirmation
- Crossover signals for momentum shifts
✅ **Real-Time Statistics Dashboard**
- Current DAO value
- Market status (Overbought/Oversold/Neutral)
- Trend direction indicator
✅ **Complete Alert System**
- Overbought/Oversold signals
- Bullish/Bearish divergences
- Signal line crosses
- Level crosses
✅ **Fully Customizable**
- Adjustable periods and levels
- Customizable colors and zones
- Toggle features on/off
---
## 📈 Trading Signals
### 1. Divergences (Most Powerful)
**Bullish Divergence:**
- Price makes lower low
- DAO makes higher low
- Signal: Strong reversal up likely
**Bearish Divergence:**
- Price makes higher high
- DAO makes lower high
- Signal: Strong reversal down likely
### 2. Overbought/Oversold
**Overbought (>0.70):**
- Market may be overextended
- Consider taking profits or looking for shorts
- Can remain overbought in strong trends
**Oversold (<0.30):**
- Market may be oversold
- Consider buying opportunities
- Can remain oversold in strong downtrends
### 3. Signal Line Crossovers
**Bullish Cross:**
- DAO crosses above signal line
- Momentum turning positive
**Bearish Cross:**
- DAO crosses below signal line
- Momentum turning negative
### 4. Level Crosses
**Cross Above 0.30:** Exiting oversold zone (potential uptrend)
**Cross Below 0.70:** Exiting overbought zone (potential downtrend)
---
## ⚙️ Default Settings
📊 Oscillator Period: 14
Number of bars for calculation
📈 Signal Line Period: 9
EMA period for signal line
🔴 Overbought Level: 0.70
Upper threshold
🟢 Oversold Level: 0.30
Lower threshold
🎯 Divergence Detection: ON
Auto divergence identification
⏰ Multi-Timeframe: OFF
Higher TF overlay (optional)
All parameters are fully customizable!
---
## 🔔 Alerts
Six pre-configured alerts available:
1. DAO Overbought
2. DAO Oversold
3. DAO Bullish Divergence
4. DAO Bearish Divergence
5. DAO Signal Cross Up
6. DAO Signal Cross Down
**Setup:** Right-click indicator → Add Alert → Choose condition
---
## 💡 How to Use
### Best Practices:
✅ Focus on divergences (strongest signals)
✅ Combine with support/resistance levels
✅ Use multiple timeframes for confirmation
✅ Wait for price action confirmation
✅ Practice proper risk management
### Avoid:
❌ Trading on indicator alone
❌ Fighting strong trends
❌ Ignoring market context
❌ Overtrading
### Recommended Settings by Trading Style:
**Day Trading:** Period 7-10, All alerts ON
**Swing Trading:** Period 14-21, Divergence alerts
**Scalping:** Period 5-7, Signal crosses
**Position Trading:** Period 21-30, Weekly/Daily TF
---
## 🌍 Markets & Timeframes
**Works on all markets:**
- Forex (all pairs)
- Stocks (all exchanges)
- Cryptocurrencies
- Commodities
- Indices
- Futures
**Works on all timeframes:** 1m to Monthly
---
## 📊 How It Works
DAO calculates the ratio of buying pressure to total market pressure:
1. **Calculate Buying Pressure (DemandMax):**
- If current high > previous high: DemandMax = difference
- Otherwise: DemandMax = 0
2. **Calculate Selling Pressure (DemandMin):**
- If previous low > current low: DemandMin = difference
- Otherwise: DemandMin = 0
3. **Apply Smoothing:**
- Calculate SMA of DemandMax over N periods
- Calculate SMA of DemandMin over N periods
4. **Final Formula:**
```
DAO = SMA(DemandMax) / (SMA(DemandMax) + SMA(DemandMin))
```
This produces a normalized value (0-1) representing market demand strength.
---
## 🎯 Trading Strategies
### Strategy 1: Divergence Trading
- Wait for divergence label
- Confirm at support/resistance
- Enter on confirming candle
- Stop loss beyond recent swing
- Target: opposite level or 0.50
### Strategy 2: Overbought/Oversold
- Best for ranging markets
- Wait for extreme readings
- Enter on reversal from extremes
- Target: middle line (0.50)
### Strategy 3: Trend Following
- Identify trend direction first
- Use DAO to time entries in trend direction only
- Enter on pullbacks to oversold (uptrend) or overbought (downtrend)
- Trade with the trend
### Strategy 4: Multi-Timeframe
- Enable MTF feature
- Trade only when both timeframes align
- Higher TF = trend direction
- Lower TF = precise entry
---
## 📂 Category
**Primary:** Oscillators
**Secondary:** Statistics, Volatility, Momentum
---
## 🏷️ Tags
dao, oscillator, momentum, overbought-oversold, divergence, reversal, demand-indicator, price-exhaustion, statistics, volatility, forex, stocks, crypto, multi-timeframe, technical-analysis
---
## ⚠️ Disclaimer
**This indicator is for educational purposes only.** It does not constitute financial advice. Trading involves substantial risk of loss. Always conduct your own research, use proper risk management, and consult with financial professionals before making trading decisions. Past performance does not guarantee future results.
---
## 📄 License
Open source - Free to use for personal trading, modify as needed, and share with attribution.
---
**Version:** 1.0
**Status:** Production Ready ✅
**Pine Script:** v5
**Trademark-Free:** 100% Safe to Publish
---
*Made with 💙 for traders worldwide*
Mom(5) SMA(3)Plots 5-period Momentum and its 3-period SMA to smooth swings and highlight short-term trend shifts.
Range Oscillator Strategy + Stoch Confirm🔹 Short summary
This is a free, educational long-only strategy built on top of the public “Range Oscillator” by Zeiierman (used under CC BY-NC-SA 4.0), combined with a Stochastic timing filter, an EMA-based exit filter and an optional risk-management layer (SL/TP and R-multiple exits). It is NOT financial advice and it is NOT a magic money machine. It’s a structured framework to study how range-expansion + momentum + trend slope can be combined into one rule-based system, often with intentionally RARE trades.
────────────────────────
0. Legal / risk disclaimer
────────────────────────
• This script is FREE and public. I do not charge any fee for it.
• It is for EDUCATIONAL PURPOSES ONLY.
• It is NOT financial advice and does NOT guarantee profits.
• Backtest results can be very different from live results.
• Markets change over time; past performance is NOT indicative of future performance.
• You are fully responsible for your own trades and risk.
Please DO NOT use this script with money you cannot afford to lose. Always start in a demo / paper trading environment and make sure you understand what the logic does before you risk any capital.
────────────────────────
1. About default settings and risk (very important)
────────────────────────
The script is configured with the following defaults in the `strategy()` declaration:
• `initial_capital = 10000`
→ This is only an EXAMPLE account size.
• `default_qty_type = strategy.percent_of_equity`
• `default_qty_value = 100`
→ This means 100% of equity per trade in the default properties.
→ This is AGGRESSIVE and should be treated as a STRESS TEST of the logic, not as a realistic way to trade.
TradingView’s House Rules recommend risking only a small part of equity per trade (often 1–2%, max 5–10% in most cases). To align with these recommendations and to get more realistic backtest results, I STRONGLY RECOMMEND you to:
1. Open **Strategy Settings → Properties**.
2. Set:
• Order size: **Percent of equity**
• Order size (percent): e.g. **1–2%** per trade
3. Make sure **commission** and **slippage** match your own broker conditions.
• By default this script uses `commission_value = 0.1` (0.1%) and `slippage = 3`, which are reasonable example values for many crypto markets.
If you choose to run the strategy with 100% of equity per trade, please treat it ONLY as a stress-test of the logic. It is NOT a sustainable risk model for live trading.
────────────────────────
2. What this strategy tries to do (conceptual overview)
────────────────────────
This is a LONG-ONLY strategy designed to explore the combination of:
1. **Range Oscillator (Zeiierman-based)**
- Measures how far price has moved away from an adaptive mean.
- Uses an ATR-based range to normalize deviation.
- High positive oscillator values indicate strong price expansion away from the mean in a bullish direction.
2. **Stochastic as a timing filter**
- A classic Stochastic (%K and %D) is used.
- The logic requires %K to be below a user-defined level and then crossing above %D.
- This is intended to catch moments when momentum turns up again, rather than chasing every extreme.
3. **EMA Exit Filter (trend slope)**
- An EMA with configurable length (default 70) is calculated.
- The slope of the EMA is monitored: when the slope turns negative while in a long position, and the filter is enabled, it triggers an exit condition.
- This acts as a trend-protection exit: if the medium-term trend starts to weaken, the strategy exits even if the oscillator has not yet fully reverted.
4. **Optional risk-management layer**
- Percentage-based Stop Loss and Take Profit (SL/TP).
- Risk/Reward (R-multiple) exit based on the distance from entry to SL.
- Implemented as OCO orders that work *on top* of the logical exits.
The goal is not to create a “holy grail” system but to serve as a transparent, configurable framework for studying how these concepts behave together on different markets and timeframes.
────────────────────────
3. Components and how they work together
────────────────────────
(1) Range Oscillator (based on “Range Oscillator (Zeiierman)”)
• The script computes a weighted mean price and then measures how far price deviates from that mean.
• Deviation is normalized by an ATR-based range and expressed as an oscillator.
• When the oscillator is above the **entry threshold** (default 100), it signals a strong move away from the mean in the bullish direction.
• When it later drops below the **exit threshold** (default 30), it can trigger an exit (if enabled).
(2) Stochastic confirmation
• Classic Stochastic (%K and %D) is calculated.
• An entry requires:
- %K to be below a user-defined “Cross Level”, and
- then %K to cross above %D.
• This is a momentum confirmation: the strategy tries to enter when momentum turns up from a pullback rather than at any random point.
(3) EMA Exit Filter
• The EMA length is configurable via `emaLength` (default 70).
• The script monitors the EMA slope: it computes the relative change between the current EMA and the previous EMA.
• If the slope turns negative while the strategy holds a long position and the filter is enabled, it triggers an exit condition.
• This is meant to help protect profits or cut losses when the medium-term trend starts to roll over, even if the oscillator conditions are not (yet) signalling exit.
(4) Risk management (optional)
• Stop Loss (SL) and Take Profit (TP):
- Defined as percentages relative to average entry price.
- Both are disabled by default, but you can enable them in the Inputs.
• Risk/Reward Exit:
- Uses the distance from entry to SL to project a profit target at a configurable R-multiple.
- Also optional and disabled by default.
These exits are implemented as `strategy.exit()` OCO orders and can close trades independently of oscillator/EMA conditions if hit first.
────────────────────────
4. Entry & Exit logic (high level)
────────────────────────
A) Time filter
• You can choose a **Start Year** in the Inputs.
• Only candles between the selected start date and 31 Dec 2069 are used for backtesting (`timeCondition`).
• This prevents accidental use of tiny cherry-picked windows and makes tests more honest.
B) Entry condition (long-only)
A long entry is allowed when ALL the following are true:
1. `timeCondition` is true (inside the backtest window).
2. If `useOscEntry` is true:
- Range Oscillator value must be above `entryLevel`.
3. If `useStochEntry` is true:
- Stochastic condition (`stochCondition`) must be true:
- %K < `crossLevel`, then %K crosses above %D.
If these filters agree, the strategy calls `strategy.entry("Long", strategy.long)`.
C) Exit condition (logical exits)
A position can be closed when:
1. `timeCondition` is true AND a long position is open, AND
2. At least one of the following is true:
- If `useOscExit` is true: Oscillator is below `exitLevel`.
- If `useMagicExit` (EMA Exit Filter) is true: EMA slope is negative (`isDown = true`).
In that case, `strategy.close("Long")` is called.
D) Risk-management exits
While a position is open:
• If SL or TP is enabled:
- `strategy.exit("Long Risk", ...)` places an OCO stop/limit order based on the SL/TP percentages.
• If Risk/Reward exit is enabled:
- `strategy.exit("RR Exit", ...)` places an OCO order using a projected R-multiple (`rrMult`) of the SL distance.
These risk-based exits can trigger before the logical oscillator/EMA exits if price hits those levels.
────────────────────────
5. Recommended backtest configuration (to avoid misleading results)
────────────────────────
To align with TradingView House Rules and avoid misleading backtests:
1. **Initial capital**
- 10 000 (or any value you personally want to work with).
2. **Order size**
- Type: **Percent of equity**
- Size: **1–2%** per trade is a reasonable starting point.
- Avoid risking more than 5–10% per trade if you want results that could be sustainable in practice.
3. **Commission & slippage**
- Commission: around 0.1% if that matches your broker.
- Slippage: a few ticks (e.g. 3) to account for real fills.
4. **Timeframe & markets**
- Volatile symbols (e.g. crypto like BTCUSDT, or major indices).
- Timeframes: 1H / 4H / **1D (Daily)** are typical starting points.
- I strongly recommend trying the strategy on **different timeframes**, for example 1D, to see how the behaviour changes between intraday and higher timeframes.
5. **No “caution warning”**
- Make sure your chosen symbol + timeframe + settings do not trigger TradingView’s caution messages.
- If you see warnings (e.g. “too few trades”), adjust timeframe/symbol or the backtest period.
────────────────────────
5a. About low trade count and rare signals
────────────────────────
This strategy is intentionally designed to trade RARELY:
• It is **long-only**.
• It uses strict filters (Range Oscillator threshold + Stochastic confirmation + optional EMA Exit Filter).
• On higher timeframes (especially **1D / Daily**) this can result in a **low total number of trades**, sometimes WELL BELOW 100 trades over the whole backtest.
TradingView’s House Rules mention 100+ trades as a guideline for more robust statistics. In this specific case:
• The **low trade count is a conscious design choice**, not an attempt to cherry-pick a tiny, ultra-profitable window.
• The goal is to study a **small number of high-conviction long entries** on higher timeframes, not to generate frequent intraday signals.
• Because of the low trade count, results should NOT be interpreted as statistically strong or “proven” – they are only one sample of how this logic would have behaved on past data.
Please keep this in mind when you look at the equity curve and performance metrics. A beautiful curve with only a handful of trades is still just a small sample.
────────────────────────
6. How to use this strategy (step-by-step)
────────────────────────
1. Add the script to your chart.
2. Open the **Inputs** tab:
- Set the backtest start year.
- Decide whether to use Oscillator-based entry/exit, Stochastic confirmation, and EMA Exit Filter.
- Optionally enable SL, TP, and Risk/Reward exits.
3. Open the **Properties** tab:
- Set a realistic account size if you want.
- Set order size to a realistic % of equity (e.g. 1–2%).
- Confirm that commission and slippage are realistic for your broker.
4. Run the backtest:
- Look at Net Profit, Max Drawdown, number of trades, and equity curve.
- Remember that a low trade count means the statistics are not very strong.
5. Experiment:
- Tweak thresholds (`entryLevel`, `exitLevel`), Stochastic settings, EMA length, and risk params.
- See how the metrics and trade frequency change.
6. Forward-test:
- Before using any idea in live trading, forward-test on a demo account and observe behaviour in real time.
────────────────────────
7. Originality and usefulness (why this is more than a mashup)
────────────────────────
This script is not intended to be a random visual mashup of indicators. It is designed as a coherent, testable strategy with clear roles for each component:
• Range Oscillator:
- Handles mean vs. range-expansion states via an adaptive, ATR-normalized metric.
• Stochastic:
- Acts as a timing filter to avoid entering purely on extremes and instead waits for momentum to turn.
• EMA Exit Filter:
- Trend-slope-based safety net to exit when the medium-term direction changes against the position.
• Risk module:
- Provides practical, rule-based exits: SL, TP, and R-multiple exit, which are useful for structuring risk even if you modify the core logic.
It aims to give traders a ready-made **framework to study and modify**, not a black box or “signals” product.
────────────────────────
8. Limitations and good practices
────────────────────────
• No single strategy works on all markets or in all regimes.
• This script is long-only; it does not short the market.
• Performance can degrade when market structure changes.
• Overfitting (curve fitting) is a real risk if you endlessly tweak parameters to maximise historical profit.
Good practices:
- Test on multiple symbols and timeframes.
- Focus on stability and drawdown, not only on how high the profit line goes.
- View this as a learning tool and a basis for your own research.
────────────────────────
9. Licensing and credits
────────────────────────
• Core oscillator idea & base code:
- “Range Oscillator (Zeiierman)”
- © Zeiierman, licensed under CC BY-NC-SA 4.0.
• Strategy logic, Stochastic confirmation, EMA Exit Filter, and risk-management layer:
- Modifications by jokiniemi.
Please respect both the original license and TradingView House Rules if you fork or republish any part of this script.
────────────────────────
10. No payments / no vendor pitch
────────────────────────
• This script is completely FREE to use on TradingView.
• There is no paid subscription, no external payment link, and no private signals group attached to it.
• If you have questions, please use TradingView’s comment system or private messages instead of expecting financial advice.
Use this script as a tool to learn, experiment, and build your own understanding of markets.
────────────────────────
11. Example backtest settings used in screenshots
────────────────────────
To avoid any confusion about how the results shown in screenshots were produced, here is one concrete example configuration:
• Symbol: BTCUSDT (or similar major BTC pair)
• Timeframe: 1D (Daily)
• Backtest period: from 2018 to the most recent data
• Initial capital: 10 000
• Order size type: Percent of equity
• Order size: 2% per trade
• Commission: 0.1%
• Slippage: 3 ticks
• Risk settings: Stop Loss and Take Profit disabled by default, Risk/Reward exit disabled by default
• Filters: Range Oscillator entry/exit enabled, Stochastic confirmation enabled, EMA Exit Filter enabled
If you change any of these settings (symbol, timeframe, risk per trade, commission, slippage, filters, etc.), your results will look different. Please always adapt the configuration to your own risk tolerance, market, and trading style.
Market Profile Dominance Analyzer# Market Profile Dominance Analyzer
## 📊 OVERVIEW
**Market Profile Dominance Analyzer** is an advanced multi-factor indicator that combines Market Profile methodology with composite dominance scoring to identify buyer and seller strength across higher timeframes. Unlike traditional volume profile indicators that only show volume distribution, or simple buyer/seller indicators that only compare candle colors, this script integrates six distinct analytical components into a unified dominance measurement system.
This indicator helps traders understand **WHO controls the market** by analyzing price position relative to Market Profile key levels (POC, Value Area) combined with volume distribution, momentum, and trend characteristics.
## 🎯 WHAT MAKES THIS ORIGINAL
### **Hybrid Analytical Approach**
This indicator uniquely combines two separate methodologies that are typically analyzed independently:
1. **Market Profile Analysis** - Calculates Point of Control (POC) and Value Area (VA) using volume distribution across price channels on higher timeframes
2. **Multi-Factor Dominance Scoring** - Weights six independent factors to produce a composite dominance index
### **Six-Factor Composite Analysis**
The dominance score integrates:
- Price position relative to POC (equilibrium assessment)
- Price position relative to Value Area boundaries (acceptance/rejection zones)
- Volume imbalance within Value Area (institutional bias detection)
- Price momentum (directional strength)
- Volume trend comparison (participation analysis)
- Normalized Value Area position (precise location within fair value zone)
### **Adaptive Higher Timeframe Integration**
The script features an intelligent auto-selection system that automatically chooses appropriate higher timeframes based on the current chart period, ensuring optimal Market Profile structure regardless of the trading timeframe being analyzed.
## 💡 HOW IT WORKS
### **Market Profile Construction**
The indicator builds a Market Profile structure on a higher timeframe by:
1. **Session Identification** - Detects new higher timeframe sessions using `request.security()` to ensure accurate period boundaries
2. **Data Accumulation** - Stores high, low, and volume data for all bars within the current higher timeframe session
3. **Channel Distribution** - Divides the session's price range into configurable channels (default: 20 rows)
4. **Volume Mapping** - Distributes each bar's volume proportionally across all price channels it touched
### **Key Level Calculation**
**Point of Control (POC)**
- Identifies the price channel with the highest accumulated volume
- Represents the price level where the most trading activity occurred
- Serves as a magnetic level where price often returns
**Value Area (VA)**
- Starts at POC and expands both upward and downward
- Includes channels until reaching the specified percentage of total volume (default: 70%)
- Expansion algorithm compares adjacent volumes and prioritizes the direction with higher activity
- Defines the "fair value" zone where most market participants agreed to trade
### **Dominance Score Formula**
```
Dominance Score = (price_vs_poc × 10) +
(price_vs_va × 5) +
(volume_imbalance × 0.5) +
(price_momentum × 100) +
(volume_trend × 5) +
(va_position × 15)
```
**Component Breakdown:**
- **price_vs_poc**: +1 if above POC, -1 if below (shows which side of equilibrium)
- **price_vs_va**: +2 if above VAH, -2 if below VAL, 0 if inside VA
- **volume_imbalance**: Percentage difference between upper and lower VA volumes
- **price_momentum**: 5-period SMA of price change (directional acceleration)
- **volume_trend**: Compares 5-period vs 20-period volume averages
- **va_position**: Normalized position within Value Area (-1 to +1)
The composite score is then smoothed using EMA with configurable sensitivity to reduce noise while maintaining responsiveness.
### **Market State Determination**
- **BUYERS Dominant**: Smooth dominance > +10 (bullish control)
- **SELLERS Dominant**: Smooth dominance < -10 (bearish control)
- **NEUTRAL**: Between -10 and +10 (balanced market)
## 📈 HOW TO USE THIS INDICATOR
### **Trend Identification**
- **Green background** indicates buyers are in control - look for long opportunities
- **Red background** indicates sellers are in control - look for short opportunities
- **Gray background** indicates neutral market - consider range-bound strategies
### **Signal Interpretation**
**Buy Signals** (green triangle) appear when:
- Dominance crosses above -10 from oversold conditions
- Previous state was not already bullish
- Suggests shift from seller to buyer control
**Sell Signals** (red triangle) appear when:
- Dominance crosses below +10 from overbought conditions
- Previous state was not already bearish
- Suggests shift from buyer to seller control
### **Value Area Context**
Monitor the information table (top-right) to understand market structure:
- **Price vs POC**: Shows if trading above/below equilibrium
- **Volume Imbalance**: Positive values favor buyers, negative favors sellers
- **Market State**: Current dominant force (BUYERS/SELLERS/NEUTRAL)
### **Multi-Timeframe Strategy**
The auto-timeframe feature analyzes higher timeframe structure:
- On 1-minute charts → analyzes 2-hour structure
- On 5-minute charts → analyzes Daily structure
- On 15-minute charts → analyzes Weekly structure
- On Daily charts → analyzes Yearly structure
This higher timeframe context helps avoid counter-trend trades against the dominant force.
### **Confluence Trading**
Strongest signals occur when multiple factors align:
1. Price above VAH + positive volume imbalance + buyers dominant = Strong bullish setup
2. Price below VAL + negative volume imbalance + sellers dominant = Strong bearish setup
3. Price at POC + neutral state = Potential breakout/breakdown pivot
## ⚙️ INPUT PARAMETERS
- **Higher Time Frame**: Select specific HTF or use 'Auto' for intelligent selection
- **Value Area %**: Percentage of volume contained in VA (default: 70%)
- **Show Buy/Sell Signals**: Toggle signal triangles visibility
- **Show Dominance Histogram**: Toggle histogram display
- **Signal Sensitivity**: EMA period for dominance smoothing (1-20, default: 5)
- **Number of Channels**: Market Profile resolution (10-50, default: 20)
- **Color Settings**: Customize buyer, seller, and neutral colors
## 🎨 VISUAL ELEMENTS
- **Histogram**: Shows smoothed dominance score (green = buyers, red = sellers)
- **Zero Line**: Neutral equilibrium reference
- **Overbought/Oversold Lines**: ±50 levels marking extreme dominance
- **Background Color**: Highlights current market state
- **Information Table**: Displays key metrics (state, dominance, POC relationship, volume imbalance, timeframe, bars in session, total volume)
- **Signal Shapes**: Triangle markers for buy/sell signals
## 🔔 ALERTS
The indicator includes three alert conditions:
1. **Buyers Dominate** - Fires on buy signal crossovers
2. **Sellers Dominate** - Fires on sell signal crossovers
3. **Dominance Shift** - Fires when dominance crosses zero line
## 📊 BEST PRACTICES
### **Timeframe Selection**
- **Scalping (1-5min)**: Focus on 2H-4H dominance shifts
- **Day Trading (15-60min)**: Monitor Daily and Weekly structure
- **Swing Trading (4H-Daily)**: Track Weekly and Monthly dominance
### **Confirmation Strategies**
1. **Trend Following**: Enter in direction of dominance above/below ±20
2. **Reversal Trading**: Fade extreme readings beyond ±50 when diverging with price
3. **Breakout Trading**: Look for dominance expansion beyond ±30 with increasing volume
### **Risk Management**
- Avoid trading during NEUTRAL states (dominance between -10 and +10)
- Use POC levels as logical stop-loss placement
- Consider VAH/VAL as profit targets for mean reversion
## ⚠️ LIMITATIONS & WARNINGS
**Data Requirements**
- Requires sufficient historical data on current chart (minimum 100 bars recommended)
- Lower timeframes may show fewer bars per HTF session initially
- More accurate results after several complete HTF sessions have formed
**Not a Standalone System**
- This indicator analyzes market structure and participant control
- Should be combined with price action, support/resistance, and risk management
- Does not guarantee profitable trades - past dominance does not predict future results
**Repainting Characteristics**
- Higher timeframe levels (POC, VAH, VAL) update as new bars form within the session
- Dominance score recalculates with each new bar
- Historical signals remain fixed, but current session data is developing
**Volume Limitations**
- Uses exchange-provided volume data which varies by instrument type
- Forex and some CFDs use tick volume (not actual transaction volume)
- Most accurate on instruments with reliable volume data (stocks, futures, crypto)
## 🔍 TECHNICAL NOTES
**Performance Optimization**
- Uses `max_bars_back=5000` for extended historical analysis
- Efficient array management prevents memory issues
- Automatic cleanup of session data on new period
**Calculation Method**
- Market Profile uses actual volume distribution, not TPO (Time Price Opportunity)
- Value Area expansion follows traditional Market Profile auction theory
- All calculations occur on the chart's current symbol and timeframe
## 📚 EDUCATIONAL VALUE
This indicator helps traders understand:
- How institutional traders use Market Profile to identify fair value
- The relationship between price, volume, and market acceptance
- Multi-factor analysis techniques for assessing market conditions
- The importance of higher timeframe structure in trade planning
## 🎓 RECOMMENDED READING
To better understand the concepts behind this indicator:
- "Mind Over Markets" by James Dalton (Market Profile foundations)
- "Markets in Profile" by James Dalton (Value Area analysis)
- Volume Profile analysis in institutional trading
## 💬 USAGE TERMS
This indicator is provided as an educational and analytical tool. It does not constitute financial advice, investment recommendations, or trading signals. Users are responsible for their own trading decisions and should conduct their own research and due diligence.
Trading involves substantial risk of loss. Past performance does not guarantee future results. Always use proper risk management and never risk more than you can afford to lose.
Alpha-Weighted RSIDescription:
The Alpha-Weighted RSI is a next-generation momentum oscillator that redefines the classic RSI by incorporating the mathematical principles of Lévy Flight. This advanced adaptation applies non-linear weighting to price changes, making the indicator more sensitive to significant market moves and less reactive to minor noise. It is designed for traders seeking a clearer, more powerful view of momentum and potential reversal zones.
🔍 Key Features & Innovations:
Lévy Flight Alpha Weighting: At the core of this indicator is the Alpha parameter (1.0-2.0), which controls the sensitivity to price changes.
Lower Alpha (e.g., 1.2): Makes the indicator highly responsive to recent price movements, ideal for capturing early trend shifts.
Higher Alpha (e.g., 1.8): Creates a smoother, more conservative output that filters out noise, focusing on stronger momentum.
Customizable Smoothing: The raw Lévy-RSI is smoothed by a user-selectable moving average (8 MA types supported: SMA, EMA, SMMA, etc.), allowing for further customization of responsiveness.
Intuitive Centered Oscillator: The RSI is centered around a zero line, providing a clean visual separation between bullish and bearish territory.
Dynamic Gradient Zones: Subtle, colour coded gradient fills in the overbought (>+25) and oversold (<-25) regions enhance visual clarity without cluttering the chart.
Modern Histogram Display: Momentum is plotted as a sleek histogram that changes color between bright cyan (bullish) and magenta (bearish) based on its position relative to the zero line.
🎯 How to Use & Interpret:
Zero-Line Crossovers: The most basic signals. A crossover above the zero line indicates building bullish momentum, while a crossover below suggests growing bearish momentum.
Overbought/Oversold Levels: Use the +25/-25 and +35/-35 levels as dynamic zones. A reading above +25 suggests strong bullish momentum (overbought), while a reading below -25 indicates strong bearish momentum (oversold).
Divergence Detection: Look for divergences between the Alpha-Weighted RSI and price action. For example, if price makes a new low but the RSI forms a higher low, it can signal a potential bullish reversal.
Alpha Tuning: Adjust the Alpha parameter to match market volatility. In choppy markets, increase alpha to reduce noise. In trending markets, decrease alpha to become more responsive.
⚙️ Input Parameters:
RSI Settings: Standard RSI inputs for Length and Calculation Source.
Lévy Flight Settings: The crucial Alpha factor for response control.
MA Settings: MA Type and MA Length for smoothing the final output.
By applying Lévy Flight dynamics, this indicator offers a nuanced perspective on momentum, helping you stay ahead of the curve. Feedback is always welcome!
Valdex BBWP Multitimeframe🇬🇧 (English Version)
Valdex BBWP Multitimeframe: Multitimeframe Volatility.
**Created by:**
**Adaptation of: Bollinger Band Width Percentile (BBWP)
📄 General Description
The **Valdex BBWP Multitimeframe** indicator is an advanced and optimized adaptation of the classic *Bollinger Band Width Percentile (BBWP)* indicator. Its purpose is to provide a robust and flexible tool for measuring the market's **relative volatility** on a scale from 0 to 100.
What distinguishes this version is its ability to **analyze volatility across THREE timeframes simultaneously**, allowing you to confirm expansion (high volatility) or contraction (low volatility) in higher timeframes without switching charts. It is an essential filter for any breakout or retracement strategy.
✨ Key Features
The indicator plots three volatility lines, each with a specific and independently configurable purpose:
1. **Base Line (Current TF):** Displays the BBWP calculated on the **exact timeframe of the current chart**, preserving its pure, unsmoothed value (original "noise").
2. **Multitimeframe (MTF) Lines:** Allows you to define two completely separate BBWP lines, each pulling data from an **external timeframe** (e.g., 60 minutes, Daily). Includes a **configurable Moving Average (MA)** to smooth the noise.
⚙️ Configuration and Usage
* **BBWP Base Settings:** You can configure the underlying BBWP parameters: Bands Length (13 default) and Percentile Lookback (252 default).
* **MTF Configuration:** For Lines 2 and 3, you **must manually enter** the desired timeframe in the text field (valid examples: `5`, `60`, `240`, `D`, `W`).
OsMA by A8/4 - Limited Edition🌟 **OsMA by A8/4 — The Ultimate Indicator for XAUUSD Trading** 🌟
An intelligent **automated system** designed exclusively for **gold trading**, equipped with everything you need in one tool 🔥
💡 **Key Features of OsMA by A8/4**
✅ **Auto Entry Signals**
Automatically detects trade opportunities using a **refined MACD Histogram formula** for enhanced accuracy.
Displays **LONG/SHORT arrows only on the first bar** to keep your chart clean and readable.
✅ **Auto Take Profit & Stop Loss System (Auto TP/SL)**
Once a signal appears, the system automatically sets:
* **TP1 = +15 USD**
* **TP2 = +25 USD**
* **SL = -10 USD**
These levels are displayed as **dashed lines** on the chart — clear and updated in real-time.
✅ **Smart DCA System (3 Orders)**
Works for both LONG and SHORT positions:
* **Order 1:** Entry upon signal confirmation (after candle close)
* **Order 2:** Entry at 5 USD below/above Order 1
* **Order 3:** Entry at another 5 USD below/above Order 2
The system automatically **calculates the average entry price** and **adjusts the SL** to -10 USD from the average cost.
This helps **spread risk** and **increase recovery potential** when prices rebound 💰
✅ **Specially Designed for XAUUSD Trading**
Compatible with both **Spot Gold** and **TFEX Gold Futures**.
Perfect for traders who value **clear, structured entry and exit strategies**.
Luminous Glide Momentum Indicator [wjdtks255]This indicator, named "Customized SuperSmoother MA Oscillator," applies a smoothing filter to price data using a SuperSmoother technique to reduce noise and enhance signal clarity. It calculates two moving averages on the smoothed data—a fast and a slow—whose difference forms the oscillator line. A signal line is derived by smoothing the oscillator with another moving average. The histogram visualizes the divergence between the oscillator and signal lines, indicating momentum strength and direction.
How it works
SuperSmoother Filter: Reduces price noise to provide smoother and more reliable signals than raw data.
Fast and Slow Moving Averages: The fast MA reacts quicker to price changes, while the slow MA indicates longer trends.
Oscillator: The difference between the fast and slow MAs signals shifts in momentum.
Signal Line: A smoothed version of the oscillator used to generate crossovers.
Histogram: Displays the distance between the oscillator and signal line, with color changes indicating bullish or bearish momentum.
Trading Strategy
Buy Signal: When the oscillator crosses above the signal line, it suggests increasing upward momentum, signaling a potential buy opportunity.
Sell Signal: When the oscillator crosses below the signal line, it suggests increasing downward momentum, signaling a potential sell opportunity.
Histogram Size and Color: Larger green bars indicate stronger bullish momentum; larger red bars indicate stronger bearish momentum.
Usage Tips
Combine this oscillator with other indicators or price action analysis to confirm trading signals.
Adjust smoothing and moving average lengths according to your trading timeframe and the asset volatility.
Use proper risk management to filter out potential false signals common in oscillators.
Z-Score of RSI//@version=5
indicator("Z-Score of RSI", overlay=false)
// Tham số
rsi_length = input.int(14, "RSI Length")
z_length = input.int(60, "Z-Score Period")
// Tính RSI
rsi = ta.rsi(close, rsi_length)
// Tính Z-Score
mean_rsi = ta.sma(rsi, z_length)
std_rsi = ta.stdev(rsi, z_length)
z_rsi = (rsi - mean_rsi) / std_rsi
// Vẽ biểu đồ
plot(z_rsi, color=color.new(color.aqua, 0), linewidth=2, title="Z-Score(RSI)")
hline(0, "Mean", color=color.gray)
hline(2, "Overbought (+2σ)", color=color.red)
hline(-2, "Oversold (-2σ)", color=color.lime)
// Cảnh báo (tuỳ chọn)
bgcolor(z_rsi < -2 ? color.new(color.lime, 85) : na)
bgcolor(z_rsi > 2 ? color.new(color.red, 85) : na)
ADX FAST and NOICE FREE DIThis tool is designed to identify trend strength and direction earlier than the traditional ADX/DI system.
Instead of relying on the normal Wilder smoothing, this version applies momentum projection to ADX (Fast ADX)
and then filters all directional movement signals through Hull smoothing to minimize market noise.
The result:
• Trends are detected faster
• Pullbacks are filtered more cleanly
• Sideways or weak structures become easy to avoid
Recommended Usage:
• Look for Fast ADX above the threshold to confirm trend environment
• Use Noise-Free +DI and -DI to confirm trend direction (bullish / bearish dominance)
• Background color highlights only when trend + direction are aligned
This is not a buy/sell signal generator by itself; it is best used as a trend and market condition confirmation layer.
Disclaimer:
This script is provided for educational and informational purposes only.
It does not constitute financial advice or a recommendation to buy or sell any security.
Market conditions vary and past performance does not guarantee future results.
Always perform your own analysis and risk management, and trade responsibly.
Robust Scaled Dema | OquantOverview
The Robust Scaled DEMA indicator is a tool designed for traders seeking to identify potential trend directions in financial markets. It combines the smoothing capabilities of a Double Exponential Moving Average (DEMA) with a robust scaling mechanism to normalize the data, making it more resilient to outliers and extreme price movements. This scaling helps in generating long and short signals based on predefined thresholds, visualized through color-coded plots and bars. The indicator aims to provide a balanced view of market momentum, reducing the impact of noise while highlighting significant shifts in price behavior.
Key Factors/Components
DEMA (Double Exponential Moving Average): Serves as the core smoothing component, reducing lag compared to simple averages by emphasizing recent price action more effectively.
Robust Scaling Mechanism: Utilizes statistical measures like median and interquartile range to normalize the DEMA values, ensuring the indicator is less sensitive to extreme values or price spikes.
Thresholds: User-defined upper and lower levels that trigger long or short signals when the scaled DEMA crosses them.
Visual Elements: Includes plotted lines for the scaled DEMA and thresholds, plus color-coded candlestick bars for intuitive interpretation.
Alerts: Built-in conditions for notifying users of potential entry points for long or short positions.
How It Works
The indicator starts by applying a DEMA to the chosen price source to create a smoothed representation of the market's direction. This smoothed value is then scaled using a robust statistical approach that accounts for the distribution of recent DEMA values, centering it around a median and adjusting for variability to minimize the influence of outliers. The resulting scaled metric is compared against user-set upper and lower thresholds: crossing above the upper suggests a bullish momentum (long signal), while dipping below the lower indicates bearish conditions (short signal). A state variable tracks these conditions to color the chart accordingly, helping traders visualize regime changes. Optional alerts fire on transitions.
For Who Is Best/Recommended Use Cases
This indicator is ideal for traders who employ trend-following or momentum-based strategies and need tools that perform well in non-normal market conditions, such as during high volatility or in assets prone to spikes. Use cases include identifying entry/exit points in trending environments, confirming breakouts, or integrating into multi-indicator systems for added confirmation. Quantitative traders or those backtesting strategies will appreciate its customizable parameters for optimization.
Settings and Default Settings
Source: The price data input for calculations, such as close, open, high, or low. Default: close.
DEMA Length: Controls the period for the DEMA smoothing; shorter values increase responsiveness but may add noise, longer ones provide more lag but smoother signals. Default: 25.
Robust Scaling Length: Defines the lookback period for the scaling statistics; affects how adaptive the normalization is to recent data distributions. Default: 40.
Upper Threshold: The level above which a long signal is triggered; higher values make signals rarer but potentially more reliable. Default: 0.5.
Lower Threshold: The level below which a short signal is triggered; lower values allow for more aggressive bearish detection. Default: 0.
Conclusion
The Robust Scaled DEMA offers an outlier-resistant alternative to traditional moving average indicators, empowering traders to navigate volatile markets. By blending exponential smoothing with statistical robustness, it provides actionable insights into trend shifts while minimizing false positives from extreme events..
⚠️ Disclaimer: This indicator is intended for educational and informational purposes only. Trading/investing involves risk, and past performance does not guarantee future results. Always test and evaluate indicators/strategies before applying them in live markets. Use at your own risk.
HTF MACD Dual Zero Cross + First EMA PullbackThis script aims to get the trader on the right side of the momentum and get better entries by only alerting when price pulls back to the trader's specified EMA.
This script isnt meant to catch tops or bottoms but to trade with the momentum once it starts.
This script will alert whe nthe MACD and signal line both cross the zero line, after that the script waits for price to make a pullback and then alet either a sell or buy. Ive found this works best when you trade with the trend on a higher timeframe.
You can use whatever MACD settings you prefer and really customize this to the asset youre trading.
You can also change whether you get an alert based on a wick touch of the EMA or a candle close.
oppliger trendfollow📈 Strategy Overview: SMA25 vs SMA200 – Gap Momentum Trend Strategy
This strategy is a trend-following system designed to capture strong, accelerating uptrends while exiting early when momentum begins to fade.
It uses the relationship between two moving averages — the 25-period SMA and the 200-period SMA — and monitors the gap (distance) between them as a measure of trend strength.
🟢 Entry Conditions (Go Long)
A long position is opened only when all of the following conditions are true:
Uptrend confirmation:
The 25-period SMA is above the 200-period SMA
→ confirms a clear upward trend.
Price momentum:
The closing price is above the SMA25 line,
→ showing that the market currently trades with bullish momentum.
Trend acceleration:
The gap between SMA25 and SMA200 has been increasing for the last 5 consecutive bars.
→ mathematically:
gap_t > gap_(t-1) > gap_(t-2) > gap_(t-3) > gap_(t-4)
→ indicates that the short-term trend is pulling away from the long-term trend and accelerating upward.
✅ When all three conditions are met, the strategy enters a long trade at the close of the current candle.
🔴 Exit Conditions (Close Long)
The position is closed when the uptrend starts to lose strength:
Trend deceleration:
The gap between SMA25 and SMA200 has been shrinking for 3 consecutive bars.
→ mathematically:
gap_t < gap_(t-1) < gap_(t-2)
→ signals that the short-term moving average is converging toward the long-term average, showing weakening momentum.
🚪 When this condition is met, the strategy closes the position at market price.
⚙️ Summary of Logic
Phase Condition Meaning
Entry SMA25 > SMA200 Long-term trend is up
Entry Close > SMA25 Short-term momentum is bullish
Entry Gap rising 5 bars Trend is accelerating
Exit Gap falling 3 bars Trend is weakening
💡 Interpretation
This strategy aims to:
Enter only when a strong, accelerating uptrend is confirmed.
Stay in the trade as long as momentum remains intact.
Exit early when the market starts losing strength, before the trend fully reverses.
It works best in trending markets and helps avoid false entries during sideways or weak phases.
Twiggs Go Money Flow Enhanced [KingThies]█ OVERVIEW
The Twiggs Money Flow (TMF) is a volume-weighted momentum oscillator that
measures buying and sellistng pressure by analyzing where price closes within
each bar's true range. It's an enhanced version of Chaikin Money Flow that
uses Wilder's smoothing method, providing better trend persistence and
smoother signals.
The indicator oscillates around a zero listne:
Values above zero indicate accumulation (buying pressure)
Values below zero indicate distribution (sellistng pressure)
TMF was developed by Colistn Twiggs as an improvement over traditional money
flow indicators by incorporating true range calculations and Wilder's
exponential moving average.
█ CONCEPTS
True Range Boundaries
TMF calculates a modified true range for each bar by comparing the current
bar's high and low with the previous close:
True Range High = maximum of (previous close, current high)
True Range Low = minimum of (previous close, current low)
This accounts for overnight gaps and ensures price continuity between bars.
Average Daily Value (ADV)
The ADV represents the portion of volume attributable to buying versus sellistng:
ADV = Volume × ((Close - TR Low) - (TR High - Close)) / True Range
When price closes near the high of the true range, ADV is positive and large.
When price closes near the low, ADV is negative and large.
A close in the middle produces values near zero.
Wilder's Moving Average
Unlistke simple moving averages, Wilder's smoothing method gives more weight
to recent values while maintaining memory of historical data:
WMA = (Previous WMA × (Period - 1) + Current Value) / Period
This creates smoother trends that are less prone to whipsaws than standard
moving averages.
Final Calculation
TMF = Wilder's MA(ADV, Period) / Wilder's MA(Volume, Period)
By dividing smoothed ADV by smoothed volume, TMF normalistzes the reading and
makes it comparable across different securities and timeframes.
█ HOW TO USE
Zero listne Crossovers
The most straightforward trading signals:
A cross above zero suggests buyers are gaining control.
Consider this a bullistsh signal, especially when confirmed by price action.
A cross below zero suggests sellers are gaining control.
Consider this a bearish signal.
The longer TMF remains above or below zero, the stronger the trend.
Extreme Values
Strong positive or negative readings indicate intense buying or sellistng pressure:
Sustained high positive values (above +0.4) suggest strong accumulation
but may also indicate overbought conditions.
Sustained low negative values (below -0.4) suggest strong distribution
but may also indicate oversold conditions.
These extremes work best when used in conjunction with price levels and
support/resistance zones.
Divergences
Divergences between price and TMF often signal potential reversals:
Bearish divergence: Price makes a higher high but TMF makes a
lower high — suggests buying pressure is weakening despite rising prices.
Bullistsh divergence: Price makes a lower low but TMF makes a
higher low — suggests sellistng pressure is weakening despite fallistng prices.
Trend Confirmation
Use TMF to confirm the strength of existing trends:
In an uptrend, TMF should remain mostly positive with occasional dips below zero.
In a downtrend, TMF should remain mostly negative with occasional rises above zero.
If TMF contradicts the price trend, consider the trend weak or potentially ending.
█ FEATURES
Period (default: 21)
The lookback length for Wilder's moving average calculation:
Shorter periods (10–15) make TMF more responsive to recent changes but
increase noise and false signals.
Longer periods (30–50) create smoother readings but lag price action more
significantly.
The default 21-period setting balances responsiveness with relistabilistty.
Consider adjusting the period based on your trading timeframe and the
volatilistty of the security you're analyzing.
█ LIMITATIONS
TMF is a lagging indicator due to its smoothing method. Signals may occur
after optimal entry or exit points.
In low-volume or illistquid markets, TMF can produce erratic readings that
may not reflect true buying or sellistng pressure.
Ranging or choppy markets often generate frequent zero-listne crosses that
can lead to whipsaws.
listke all volume-based indicators, TMF's relistabilistty depends on accurate
volume data.
For securities with unrelistable volume reporting, consider using
price-based momentum indicators instead.
█ NOTES
This indicator uses area-style plotting in the original version to visualistze
the magnitude of buying and sellistng pressure. The filled area makes it easy
to see at a glance whether the market is in accumulation or distribution mode.
TMF works on any timeframe but tends to be most relistable on daily charts
where volume data is most accurate and meaningful.
█ CREDITS
Original indicator developed by
LazyBear .
Based on the Twiggs Money Flow concept from Incredible Charts:
Incredible Charts – Twiggs Money Flow .
RSI MTF Table - 12 Pairs (1,5,15)
The relative strength index measures the speed and magnitude of an asset's recent price changes. Therefore, it is considered a momentum indicator in technical analysis. Essentially, the RSI is the ratio of the days an asset's value increases to decreases over a given period.
Generally speaking, if the RSI is around 50, we do not expect strong movements. RSI above 65 or below 35 are areas we expect. In this context, this chart and the general momentum in 1-5-15 minutes allow us to quickly determine the parity we will trade. It is useful for intraday trading and scalping.
Fisher MPzFisher MPz - Multi-Period Z-Score Fisher Transform
Overview
An enhanced Fisher Transform that uses multi-period analysis and improved statistical methods to provide more reliable trading signals with the goal of fewer false positives.
Evolution Beyond Traditional Fisher Transform
While the classic Fisher Transform uses simple price normalization and basic smoothing, Fisher MPz introduces several key enhancements:
- Multi-period composite instead of single timeframe analysis
- Robust z-score normalization using median/MAD rather than mean/standard deviation
- Winsorization to handle outliers and price spikes
- Dynamic clipping that adapts to market volatility
- Kalman filtering for superior noise reduction vs. traditional EMA smoothing
These improvements result in cleaner signals, better adaptability to different market conditions, handles trending markets without over-saturation at extreme values, and reduced false signals compared to the standard Fisher Transform.
Key Features
Multi-Period Analysis
- Three Timeframe Approach: Simultaneously analyzes short (default 8), medium (default 13), and long (default 26) periods
- Weighted Composite: Combines all three periods using customizable weights for optimal signal generation
- Individual Period Display: Optional visualization of each period's Fisher Transform for deeper analysis
Advanced Statistical Methods
Robust Z-Score Calculation
- Uses median and MAD (Median Absolute Deviation) instead of mean and standard deviation
- More resistant to outliers and extreme price movements
- Provides stable normalization across varying market conditions
Winsorization
- Caps extreme price values at specified percentiles (default 5th and 95th)
- Reduces the impact of price spikes and anomalies
- Configurable lookback period for threshold calculation
Dynamic Z-Score Clipping
- Automatically adjusts clipping levels based on recent volatility
- Tighter bounds in calm markets (0.05) for precision
- Wider bounds in volatile markets (0.2) to capture significant moves
- Uses ATR-based volatility measurement
Kalman Filter Smoothing
- Optional advanced noise reduction using Kalman filtering
- Superior to traditional EMA smoothing for optimal signal extraction
- Configurable process noise (Q) and measurement noise (R) parameters
- Fallback to traditional smoothing factor available
How to Use
Basic Interpretation
- Above Zero: Bullish momentum
- Below Zero: Bearish momentum
- Extreme Values: Potential overbought/oversold conditions
- Crossovers: Entry/exit signals when composite crosses trigger line
Customizable Settings
Periods: Adjust based on your trading timeframe
- Lower values (3-10): More sensitive, suitable for scalping
- Medium values (10-20): Balanced for swing trading
- Higher values (20-50): Smoother for position trading
Weights: Customize responsiveness
- Increase short weight: More reactive to recent price changes
- Increase long weight: More stability and trend confirmation
Kalman Settings
- Lower Q (0.001-0.02): Smoother, more filtered signals
- Higher Q (0.02-0.1): More responsive to price changes
- Lower R (0.01-0.05): Trust data more, less filtering
- Higher R (0.1-1.0): More skeptical of data, more smoothing






















