Volume-Weighted Price Z-Score [QuantAlgo]🟢 Overview
The Volume-Weighted Price Z-Score indicator quantifies price deviations from volume-weighted equilibrium using statistical standardization. It combines volume-weighted moving average analysis with logarithmic deviation measurement and volatility normalization to identify when prices have moved to statistically extreme levels relative to their volume-weighted baseline, helping traders and investors spot potential mean reversion opportunities across multiple timeframes and asset classes.
🟢 How It Works
The indicator's core methodology lies in its volume-weighted statistical approach, where price displacement is measured through normalized deviations from volume-weighted price levels:
volumeWeightedAverage = ta.vwma(priceSource, lookbackPeriod)
logDeviation = math.log(priceSource / volumeWeightedAverage)
volatilityMeasure = ta.stdev(logDeviation, lookbackPeriod)
The script uses logarithmic transformation to capture proportional price changes rather than absolute differences, ensuring equal treatment of percentage moves regardless of price level:
rawZScore = logDeviation / volatilityMeasure
zScore = ta.ema(rawZScore, smoothingPeriod)
First, it establishes the volume-weighted baseline which gives greater weight to price levels where significant trading occurred, creating a more representative equilibrium point than simple moving averages.
Then, the logarithmic deviation measurement converts the price-to-average ratio into a normalized scale:
logDeviation = math.log(priceSource / volumeWeightedAverage)
Next, statistical normalization is achieved by dividing the deviation by its own historical volatility, creating a standardized z-score that measures how many standard deviations the current price sits from the volume-weighted mean.
Finally, EMA smoothing filters noise while preserving the signal's responsiveness to genuine market extremes:
rawZScore = logDeviation / volatilityMeasure
zScore = ta.ema(rawZScore, smoothingPeriod)
This creates a volume-anchored statistical oscillator that combines price-volume relationship analysis with volatility-adjusted normalization, providing traders with probabilistic insights into market extremes and mean reversion potential based on standard deviation thresholds.
🟢 Signal Interpretation
▶ Positive Values (Above Zero): Price trading above volume-weighted average indicating potential overvaluation relative to volume-weighted equilibrium = Caution on longs, potential mean reversion downward = Short/sell opportunities
▶ Negative Values (Below Zero): Price trading below volume-weighted average indicating potential undervaluation relative to volume-weighted equilibrium = Caution on shorts, potential mean reversion upward = Long/buy opportunities
▶ Zero Line Crosses: Mean reversion transitions where price crosses back through volume-weighted equilibrium, indicating shift from overvalued to undervalued (or vice versa) territory
▶ Extreme Positive Zone (Above +2.5σ default): Statistically rare overvaluation representing 98.8%+ confidence level deviation, indicating extremely stretched bullish conditions with high mean reversion probability = Strong correction warning/short signal
▶ Extreme Negative Zone (Below -2.5σ default): Statistically rare undervaluation representing 98.8%+ confidence level deviation, indicating extremely stretched bearish conditions with high mean reversion probability = Strong buying opportunity signal
▶ ±1σ Reference Levels: Moderate deviation zones (±1 standard deviation) marking common price fluctuation boundaries where approximately 68% of price action occurs under normal distribution
▶ ±2σ Reference Levels: Significant deviation zones (±2 standard deviations) marking unusual price extremes where approximately 95% of price action should be contained under normal conditions
🟢 Features
▶ Preconfigured Presets: Three optimized parameter sets accommodate different analytical approaches, instruments and timeframes. "Default" provides balanced statistical measurement suitable for swing trading and daily/4-hour analysis, offering deviation detection with moderate responsiveness to price dislocations. "Fast Response" delivers heightened sensitivity optimized for intraday trading and scalping on 15-minute to 1-hour charts, using shorter statistical windows and minimal smoothing to capture rapid mean reversion opportunities as they develop. "Smooth Trend" offers conservative extreme identification ideal for position trading on daily to weekly charts, employing extended statistical periods and heavy noise filtering to isolate only the most significant market extremes.
▶ Built-in Alerts: Seven alert conditions enable comprehensive automated monitoring of statistical extremes and mean reversion events. Extreme Overbought triggers when z-score crosses above the extreme threshold (default +2.5σ) signaling rare overvaluation, Extreme Oversold activates when z-score crosses below the negative extreme threshold (default -2.5σ) signaling rare undervaluation. Exit Extreme Overbought and Exit Extreme Oversold alert when prices begin reverting from these statistical extremes back toward the mean. Bullish Mean Reversion notifies when z-score crosses above zero indicating shift to overvalued territory, while Bearish Mean Reversion triggers on crosses below zero indicating shift to undervalued territory. Any Extreme Level provides a combined alert for any extreme threshold breach regardless of direction. These notifications allow you to capitalize on statistically significant price dislocations without continuous chart monitoring.
▶ Color Customization: Six visual themes (Classic, Aqua, Cosmic, Ember, Neon, plus Custom) accommodate different chart backgrounds and visual preferences, ensuring optimal contrast for identifying positive versus negative deviations across trading environments. The adjustable fill transparency control (0-100%) allows fine-tuning of the gradient area prominence between the z-score line and zero baseline, with higher opacity values creating subtle background context while lower values produce bold deviation emphasis. Optional bar coloring extends the z-score gradient directly to the indicator pane bars, providing immediate visual reinforcement of current deviation magnitude and direction without requiring reference to the plotted line itself.
*Note: This indicator requires volume data to function correctly, as it calculates deviations from a volume-weighted price average. Tickers with no volume data or extremely limited volume will not produce meaningful results, i.e., the indicator may display flat lines, erratic values, or fail to calculate properly. Using this indicator on assets without volume data (certain forex pairs, synthetic indices, or instruments with unreported/unavailable volume) will produce unreliable or no results at all. Additionally, ensure your chart has sufficient historical data to cover the selected lookback period, e.g., using a 100-bar lookback on a chart with only 50 bars of history will yield incomplete or inaccurate calculations. Always verify your chosen ticker has consistent, accurate volume information and adequate price history before applying this indicator.
Multitimeframe
Broadening Formation Structure Review ToolThis script provides an educational, checklist-based framework for studying Broadening Formations together with basic Strat-style reversal behavior and higher-timeframe direction. It is designed to show multiple structural conditions in one place so users can observe how they interact. It does not execute trades, generate signals, or provide financial advice.
What makes this script original is the integration of four components into a single logical framework:
• dynamic tracking of Broadening Formation high/low levels
• proximity evaluation relative to those levels
• classification of simple bar reversal behavior
• higher-timeframe open–close continuity checks
Instead of using these concepts as separate tools, the script combines them into a single checklist so users can see when multiple conditions occur at the same time.
Broadening Formation levels may be user-defined or automatically derived using:
• unlimited dynamic expansion
• range-limited dynamic expansion
• swing-pivot detection
• manual input mode
Users may also optionally lock levels once a structure is identified.
Proximity to BF levels can be measured in several ways, including percentage, ticks, points, dollars, ATR multiples, or expected-move multiples. The script can also detect when price takes out BF highs or lows.
The script classifies basic Strat-style price behavior, including:
• two-up / two-down moves
• outside bars
• failed 2U/2D reversals
• 2D→2U and 2U→2D reversals
A selectable higher timeframe (such as 60, 240, D, W, or M) is used to evaluate direction by comparing the higher-timeframe open and close.
The on-chart table summarizes:
• current BF High and BF Low levels
• proximity status relative to those levels
• whether BF highs or lows have been taken out
• reversal classification results
• higher-timeframe direction
• theoretical risk distance and 2R/3R projections
Optional alerts can notify when three-condition or four-condition checklist alignment occurs, based only on the logical rules visible in the script. Optional chart lines for BF levels may also be displayed.
Transparency and behavior notes
• swing pivots repaint until confirmed
• higher-timeframe direction is only final at bar close
• dynamically derived BF levels may update as price forms new extremes
This script is intended purely for market-structure study and education. It does not guarantee performance, predict outcomes, or recommend trades.
Q# ML Logistic Regression Indicator [Lite]
Q TechLabs MLLR Lite — Machine Learning Logistic Regression Trading Indicator
© Q# Tech Labs 2025 Developed by Team Q TechLabs
Overview
Q# MLLR Lite is an open-source, lightweight TradingView indicator implementing a logistic regression model to generate buy/sell signals based on engineered price features. This “lite” version is designed for broad community access and serves as a foundation for the upcoming Pro version with advanced features and integration.
Features
Logistic Regression-based buy/sell signal generation
Customizable price source input (Open, High, Low, Close, HL2, HLC3, OHLC4)
Adjustable signal threshold and smoothing parameters
Signal confidence plotted in a separate pane
Alert conditions for buy and sell signals
Fully documented, clean Pine Script (v6) code for easy customization
Installation
Open TradingView and navigate to the Pine Script editor
Create a new script and paste the full content of the Q# MLLR Lite Pine Script
Save and add to chart
Configure inputs as needed for your trading style
Licensing
Q# MLLR Lite is provided under the MIT License, promoting open use, modification, and community collaboration with attributi
Q# MLLR Lite — Machine Learning Logistic Regression Trading Indicator
© Q# Tech Labs 2025 — Developed by Team Q#
Overview
Q# MLLR Lite is an open-source, lightweight TradingView indicator implementing a logistic regression model to generate buy/sell signals based on engineered price features. This “lite” version is designed for broad community access and serves as a foundation for the upcoming Pro version with advanced features and integration.
Features
Logistic Regression-based buy/sell signal generation
Customizable price source input (Open, High, Low, Close, HL2, HLC3, OHLC4)
Adjustable signal threshold and smoothing parameters
Signal confidence plotted in a separate pane
Alert conditions for buy and sell signals
Fully documented, clean Pine Script (v6) code for easy customization
Installation
Open TradingView and navigate to the Pine Script editor
Create a new script and paste the full content of the Q# MLLR Lite Pine Script
Save and add to chart
Configure inputs as needed for your trading style
Licensing
Q# MLLR Lite is provided under the MIT License, promoting open use, modification, and community collaboration with attribution.
Copyright (c) 2025 Q# Tech Labs
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
MA-MTF-12 Overlay📊 MA-MTF-12 Overlay — Indicator Description
■ Overview
MA-MTF-12 Overlay is a multi-timeframe moving average indicator that allows you to display up to 12 moving averages (SMA / EMA) simultaneously, calculated either from the current timeframe (Local) or from higher timeframes (MTF).
It is designed to help traders visualize short-term price action and higher-timeframe market structure on a single chart, enabling clearer trend context and better decision-making.
■ Key Features
✅ Up to 12 Moving Averages
Display MA1–MA12 independently
Choose SMA or EMA for each MA
Fully customizable length, color, and line width
✅ Per-MA Local / MTF Selection
Each moving average can be set individually to:
Local – calculated on the current chart timeframe
MTF – retrieved from a higher timeframe (e.g. 1H, 4H, Daily, Weekly, Monthly)
This allows you to clearly separate entry signals from higher-timeframe trend context.
✅ Confirmed Bar Mode (Repaint Control)
When using MTF, each MA supports Confirmed Bar Mode:
ON – updates only after the higher-timeframe bar is closed (minimal repaint, backtest-friendly)
OFF – follows the current higher-timeframe bar in real time (discretionary trading)
✅ Gap Handling Option
Gaps OFF – higher-timeframe values are filled smoothly (step-style, easier to read)
Gaps ON – values appear only when a higher-timeframe bar updates (theoretical accuracy)
✅ Lightweight & Efficient Design
Each MA includes separate:
Calculation ON / OFF
Display ON / OFF
Unused MAs can be completely disabled, preventing unnecessary calculations and keeping the indicator fast even with multiple MTF sources.
■ Example Use Case
MA1–MA3: Local timeframe MAs for short-term momentum
MA4–MA6: Higher-timeframe MAs (4H / Daily / Weekly) for trend structure
MA7–MA12: Optional layers, disabled by default
This setup makes it easy to understand where price is trading within the broader market context.
■ Who This Indicator Is For
Traders who rely on multi-timeframe trend analysis
Scalpers, day traders, and swing traders who want one-chart clarity
Users concerned about repainting and indicator performance
Anyone who uses moving averages as structural reference points, not just signals
■ Technical Notes
Pine Script v5
Overlay indicator (drawn on price chart)
Multi-timeframe support via request.security()
No alerts or shapes — pure visual analysis
📊 MA-MTF-12 Overlay – インジケーター解説
■ 概要
MA-MTF-12 Overlay** は、
最大12本の移動平均(SMA / EMA)を、現在足(Local)または上位足(MTF)から自由に組み合わせて表示できる**
マルチタイムフレーム対応の高機能MAインジケーターです。
短期足の値動きから、1時間・4時間・日足・週足・月足といった
上位足のトレンド環境を、1つのチャート上で同時に把握**することを目的に設計されています。
---
■ 主な特徴
✅ 最大12本のMAを同時表示
* MA1〜MA12を個別に設定可能
* SMA / EMA をMAごとに選択
* 期間・色・太さもすべて自由にカスタマイズ
---
✅ Local / MTF をMAごとに切替可能
各MAは以下を個別に選択できます。
Local:現在のチャート時間足で計算
MTF:指定した上位足(例:1H / 4H / D / W / M)から取得
👉
短期MAはLocal、
環境認識用MAはMTF、
という役割分担を1つのインジケーターで実現できます。
---
✅ 確定足モード(リペイント制御)
MTF使用時は、確定足モードをMAごとに設定可能。
ON:上位足が確定してから更新(リペイント最小・検証向き)
OFF:上位足の進行中の値もリアルタイムで反映(裁量トレード向き)
用途に応じて柔軟に使い分けられます。
---
✅ ギャップ表示 ON / OFF
OFF:上位足MAを階段状に補完表示(視認性重視)
ON:上位足更新点のみ表示(理論重視)
---
✅ 計算ON / 表示ON を分離した軽量設計
各MAには
計算ON / OFF
表示ON / OFF**
を個別に用意。
使わないMAは計算そのものを停止できるため、
MTFを多用しても**動作が重くなりにくい設計です。
---
■ 想定される使い方
* MA1〜MA3:Local(短期〜中期の勢い把握)
* MA4〜MA6:MTF(4H・日足・週足のトレンド環境)
* MA7〜MA12:必要に応じて追加(初期はOFF)
👉
「今どの時間軸のトレンドの中にいるのか」を
MAだけで直感的に把握できます。
---
■ こんな方におすすめ
* 上位足MAを使った環境認識を重視するトレーダー
* スキャル・デイトレ・スイングを1チャートで完結させたい方
* MTFインジケーターのリペイントや重さが気になる方
* MAを「本数・役割・時間軸」で整理して使いたい方
---
■ 技術仕様
* Pine Script v5
* overlay=true(価格チャート上に表示)
* MTF対応(request.security 使用)
* アラート・シェイプなし(純粋な分析用)
---
Trend Table by DNDFXTrend Table is the latest version released in 2026. Initially, this feature was integrated into the CTR indicator. However, due to technical issues that caused errors in the main indicator, Trend Table was separated and developed as a standalone indicator to ensure stability and allow it to operate without interfering with the main system.
The Trend Table indicator is designed to provide a clear overview of market trend direction across multiple timeframes in a single, concise display. The timeframes included are M1, M3, M5, M10, M15, M30, H1, H4, and Daily. With this separation, users can monitor trend conditions from lower to higher timeframes more efficiently, consistently, and reliably.
CME Gap Tracker [captainua]CME Gap Tracker - Advanced Gap Detection & Tracking System
Overview
This indicator provides comprehensive gap detection and tracking capabilities for both consecutive bar gaps and weekly CME trading session gaps. It automatically detects gaps, tracks their fill progress in real-time, provides detailed statistics, and includes backtesting features to validate gap trading strategies. The script is optimized for CME futures trading but works with any instrument, automatically handling ticker conversion between CME futures and spot markets.
Gap Detection Types
Consecutive Bar Gaps:
Detects gaps between any two consecutive bars on the current timeframe. Two detection modes are available:
- High/Low Mode: Detects gaps when current bar's low > previous bar's high (gap up) or current bar's high < previous bar's low (gap down). This is more sensitive and detects more gaps.
- Close/Open Mode: Detects gaps when current bar's open > previous bar's close (gap up) or current bar's open < previous bar's close (gap down). This is more conservative.
Weekly CME Gaps:
Detects gaps between weekly trading sessions, specifically designed for CME futures markets. The script automatically detects the first bar of each new week and compares the current week's open with the previous week's close/high/low. This is particularly useful for tracking weekend gaps in CME futures markets where price can gap significantly between Friday close and Monday open.
Smart Ticker Detection
The script automatically converts between CME futures tickers (e.g., BTC1!, ETH1!) and spot tickers (e.g., BTCUSDT, ETHUSDT). When viewing a CME futures chart, it can automatically detect and use the corresponding spot ticker for gap analysis, and vice versa. This allows traders to:
- View CME futures but track spot market gaps
- View spot markets but track CME futures gaps
- Manually override with custom ticker specification
The ticker validation system uses caching to prevent race conditions during initial script load, ensuring reliable ticker resolution.
Gap Filtering & Tolerance
Static Tolerance:
Set minimum and maximum gap sizes as percentages (default: show only gaps > 0.333% and < 100%). This filters out noise and focuses on significant gaps.
Dynamic Tolerance:
When enabled, tolerance is calculated dynamically based on ATR (Average True Range). The formula: Dynamic Tolerance = (ATR × ATR Multiplier / Close Price) × 100%. This adapts to market volatility - in volatile markets, only larger gaps are shown; in calm markets, smaller gaps are displayed. This is particularly useful for instruments with varying volatility.
Absolute Size Filtering:
In addition to percentage filtering, gaps can be filtered by absolute price size (e.g., show only gaps > $100). This is useful for instruments where percentage alone doesn't capture significance (e.g., high-priced stocks).
Fill Confirmation System
To reduce false gap closure signals, the script requires multiple consecutive bars to confirm gap closure. The default is 2 bars, but can be adjusted from 1-10 bars. Lower values (1) confirm faster but may produce false signals from temporary wicks. Higher values (3-5) reduce false fill signals but delay confirmation. This prevents temporary price spikes from triggering false gap closure alerts.
Gap Fill Tracking
The script tracks gap fill progress in real-time:
- Fill Percentage: How much of the gap has been filled (0-100%)
- Fill Speed: Whether fill is accelerating, decelerating, or constant
- Time to Fill: For closed gaps, how many bars it took to fill
- Fill Status: Unfilled, partially filled, or fully filled
Visual Features
Heatmap Colors:
Gap colors can be adjusted based on gap size, with larger gaps appearing more intense and smaller gaps more faded.
Adaptive Line Width:
Line thickness automatically adjusts based on gap size, making larger gaps more prominent.
Age-Based Coloring:
Gaps can be color-coded by age, with newer gaps appearing brighter and older gaps more faded.
Confluence Zones:
Areas where multiple gaps overlap are highlighted with enhanced visuals, indicating stronger support/resistance zones.
Gap Statistics
A comprehensive statistics table provides:
- Total gaps created, open, and closed
- Fill rates by direction (up vs down) and size category (small, medium, large)
- Average fill time, fastest fill, slowest fill
- Oldest gap and oldest unfilled gap
- Backtesting results: success rate, reversal rate, average move after fill
- CME gap expiration statistics: Gaps expired unfilled (for Weekly CME gaps only)
Statistics can be filtered by period (All Time, Last 100/500/1000/5000 bars) and can be reset via toggle button.
Backtesting
When enabled, the script tracks price movement after gap fills:
- Price after fill: Captures price when gap closes
- Move after fill: Percentage price movement after closure
- Success/Reversal tracking: Determines if price continued in fill direction or reversed
- Success rate: Percentage of gaps where price continued in fill direction
This data helps validate gap trading strategies and understand gap fill behavior.
Gap Re-opening Detection
When enabled, the script detects when a previously filled gap reopens (price gaps back through the filled gap zone). This is useful for identifying when support/resistance levels break and can signal trend reversals.
CME-Specific Features
Monday Opening Volume Analysis:
For Weekly CME gaps detected on Monday openings, the script tracks Monday opening volume relative to average volume. Higher Monday volume ratios indicate stronger gap significance. This ratio is integrated into gap strength calculations and can be displayed in gap labels. Gaps with Monday volume > 1.5x average receive priority score boosts.
CME Gap Expiration Tracking:
Weekly CME gaps that remain unfilled beyond a configurable threshold (default 1000 bars) are automatically marked as "expired" and tracked separately in statistics. This helps identify gaps that act as strong support/resistance levels and never fill. Expired gaps are displayed with special labeling and counted in the "Gaps Expired (CME)" statistic.
CME Gap Priority Scoring Enhancement:
The priority scoring system includes special boosts for CME gaps:
- Monday gaps: +10 points (gaps detected on Monday openings)
- High Monday volume gaps: +15 points (Monday volume ratio > 1.5x average)
- Gaps at key weekly levels: +10 points (gaps aligning with previous week's high, low, or close within 0.5% tolerance)
These enhancements help prioritize the most significant CME gaps for trading decisions.
Custom Gap Zones
Traders can manually mark custom gap zones by specifying top and bottom levels. These zones are tracked like automatically detected gaps, allowing traders to:
- Mark historical gaps that weren't detected
- Create support/resistance zones based on other analysis
- Track specific price levels of interest
Multi-Timeframe Support
The script can detect gaps on higher timeframes simultaneously. For example, when viewing a 1-hour chart, it can also detect and display gaps from the weekly timeframe. This provides multi-timeframe context for gap analysis.
Alert System
Comprehensive alert system with multiple trigger types:
- Gap Creation: Alert when new gaps are detected
- Gap Closure: Alert when gaps are fully filled
- Partial Fill: Alert when gaps reach specific fill percentages (e.g., 25%, 50%, 75%, 90%)
- Approaching Closure: Alert when gaps reach high fill levels (e.g., 90%, 95%) before closing
- Gap Re-opening: Alert when previously filled gaps reopen
Alerts can be filtered to trigger only on Mondays (useful for CME weekly gaps) or any day.
Filtering Options
Gaps can be filtered by:
- Fill Status: Show all, unfilled only, partially filled only, or fully filled only
- Fill Percentage Range: Show gaps within specific fill percentage ranges
- Gap Age: Show only gaps within specific age ranges (bars)
- Gap Expiration: Automatically remove gaps older than specified number of bars (for Weekly CME gaps, uses separate CME expiration threshold)
Performance & Safety
The script includes several safety features:
- Safe array operations to prevent index out-of-bounds errors
- Memory leak prevention through proper visual object cleanup
- Ticker validation caching to prevent race conditions
- Week boundary detection for accurate CME gap identification
- Fill confirmation system to reduce false signals
- Monday opening volume analysis for CME gap strength assessment
- CME gap expiration tracking with configurable thresholds
- Priority scoring enhancement for Monday gaps, high Monday volume, and key weekly levels
Usage Recommendations
For CME Weekly Gaps:
1. Set "Gap Detection Type" to "Weekly CME"
2. View a CME futures chart (e.g., BTC1!) or enable auto-detect spot ticker
3. Set tolerance to filter gap size (default 0.333%)
4. Enable statistics to track fill rates
5. Configure alerts for gap creation/closure
For Consecutive Bar Gaps:
1. Set "Gap Detection Type" to "Consecutive Bars"
2. Choose "High/Low" for more gaps or "Close/Open" for fewer gaps
3. Adjust tolerance based on instrument volatility
4. Enable fill confirmation (2-3 bars) for more reliable signals
5. Use filtering to focus on specific gap types
For Gap Trading Strategies:
1. Enable backtesting to validate strategy performance
2. Review statistics to understand gap fill patterns
3. Use confluence zones to identify strong support/resistance
4. Configure alerts for gap events matching your strategy
5. Use custom zones to mark important levels
Technical Details:
• Pine Script v6 | Overlay indicator
• Safe array operations with index validation
• Memory leak prevention through proper object cleanup
• Ticker validation caching for reliable ticker resolution
• Works on all timeframes and instruments
• Comprehensive edge case handling
• Week boundary detection using ta.change(weekofyear)
• Fill confirmation system with configurable bars
For detailed documentation and usage instructions, see the script comments.
Chart Wolf ToolkitVWAP • PDH/PDL • NY Kill Zone
This indicator is built for traders who trade less, not more.
The Chart Wolf WLR Toolkit standardizes your chart so every decision is made from location, structure, and timing — not indicators, signals, or predictions.
It is designed to support the Wolf Liquidity Reversal (WLR) and Wolf Value Reversion (WVR) trade models.
BB6-MTF-OverlayBB6-MTF-Overlay (Multi-Bollinger Bands, MTF, Overlay)
BB6-MTF-Overlay is a Bollinger Bands overlay indicator that lets you display up to 6 independent BB sets on a single chart, with full MTF (higher timeframe) support.
It’s designed for fast multi-timeframe context—so you can see where price is relative to higher-timeframe BB levels (middle / ±1σ / ±2σ / ±3σ) while trading your current timeframe.
Key Features
Up to 6 Bollinger Band sets displayed simultaneously (overlay)
Per BB set: choose Local (current TF) or MTF (higher TF via security)
Per BB set: Gaps ON/OFF
ON: values may appear only at HTF update points (discontinuous)
OFF: HTF values are filled across lower TF bars (step-like)
Per BB set: Confirmed Bars Mode ON/OFF
ON: uses confirmed HTF values (minimizes repainting)
OFF: follows the in-progress HTF bar (useful for discretionary trading)
Per BB set: toggle visibility for Middle / ±σ1 / ±σ2 / ±σ3 independently
Custom sigma multipliers (e.g., 1.5σ, 0.6σ) for fine tuning
Separate switches for Calculation ON/OFF and Display ON/OFF
Turn off calculations to reduce load, or hide plots only
Typical Use Cases
Use higher timeframe (4H/D/W) BB middle and ±1σ as “structure walls” while executing on lower timeframe
Combine real-time tracking (e.g., 15m BB with Confirmed OFF) with stable HTF anchors (e.g., Daily/Weekly with Confirmed ON)
Keep ±2σ/±3σ OFF by default and enable them only when you need to check range expansion or extremes
Default Preset (Initial Settings)
BB1: 15m MTF (Confirmed Bars Mode OFF)
BB2: 4H MTF (Confirmed Bars Mode OFF)
BB3: Daily MTF (Confirmed Bars Mode ON)
BB4: Weekly MTF (Confirmed Bars Mode ON)
BB5: Monthly MTF (Confirmed Bars Mode ON)
BB6: Calculation OFF / Display OFF
For all active BB sets: σ1 ON by default, σ2 & σ3 OFF by default
Notes
With MTF + Confirmed OFF, band values will move until the higher timeframe bar closes (intended for discretionary use).
If the chart looks too busy, disable unused BB sets or turn off σ2/σ3.
📌 BB6-MTF-Overlay(ボリンジャーバンド6本・MTF対応・Overlay)
BB6-MTF-Overlay は、最大6セットのボリンジャーバンドを同時にチャート上へ重ねて表示できる、MTF(上位足参照)対応のBollinger Bandsインジケーターです。
🕒 15分/4時間/日足/週足/月足など、複数時間軸のボリンジャーを1つのチャートで確認できるため、環境認識(上位足の位置関係)+現在足の判断をスムーズに行えます。
✨ 主な特徴
📈 最大6本のボリンジャーバンドを同時表示(Overlay)
🔁 各BBごとに Local(現在足) / MTF(上位足) を選択可能
🧩 各BBごとに ギャップON/OFF(上位足更新点のみ表示/階段状に埋める表示)を切替
✅ 各BBごとに 確定足モードON/OFF
ON:上位足確定値(リペイント最小)
OFF:進行中の上位足にも追随(裁量補助向け)
🎚️ 各BBごとに ミドル/±σ1/±σ2/±σ3 を個別に表示ON/OFF
🔧 σ値は自由入力(例:1.5σ、0.6σ など微調整可)
⚙️ 計算ON/OFFと表示ON/OFFを分離
表示だけ消す/計算ごと止めて軽くする、の両方に対応
🧠 想定する使い方(例)
🧱 上位足(4H/日足/週足)のミドル・±1σを「壁」として見て、今の足(5分/15分)での反発・抜けを判断
🏃 「15分BB(確定足OFF)」でリアルタイム追随しつつ、「日足/週足(確定足ON)」で大局の位置を固定して確認
🔍 σ2・σ3は普段OFF、必要なときだけONにしてレンジ幅・伸び代を確認
🧾 デフォルト設定(初期状態)
1️⃣ BB1:15分MTF(確定足モードOFF)
2️⃣ BB2:4時間MTF(確定足モードOFF)
3️⃣ BB3:日足MTF(確定足モードON)
4️⃣ BB4:週足MTF(確定足モードON)
5️⃣ BB5:月足MTF(確定足モードON)
6️⃣ BB6:計算OFF/表示OFF
🎛️ 初期表示は全BB共通で「1σのみON(2σ・3σはOFF)」
⚠️ 注意事項
🔄 MTFで「確定足モードOFF(追随)」を使用する場合、上位足が確定するまで値が動くため、見え方が変化します(裁量補助向け)。
🧹 表示本数が増えるとチャートが混み合うため、必要なBBだけ表示ONにする運用がおすすめです。
Hidden Div ALERT ONLY v1.9 1. This script detects **price-anchored hidden divergences** for trend continuation, not reversals.
2. It uses **price pivots** as the reference and reads **RSI at the exact pivot candle**.
3. **Hidden Bearish**: lower high in price with higher high in RSI → bearish trend continuation.
4. **Hidden Bullish**: higher low in price with lower low in RSI → bullish trend continuation.
5. A **RefLock mechanism** prevents small or noisy pivots from overwriting the main swing.
6. **Min/Max gap filters** ensure only valid swing structures are evaluated.
7. Optional **EMA, RSI range, and volume filters** help align signals with market context.
8. The script is **alert-only**, non-repainting, and optimized for **mobile use**.
9. Designed for **set-and-forget trading**, alerts trigger execution without watching the chart.
Stoch Heat Lines Yeah, the heatmap can be confusing at first, but stochastics are way more complex than people think. Its not just “oversold” to “oversold” most of the time. Sometimes u get a double bottom, sometimes it doesnt even reach oversold. They’re not signals, they’re waves that start on lower timeframes, roll into higher ones, and eventually feed back down again.
For example, we draw a trendline on the 3H RSI and say “trend broken.” That’s technically true, but it doesn’t tell you which trend you broke. Sometimes you only break a small internal wave and RSI curves back up from ~46. Other times you break a larger structure and RSI keeps pushing toward 20.
That difference isn’t visible on a single RSI line.
By watching the top third of the heatmap, you can see which higher-timeframe waves are losing structure. If it shifts from red to orange to yellow, you likely broke a small wave. If it turns green or blue, the move is actually bearish and driven by higher-timeframe pressure.
Adaptive Strength Overlay (MTF) [BackQuant]Adaptive Strength Overlay (MTF)
A multi-timeframe RSI strength visualizer that projects oscillator “pressure” directly onto price using adaptive gradient fills between percent bands. Built to make strength, exhaustion, and regime context readable at a glance, without needing to stare at a separate oscillator panel.
Mean-Reversion mode example
What this indicator does
This indicator converts RSI strength into a chart overlay that reacts to momentum and extremes, then visualizes it as colored “pressure zones” around price.
Instead of plotting RSI in a sub-window, it:
Builds 1 to 3 symmetric percent bands above and below price.
Computes RSI strength on up to 3 different timeframes (MTF).
Smooths RSI with your selected moving average type.
Maps RSI values into discrete transparency “buckets”.
Fills between the bands with a gradient whose opacity reflects strength or exhaustion.
Displays a compact RSI table for all enabled timeframes.
Provides alert conditions for extremes and midline shifts on each timeframe.
The result is an overlay that looks like a dynamic envelope. When strength rises, the envelope “lights up” in the direction of the move. When strength becomes stretched, the outer zones become visually prominent.
Core idea: “Strength as an overlay”
RSI is normally interpreted in a separate oscillator panel. That makes context-switching slow:
You check price action.
You look down at RSI.
You mentally translate RSI into risk or trend bias.
This script removes that translation step by projecting strength directly onto the price area, using band fills as a visual language:
More visible fill = stronger strength or more extreme condition (depending on mode).
Less visible fill = weak strength or neutral state.
Two operating modes
1) Trend mode
Trend mode emphasizes strength aligned with direction:
When RSI is strong on the upside, upper bands become more visible.
When RSI is strong on the downside, lower bands become more visible.
Neutral RSI fades, so the chart de-clutters during chop.
Use Trend mode when:
You want a clean trend-following overlay.
You want to quickly see which timeframe(s) are powering the move.
You want to filter entries to moments when strength confirms direction.
2) Mean-Reversion mode
Mean-Reversion mode flips the emphasis to highlight exhaustion against the move :
Upper extremes become a “potential exhaustion” cue.
Lower extremes become a “potential exhaustion” cue.
The overlay is tuned to make stretched conditions obvious.
This is not an automatic “short overbought / long oversold” system. It is a visualization mode that makes “extended” conditions stand out faster, especially when multiple timeframes align.
How the bands work (Percent Bands)
The indicator constructs up to three symmetric envelopes around price:
Band 1: percent1 scaled by scale
Band 2: percent2 scaled by scale (optional)
Band 3: percent3 scaled by scale (optional)
The percent bands are simple deviations from the selected price source:
Upper = price * (1 + (percent * scaling)/100)
Lower = price * (1 - (percent * scaling)/100)
Why this matters:
It anchors “strength visualization” to meaningful price distance.
It makes the overlay comparable across assets because it’s percent-based.
It gives you a consistent spatial frame for reading momentum versus extension.
Multi-timeframe engine (MTF)
The script runs the same strength calculation on up to three timeframes:
Timeframe 1 uses the chart timeframe by default (empty string input).
Timeframe 2 is optional and defaults to Daily.
Timeframe 3 is optional and defaults to Weekly.
Each timeframe has:
Its own RSI period (len, len2, len3).
Its own smoothing length (slen, slen2, slen3).
The same smoothing type selection (EMA, HMA, etc).
This creates a layered view:
TF1 often reflects tactical pressure (entries/exits).
TF2 reflects structural pressure (swing context).
TF3 reflects macro bias (regime context).
When multiple timeframes agree, the fills stack and the overlay becomes visually louder. When they disagree, the overlay looks mixed or muted, which is exactly the point.
Smoothing options (why so many)
Raw RSI can be noisy. This script lets you smooth RSI with multiple MA types, which changes how “responsive” the overlay feels:
EMA/RMA smooth without lagging as hard as SMA.
HMA responds faster but can be twitchy.
LINREG can feel more “structural”.
ALMA and T3/TEMA provide heavier smoothing profiles with different lag characteristics.
This isn’t cosmetic. Your smoothing choice affects:
How early the overlay “lights up” in Trend mode.
How long extremes remain highlighted in Mean-Reversion mode.
How often fills flicker in chop.
Strength mapping (the transparency buckets)
Instead of mapping RSI to a continuous color scale, the script uses a discrete transparency ladder. That creates a clean, readable visual that avoids constant flickering.
The logic assigns two transparency values per timeframe:
Upper-side transparency responds to lower RSI zones (weak upside strength).
Lower-side transparency responds to higher RSI zones (strong upside strength).
Then the script uses those transparencies differently depending on mode:
Trend mode shows “strength aligned with direction”.
Mean-Reversion mode swaps the emphasis so “extremes” stand out as potential stretch.
You can think of it as:
Trend mode highlights continuation strength.
Mean-Reversion mode highlights potential exhaustion.
Fill stacking (how the overlay is built)
The overlay uses layered fills:
Fill from price to Band 1
Fill from Band 1 to Band 2 (if enabled)
Fill from Band 2 to Band 3 (if enabled)
Upper side uses the negative color (typically red) and lower side uses the positive color (typically green), because upper bands represent “above price” space and lower bands represent “below price” space. The intensity is controlled by the computed transparency per timeframe and selected mode.
Important behavior:
Disabling Band 2 or Band 3 can change how the stacked fills look, because you are removing fill segments.
If you want a clean look, run only Band 1.
If you want a “regime heat” look, run Bands 1–3 with higher scaling.
Table (MTF RSI dashboard)
A compact table prints RSI values for each configured timeframe:
Row labels show TF.
Values show the smoothed RSI output that drives the overlay.
Use it for quick confirmation:
If overlay looks strong but table RSI is neutral, your band settings might be too tight.
If TF3 RSI is extreme while TF1 is neutral, you are likely in a macro stretched regime with local consolidation.
Alerts (built-in)
Alerts are provided for each timeframe separately, covering:
Entering upper extreme (cross above 70)
Exiting upper extreme (cross below 70)
Entering lower extreme (cross below 30)
Exiting lower extreme (cross above 30)
Bullish midline cross (cross above 50)
Bearish midline cross (cross below 50)
This enables workflows like:
Notify when TF2 enters extreme, then wait for TF1 mean-reversion confirmation.
Notify when TF3 crosses midline, then only take TF1 trend setups in that direction.
How to use it (practical reads)
Trend mode reads
Strong continuation: TF1 and TF2 fills become clearly visible on the same side.
Healthy pullback: TF1 fades but TF2 stays visible, suggesting underlying structure remains strong.
Chop warning: fills alternate or remain mostly invisible, indicating neutral strength.
Mean-Reversion mode reads
Exhaustion zones: outer fills become prominent near the extremes, signaling stretched conditions.
Compression after extreme: fill fades while price stabilizes, suggesting “cooling off” rather than immediate reversal.
Multi-TF stretch: TF2 and TF3 extremes together often mark higher significance zones.
Recommended setup presets
Preset A: Clean trend overlay
Mode: Trend
Bands: only Band 1
Scale: 1–2
Smoothing: EMA, moderate slen (6–10)
TF2: Daily on intraday charts
Preset B: Regime and exhaustion mapper
Mode: Mean-Reversion
Bands: Bands 1–3
Scale: 2–4
Smoothing: T3 or RMA, slightly higher slen
TF2: Daily, TF3: Weekly
Limitations
This is a strength visualization tool, not a full entry/exit system.
Percent bands are not volatility-adjusted, they are distance frames. In very high vol conditions, you may need higher band percentages or higher scaling.
MTF values update on their own timeframe closes, so higher timeframes will step rather than update every bar.
SHFE Silver USD/ozPersonal utility script to view Shanghai silver prices in USD/oz along side COMEX silver.
HTF Balanced Price RangeThis script is based off of TradeForOpp's BPR indicator, but I adapted it to work on higher timeframes
Opens and RangesDisplays:
- Daily, Weekly, Monthly and Yearly opens
- High / Low / Midline(EQ) of previous day and previous week
Entropy Balance Oscillator [JOAT]
Entropy Balance Oscillator - Chaos Theory Edition
Overview
Entropy Balance Oscillator is an open-source oscillator indicator that applies chaos theory concepts to market analysis. It calculates market entropy (disorder/randomness), balance (price position within range), and various chaos metrics to identify whether the market is in an ordered, chaotic, or balanced state. This helps traders understand market regime and adjust their strategies accordingly.
What This Indicator Does
The indicator calculates and displays:
Entropy - Measures market disorder using return distribution analysis
Balance - Price position within the high-low range, normalized to -1 to +1
Lyapunov Exponent - Estimates sensitivity to initial conditions (chaos indicator)
Hurst Exponent - Measures long-term memory in price series (trend persistence)
Strange Attractor - Simulated attractor points for visualization
Bifurcation Detection - Identifies potential regime change points
Chaos Index - Combined entropy and volatility score
Market Phase - Classification as CHAOS, ORDER, or BALANCED
How It Works
Entropy is calculated using return distribution:
calculateEntropy(series float price, simple int period) =>
// Calculate returns and their absolute values
// Sum absolute returns for normalization
// Apply Shannon entropy formula: -sum(p * log(p))
float entropy = 0.0
for i = 0 to array.size(returns) - 1
float prob = math.abs(array.get(returns, i)) / sumAbs
if prob > 0
entropy -= prob * math.log(prob)
entropy
Balance measures price position within range:
calculateBalance(series float high, series float low, series float close, simple int period) =>
float range = high - low
float position = (close - low) / (range > 0 ? range : 1)
float balance = ta.ema(position, period)
(balance - 0.5) * 2 // Normalize to -1 to +1
Lyapunov Exponent estimates chaos sensitivity:
lyapunovExponent(series float price, simple int period) =>
float sumLog = 0.0
for i = 1 to period
float ratio = price > 0 ? math.abs(price / price ) : 1.0
if ratio > 0
sumLog += math.log(ratio)
lyapunov := sumLog / period
Hurst Exponent measures trend persistence:
H > 0.5: Trending/persistent behavior
H = 0.5: Random walk
H < 0.5: Mean-reverting behavior
Signal Generation
Phase changes and extreme conditions generate signals:
Chaos Phase: Normalized entropy exceeds chaos threshold (default 0.7)
Order Phase: Normalized entropy falls below order threshold (default 0.3)
Extreme Chaos: Entropy exceeds 1.5x chaos threshold
Extreme Order: Entropy falls below 0.5x order threshold
Bifurcation: Variance exceeds 2x average variance
Dashboard Panel (Top-Right)
Market Phase - Current phase (CHAOS/ORDER/BALANCED)
Entropy Level - Normalized entropy value
Balance - Current balance reading (-1 to +1)
Chaos Index - Combined chaos score percentage
Volatility - Current price volatility
Lyapunov Exp - Lyapunov exponent value
Hurst Exponent - Hurst exponent value
Chaos Score - Overall chaos assessment
Status - Current market status
Visual Elements
Entropy Line - Main oscillator showing normalized entropy
Entropy EMA - Smoothed entropy for trend reference
Balance Area - Filled area showing balance direction
Chaos/Order Thresholds - Horizontal dashed lines
Lyapunov Line - Step line showing Lyapunov exponent
Strange Attractor - Circle plots showing attractor points
Phase Space - Line showing phase space reconstruction
Phase Background - Background color based on current phase
Extreme Markers - X-cross for extreme chaos, diamond for extreme order
Bifurcation Markers - Circles at potential regime changes
Input Parameters
Entropy Period (default: 20) - Period for entropy calculation
Balance Period (default: 14) - Period for balance calculation
Chaos Threshold (default: 0.7) - Threshold for chaos phase
Order Threshold (default: 0.3) - Threshold for order phase
Lyapunov Exponent (default: true) - Enable Lyapunov calculation
Hurst Exponent (default: true) - Enable Hurst calculation
Strange Attractor (default: true) - Enable attractor visualization
Bifurcation Detection (default: true) - Enable bifurcation detection
Suggested Use Cases
Identify market regime for strategy selection (trend-following vs mean-reversion)
Watch for phase changes as potential trading environment shifts
Use Hurst exponent to assess trend persistence
Monitor chaos index for volatility regime awareness
Avoid trading during extreme chaos phases
Timeframe Recommendations
Best on 1H to Daily charts. Chaos metrics require sufficient data for meaningful calculations.
Limitations
Chaos theory concepts are applied as analogies, not rigorous mathematical implementations
Lyapunov and Hurst calculations are simplified approximations
Strange attractor visualization is conceptual
Bifurcation detection uses variance as proxy
Open-Source and Disclaimer
This script is published as open-source under the Mozilla Public License 2.0 for educational purposes. It does not constitute financial advice. Past performance does not guarantee future results. Always use proper risk management.
- Made with passion by officialjackofalltrades
#BLTA - CARE 7891🔷 #BLTA - CARE 7891: Ny session toolkit + Risk box + Confirmed levels + Asia box + Structure + Imbalances
Description:
#BLTA - CARE 7891 is an overlay toolkit 🧭🛠️ built for structured discretionary trading preparation. Its main purpose is to keep your chart reading and pre-trade planning in one place by combining time context, confirmed reference levels, liquidity framing, manual risk sizing, and context overlays (structure + imbalances).
🚫 This script is an indicator, not a strategy. It does not place orders.
🧩 Why these modules are combined (and how they work together)
This is not a “mashup for the sake of mixing”. Each module supports a specific step of a practical workflow:
🕒 Time context (new york session mapping)
Background highlights mark precise NY-time windows (day division at 17:00, london blocks, and new york blocks).
This provides the timing framework for when you typically scan, plan, or execute.
📰📅 Confirmed reference levels (previous day/week highs & lows)
Instead of plotting live extremes, this script confirms levels at defined boundaries:
Trading day: 17:00 → 17:00 NY
Weekly boundary: Sunday 17:00 NY
Lines start exactly at the candle where the high/low occurred and extend forward.
Optional “stop on hit” 🧊 freezes a level once price touches it, keeping the chart clean and realistic for forward analysis.
🈵 Asian range liquidity box (session that can cross midnight)
A dedicated Asian range container tracks high/low and an optional 50% midline.
It uses NY timestamps and safely handles sessions that cross midnight (storing the correct session date).
This gives you a daily liquidity “frame” often used for sweeps, breaks, and invalidations.
💸 Manual risk planning (trade box + lot sizing + table)
You select Entry (EP) and Stop (SL) directly on the chart using input.price(..., confirm=true) and time anchors.
The script then calculates:
💰 cash at risk from balance and risk %
📏 stop distance in pips (forex-aware pip sizing)
📦 lot size using units-per-lot and account currency inputs
🎯 target price using a reward ratio
It draws a risk box + target box and shows a compact table for quick verification.
🔁 Re-confirm mode (wizard) is included to prevent “stale” anchor points after timeframe changes or when you want a clean reset. While enabled, the risk table is replaced with a step guide and temporary EP/SL markers.
📈 Market structure overlay (1H zigzag projected to any timeframe)
A zigzag swing engine is computed on 1H via request.security() and projected onto the current chart.
Opacity is automatically reduced on non-1H charts so it stays contextual, not dominant.
Optional live extension of the last leg helps you see the active swing in progress.
📊 Imbalance map (fvg / og / vi) + optional dashboard
The script detects and draws:
🤏 fair value gaps (fvg)
👐 opening gaps (og)
🔎 volume imbalances (vi)
Optional filters allow minimum width by points / % / atr, and each imbalance type can be extended forward.
A dashboard 📱 can summarize bullish/bearish frequency and fill rates for context review.
✅ Quick start (recommended order)
Turn on 🕒 session visualization to align with NY timing.
Enable 📰 pdh/pdl and 📅 weekly highs/lows to map confirmed reference liquidity.
Use 🈵 the asian range box to frame the early-session liquidity container.
Plan your trade with 💸 risk module (pick EP/SL, verify pips + lots + target).
Add 📈 zigzag structure and 📊 imbalances only as supporting context.
⚠️ Notes & limitations
This tool is for planning and chart reading, not automated execution.
Lot sizing is an estimate based on your inputs; always confirm broker contract specs.
Some modules draw many objects (boxes/lines/tables) 🧱, which may slow very small timeframes.
Velocity Divergence Radar [JOAT]
Velocity Divergence Radar - Momentum Physics Edition
Overview
Velocity Divergence Radar is an open-source oscillator indicator that applies physics concepts to market analysis. It calculates price velocity (rate of change), acceleration (rate of velocity change), and jerk (rate of acceleration change) to provide a multi-dimensional view of momentum. The indicator also includes divergence detection and force vector analysis.
What This Indicator Does
The indicator calculates and displays:
Velocity - Rate of price change over a configurable period, smoothed with EMA
Acceleration - Rate of velocity change, showing momentum shifts
Jerk (3rd Derivative) - Rate of acceleration change, indicating momentum stability
Force Vectors - Volume-weighted acceleration representing market force
Kinetic Energy - Calculated as 0.5 * mass (volume ratio) * velocity squared
Momentum Conservation - Tracks momentum relative to historical average
Divergence Detection - Identifies when price and velocity diverge at pivots
How It Works
Velocity is calculated as smoothed rate of change:
calculateVelocity(series float price, simple int period) =>
float roc = ta.roc(price, period)
float velocity = ta.ema(roc, period / 2)
velocity
Acceleration is the change in velocity:
calculateAcceleration(series float velocity, simple int period) =>
float accel = ta.change(velocity, period)
float smoothAccel = ta.ema(accel, period / 2)
smoothAccel
Jerk is the change in acceleration:
calculateJerk(series float acceleration, simple int period) =>
float jerk = ta.change(acceleration, period)
float smoothJerk = ta.ema(jerk, period / 2)
smoothJerk
Force is calculated using F = m * a (mass approximated by volume ratio):
calculateForceVector(series float mass, series float acceleration) =>
float force = mass * acceleration
float forceDirection = math.sign(force)
float forceMagnitude = math.abs(force)
Signal Generation
Signals are generated based on velocity behavior:
Bullish Divergence: Price makes lower low while velocity makes higher low
Bearish Divergence: Price makes higher high while velocity makes lower high
Velocity Cross: Velocity crosses above/below zero line
Extreme Velocity: Velocity exceeds 1.5x the upper/lower zone threshold
Jerk Extreme: Jerk exceeds 2x standard deviation
Force Extreme: Force magnitude exceeds 2x average
Dashboard Panel (Top-Right)
Velocity - Current velocity value
Acceleration - Current acceleration value
Momentum Strength - Combined velocity and acceleration strength
Radar Score - Composite score based on velocity and acceleration
Direction - STRONG UP/SLOWING UP/STRONG DOWN/SLOWING DOWN/FLAT
Jerk - Current jerk value
Force Vector - Current force magnitude
Kinetic Energy - Current kinetic energy value
Physics Score - Overall physics-based momentum score
Signal - Current actionable status
Visual Elements
Velocity Line - Main oscillator line with color based on direction
Velocity EMA - Smoothed velocity for trend reference
Acceleration Histogram - Bar chart showing acceleration direction
Jerk Area - Filled area showing jerk magnitude
Vector Magnitude - Line showing combined vector strength
Radar Scan - Oscillating pattern for visual effect
Zone Lines - Upper and lower threshold lines
Divergence Labels - BULL DIV / BEAR DIV markers
Extreme Markers - Triangles at velocity extremes
Input Parameters
Velocity Period (default: 14) - Period for velocity calculation
Acceleration Period (default: 7) - Period for acceleration calculation
Divergence Lookback (default: 10) - Bars to scan for divergence
Radar Sensitivity (default: 1.0) - Zone threshold multiplier
Jerk Analysis (default: true) - Enable 3rd derivative calculation
Force Vectors (default: true) - Enable force analysis
Kinetic Energy (default: true) - Enable energy calculation
Momentum Conservation (default: true) - Enable momentum tracking
Suggested Use Cases
Identify momentum direction using velocity sign and magnitude
Watch for divergences as potential reversal warnings
Use acceleration to detect momentum shifts before price confirms
Monitor jerk for momentum stability assessment
Combine force and kinetic energy for conviction analysis
Timeframe Recommendations
Works on all timeframes. Higher timeframes provide smoother readings; lower timeframes show more granular momentum changes.
Limitations
Physics analogies are conceptual and not literal market physics
Divergence detection uses pivot-based lookback and may lag
Force calculation uses volume ratio as mass proxy
Kinetic energy is a derived metric, not actual energy
Open-Source and Disclaimer
This script is published as open-source under the Mozilla Public License 2.0 for educational purposes. It does not constitute financial advice. Past performance does not guarantee future results. Always use proper risk management.
- Made with passion by officialjackofalltrades
THE ELVINATORTHE ELVINATOR is my trend-following momentum indicator built on the 20 EMA, 50 EMA, and 200 EMA, designed for trading **XAUUSD during the New York session (9:30–17:00 NY time), Monday through Friday**.
**How to trade it:**
* **Trend filter:** Only take **longs above the 200 EMA** and **shorts below the 200 EMA**. This keeps trades aligned with Gold’s dominant direction.
* **Long setups:** A **20 EMA cross above the 50 EMA** signals bullish momentum. Best entries come after a pullback into the 20–50 EMA zone followed by strong continuation candles.
* **Short setups:** A **20 EMA cross below the 50 EMA** signals bearish momentum. Look for pullbacks into the EMA zone and rejection before continuation lower.
* **Timing:** Focus on NY open and high-volume moves. Avoid choppy conditions and late-session exhaustion.
* **Risk & exits:** Place stops beyond recent swings or EMA structure. Targets can be prior highs/lows or scaled with trend continuation.
THE ELVINATOR is built for **structure, patience, and disciplined execution**, allowing traders to capitalize on Gold’s volatility without chasing noise.
Nadaraya-Watson Envelope + EMA Filter (Optimized for BTC)Best Way to Use This Nadaraya-Watson EnvelopeThis indicator is not a standalone "holy grail" system — it's a powerful predictive tool that estimates where price is "likely" to go based on historical patterns.Core Idea:The orange line = predicted "fair value" or mean price path
The blue cloud = expected range (dynamic support/resistance)
Price tends to mean-revert to the orange line
Best Practices:Trade bounces in ranging markets:BUY at lower band (green) when price is below orange line
SELL at upper band (red) when price is above orange line
Target: the orange line or opposite band
Trade breakouts in trending markets:If price breaks and closes strongly outside the cloud → potential trend start
Wait for pullback to orange line for entry in trend direction
Best timeframes:5m–15m: Scalping bounces
1H–4H: Swing trading mean reversion
Add confluence for higher win rate:Only take BUY if price is above EMA 200 (uptrend bias)
Combine with volume spike or RSI oversold/overbought
Use with support/resistance levels
Risk management:Stop loss: just outside the envelope
Take profit: at orange line or next band
enjoy
MTF EMAs: 200 EMA (1hr & 15m), 8 EMA (5m)Using the 200 ema on 1hr and 15 min timeframe to ID entry points for scalping.
Bar Countdown ClockBar Countdown Clock
Description:
Displays the remaining time for the current bar on the chart. The countdown label follows the previous EMA5 price to stay stable during high-volatility markets. Font size and label position are fully customizable. Works well on BTC, Gold, Forex, and other trading instruments.
How to Use:
Add the indicator to your chart.
Adjust Clock Color, Font Size, and X Offset to suit your preference.
The label will automatically track the previous EMA5 price.
The countdown updates in real-time until the current bar closes.
Tips:
Increase X Offset if the label overlaps the current bar.
For high-volatility instruments, the label remains stable by following EMA5.
EMA Length can be adjusted to change the anchor point for the label.






















