Star SMC and Price action [ARule]This script is a Smart Money Concepts (SMC) + Price Action + VWAP + Swing Zones indicator.
It detects and draws:
✅ Fair Value Gaps (FVG)
✅ Imbalances (HTF FVG)
✅ BOS / CHoCH (Market Structure)
✅ Internal & Swing Structure
✅ Order Blocks (Internal + Swing)
✅ Equal High / Equal Low (EQH / EQL)
✅ Premium / Discount Zones
✅ Multi-Timeframe High & Low levels
✅ VWAP trend filter
✅ Swing High / Low zones with volume/count filter
✅ Alerts for all major SMC events
👉 Basically:
💎 “All-in-one institutional trading indicator”
✅ 1) HTF FVG / Imbalance System (First Part)
This part:
Uses multiple higher timeframes:
5m, 15m, 1H, 4H, 1D, 1W
Detects imbalance (FVG-like gaps)
Draws boxes on chart
Marks mitigated zones
Adds labels like: 5m, 15m, 1H etc.
Logic:
An imbalance forms when:
current high < previous low (gap down)
or
current low > previous high (gap up)
Then it draws a box 📦
✅ 2) Mitigation Logic (Very Important)
Your script checks when FVG is filled:
Options:
Wick filled
Body filled
Half filled
None
Example:
"Wick filled" => low <= imb.open
Meaning:
👉 Price touched the FVG → mark as mitigated.
✅ 3) Smart Money Concepts (SMC Core)
This huge section detects:
🔹 BOS (Break of Structure)
When price breaks previous swing high/low.
🔹 CHoCH (Change of Character)
Trend reversal signal.
Example:
Uptrend → break low → CHoCH bearish
Downtrend → break high → CHoCH bullish
✅ 4) Internal vs Swing Structure
Internal Structure:
Small moves (lower timeframe)
Fast signals ⚡
Swing Structure:
Major trend structure
Strong signals 💪
You can enable/disable both in settings.
✅ 5) Order Blocks (OB)
Detected when structure breaks.
Two types:
🟢 Bullish OB
🔴 Bearish OB
Logic:
Script finds last opposite candle before BOS/CHoCH.
Then draws OB box 📦
Also checks mitigation:
close > OB high → bearish OB broken
close < OB low → bullish OB broken
✅ 6) Equal High / Equal Low (Liquidity)
Detects liquidity zones:
EQH = Equal High
EQL = Equal Low
Logic:
If two highs/lows are close within ATR threshold.
Used for:
👉 Liquidity grab / stop hunt zones.
✅ 7) Fair Value Gaps (FVG) – Another System
This is separate from HTF imbalance.
Condition:
currentLow > high → bullish FVG
currentHigh < low → bearish FVG
Draws 2 boxes per FVG.
✅ 8) Premium / Discount Zones
Based on latest swing high & low:
Premium zone = top 50%
Discount zone = bottom 50%
Equilibrium = middle
Used in SMC for entries.
✅ 9) Multi-Timeframe High/Low Levels
Draws:
Previous Day High/Low
Previous Week High/Low
Previous Month High/Low
✅ 10) VWAP Filter (Your Added Block)
You added:
VWAP Line
vwapValue = ta.vwap(close)
Trend Filter
Bullish → price above VWAP
Bearish → price below VWAP
ATM / ITM / OTM logic
atm_condition = abs(close - vwap) <= 25
Meaning:
ATM = price near VWAP
ITM / OTM = based on VWAP direction
💡 This is NOT real option ATM — it's a conceptual filter.
✅ 11) Swing High / Low Zones (Last Part)
This part:
Detects swing highs & lows using pivot logic
Creates zones (boxes)
Counts touches or volume inside zone
Filters strong zones
Example:
More touches = stronger support/resistance
More volume = institutional interest
✅ What makes this script powerful 💎
It combines:
Concept Purpose
FVG / Imbalance Institutional gaps
BOS / CHoCH Trend change
Order Blocks Smart money zones
EQH/EQL Liquidity
Premium/Discount Entry zones
VWAP Trend filter
Swing Zones Support/Resistance
👉 This is almost like ICT + SMC + Volume + VWAP hybrid.
✅ If you want, I can help you:
I can:
✅ Simplify this script (remove heavy parts)
✅ Add NIFTY / BANKNIFTY option logic
✅ Add Buy/Sell signals
✅ Add scanner (BOS + VWAP + FVG)
✅ Add dashboard table
✅ Optimize performance (reduce lag)
✅ Convert VWAP → real ATM strike logic
✅ Explain any part line-by-line
Educational
SMA 200 & RSI Background A comnination of SMA200 and RSI (as a background in the chart, turning green, when RSI oversold)
RSI (Background) + SMA200 (Suntrader)Kombination aus einem Background RSI (Verfärbung Grün bei überverkauftem Bereich) mit dem SMA200
Option Levels PlottingThis script plots the levels for options of single legs and 4 vertical spreads.
EstongA Scalping Multi-TFEA *Here’s a consolidated list of warnings and advice for traders, whether you're just starting or are experienced:
⚠️ Critical Warnings
1. You can lose all your capital – Trading is not a get-rich-quick scheme. Never trade with money you can’t afford to lose.
2. Avoid leverage until you fully understand it – Leverage amplifies both gains and losses. Many traders get wiped out by over-leveraging.
3. Beware of "guaranteed profit" systems – If it sounds too good to be true, it is. No strategy works all the time.
4. Emotional trading is a career killer – Fear, greed, and revenge trading destroy accounts.
5. Don’t follow tips or "hot leads" blindly – Do your own analysis. Many influencers are secretly unloading positions onto followers.
📚 Essential Advice
Mindset & Psychology
• Treat trading like a business, not gambling. Have a plan for every trade.
• Develop patience – Wait for high-probability setups; don’t force trades.
• Accept losses as part of the game – Even the best traders have losing streaks. The key is risk management.
• Keep a trading journal – Record every trade: entry/exit reasoning, emotional state, outcome. Review weekly.
Risk Management (Non-Negotiable)
• Risk only 1-2% of your capital per trade – This protects you from ruin during a losing streak.
• Always use stop-losses – Decide your stop-loss BEFORE entering a trade.
• Never add to a losing position ("averaging down") – This is how small losses become catastrophes.
• Have a risk/reward ratio of at least 1:2 – Aim for potential profit to be at least double your potential loss.
Strategy & Education
• Master one market/strategy at a time – Don’t jump between forex, stocks, crypto, and options simultaneously.
• Backtest and forward-test any strategy before using real money.
• Understand market context – Are you in a trending or ranging market? Adjust your strategy accordingly.
• Continuously educate yourself – Markets evolve. Stay updated, but avoid constantly switching strategies.
Practical Habits
• Start with a demo account – Prove you can be consistently profitable before using real money.
• When moving to real money, start small – The psychology changes with real money on the line.
• Set trading hours and stick to them – Avoid overtrading and burnout.
• Regularly withdraw profits – Secure gains and reinforce the reality of your earnings.
🚨 Red Flags in Yourself
• Chasing losses – Trying to immediately recoup a loss leads to bigger losses.
• Overconfidence after wins – Leads to taking oversized, reckless trades.
• Ignoring your trading plan – If you’re making exceptions, you don’t have a plan.
• Blaming the market or others – You are responsible for every trade. Take ownership.
🔍 Choosing a Broker/Platform
• Regulation is crucial – Ensure they are licensed by a reputable authority (FCA, SEC, ASIC, etc.).
• Understand all fees – Spreads, commissions, overnight financing, withdrawal fees.
• Test customer support – You need them in a crisis.
• Start with a well-known, established broker – Avoid obscure platforms with offers that seem too good.
💡 Final Wisdom
• Preservation of capital is more important than making profits. Survive to trade another day.
• The market will always be there – Missing an opportunity is better than taking a bad trade.
• Trading is a marathon of consistency, not a sprint for mega-returns.
• If you're consistently losing, stop, step back, and re-evaluate. Sometimes the best trade is no trade.
Remember, approximately 90% of retail traders lose money. To be in the successful 10%, you need discipline, continuous learning, and emotional control more than a "perfect" strategy. Good luck.
Auto MA Trend RB Scalper v2.4Indicator Name
AutoMA Trend — RB Scalper
Adaptive trend-filter and regime indicator designed for 1–5 minute MNQ/NQ scalping.
What the Indicator Does
AutoMA Trend dynamically adjusts its moving average behavior based on market regime persistence.
Instead of using a fixed-length MA, the indicator adapts its smoothing speed as trends develop or weaken.
The indicator provides:
A dynamic adaptive moving average (AEMA / ARMA)
Trend regime filtering (bullish / bearish / neutral)
Trend confirmation markers (optional dots & start markers)
Trend strength scoring for context, not entries
Core Components Explained
1. Dynamic Moving Average (Main Line)
The primary line is an adaptive MA, not a fixed EMA/SMA.
Color meaning:
Blue → confirmed bullish regime
Red → confirmed bearish regime
Gray → neutral / transition / chop
Use as a directional bias filter, not an entry trigger.
User controls:
MA Type: Adaptive EMA (AEMA) or Adaptive RMA (ARMA)
Ability to show/hide the MA line entirely
2. Trend Dots (Optional)
Dots appear only after trend persistence is confirmed.
Above price → confirmed uptrend
Below price → confirmed downtrend
Dots do not signal entries
Dots indicate: “Trend has proven stability”
Use case:
Stay aligned with the dominant regime
Avoid counter-trend trades while dots persist
User control:
Dots and markers can be enabled or disabled
3. Trend Start Markers (Triangles)
Triangles mark the first bar of confirmed trend acceptance.
▲ Triangle up → confirmed bullish trend start
▼ Triangle down → confirmed bearish trend start
These are confirmation markers, not breakout signals.
4. Regime Fill (Optional)
A soft fill appears between:
Dynamic MA
EMA(10) (used only for visual reference)
Fill meaning:
Blue fill → price regime above MA
Red fill → price regime below MA
User control:
Fill can be turned on or off
5. Reset Modes (Advanced)
The indicator allows selecting what defines a regime shift:
Common choices:
Slope (default): clean trend filtering
Momentum / MACD: faster regime response
RSI / Stochastic: mean-reversion environments
None: disables dynamic resets
For MNQ/NQ scalping:
Slope or Momentum recommended
How to Use for 1–5 Minute Scalping
Recommended Workflow
Use the MA color as bias
Blue → look for longs only
Red → look for shorts only
Gray → reduce size or stand aside
Use dots as permission
Trade pullbacks with dots
Avoid fading moves while dots persist
Execute with separate tools
Order flow
Momentum bursts
Structure / VWAP / levels
This indicator does not generate entries
What This Indicator Is NOT
❌ Not a buy/sell signal generator
❌ Not a standalone trading system
❌ Not predictive
It is a context and regime filter.
Best Practices
Use on MNQ / NQ, 1–5 minute charts
Combine with:
Volume
Momentum confirmation
Session context
Reduce trades during:
Gray MA phases
Frequent color flipping
Disclaimer
This indicator is provided for educational and analytical purposes only.
It does not constitute:
Financial advice
Trading advice
A recommendation to buy or sell any instrument
Trading futures involves substantial risk and is not suitable for all participants.
Past performance does not guarantee future results.
The user is fully responsible for:
Trade decisions
Risk management
Compliance with prop firm or broker rules
Use at your own discretion.
Multi-Indicator Dashboard# Multi-Indicator Dashboard v3.7
## What Makes This Script Original?
This dashboard is **not a simple indicator mashup**. It implements a **unique multi-layer decision system** that combines three distinct methodologies into a unified framework:
1. **Ehlers' Laguerre Mathematics** - 18 weighted Laguerre filters with consensus voting
2. **Minervini's Trend Template** - Structural trend analysis using SMA relationships
3. **Defensive Voting System** - A 7-jury protection mechanism to prevent false signals
The key innovation is the **layered signal override architecture**: each layer can downgrade (but never upgrade) signals from the previous layer, creating a "safety net" that catches bull traps and false breakouts.
---
## How It Works: The 5-Layer Protection System
### Layer 1: Laguerre Consensus (Signal Generation)
The script calculates 18 Laguerre filters with gamma values from 0.10 to 0.95. Each filter "votes" bullish or bearish based on:
- Price position relative to filter
- Filter direction (rising/falling)
Votes are weighted by gamma (slower filters = higher weight). The **Effective Consensus** percentage determines the base signal strength.
### Layer 2: Market Filter (Macro Protection)
```
IF Reference Index (SPY/QQQ) < 200-day SMA
THEN Market = Bearish → Block ENTER signals
```
This prevents new entries during bear markets, regardless of individual stock strength.
### Layer 3: Regime Filter (Market Condition)
The script detects three market regimes using 7 criteria:
- ADX level (trend strength)
- DI+ vs DI- spread
- RSI position
- SMA convergence
- Volatility contraction
- Laguerre spread
**Choppy or Sideways regime** → Downgrade TREND/ENTER to CAUTION
### Layer 4: Protection Score (7-Jury System)
Seven independent "juries" vote on structural health:
| Jury | Condition | Meaning |
|------|-----------|---------|
| Laguerre | Close < Lag01 | Fast support broken |
| MACD | Histogram < 0 | Momentum negative |
| OBV | Trend = -1 | Volume selling |
| SMA20 | Close < SMA20 | Short-term trend broken |
| EMA Structure | EMA10 < SMA20 | Trend structure damaged |
| RS Line | RS < RS SMA50 | Underperforming index |
| Net Momentum | RSC < 50 | Sellers stronger than buyers |
**Scoring:**
- 0-1 points: Normal
- 2 points: Yellow Alert (TREND → WAIT)
- 3+ points: Red Alert (→ CAUTION)
### Layer 5: RSI Divergence Alert (Visual Warning)
When price approaches a 60-day high but RSI is 5+ points lower than at the previous peak, a warning icon (⚠️) appears. This **does not change signals** - it's informational only.
---
## Signal Interpretation
| Signal | Code | Meaning | Action |
|--------|------|---------|--------|
| 🟢 ENTER | 5 | Strong setup, all layers confirm | Consider entry |
| 🟢 TREND | 4 | Trend continues, structure intact | Hold position |
| 🟠 CAUTION | 3 | Warning signs present | Avoid new entries |
| 🟡 WATCH | 2 | Developing, too early | Monitor closely |
| ⚪ WAIT | 1 | Conditions unfavorable | Stay in cash |
---
## Key Indicators Explained
### RSC (Relative Strength of Change)
```
RSC = Sum of Positive Changes / Total Changes × 100
```
- RSC > 50: Buyers creating larger moves
- RSC < 50: Sellers creating larger moves
### Effective Consensus
Weighted average of 18 Laguerre filter votes. Higher gamma filters (slower, more reliable) have 2x weight compared to fast filters.
### LaRSI (Laguerre RSI)
Ehlers' smoothed RSI variant. Key zones:
- Below 0.20: Oversold (potential bottom)
- 0.30-0.55: Pullback zone (entry opportunity if turning up)
- Above 0.80: Overbought (caution)
---
## How to Use
1. **Check FINAL SIGNAL** - This is the output after all 5 layers process
2. **Read Status Row** - Shows which filter is currently active (if any)
3. **Monitor RSI Alert** - Orange color with ⚠️ means divergence detected
4. **Use Data Window** - Right-click chart → Data Window for all raw values
### Settings
- **Reference Index**: SPY for US stocks, BTCUSD for crypto
- **RS Lookback**: Period for relative strength calculation (default 50)
- **Filters can be toggled** on/off based on your strategy
---
## Important Disclaimers
- This indicator does not guarantee profits
- Past performance ≠ future results
- ENTER signal ≠ "buy immediately" - always confirm with your own analysis
- Risk management remains your responsibility
---
## Credits & Methodology Sources
- **Laguerre Filters**: John Ehlers, "Cybernetic Analysis for Stocks and Futures"
- **Trend Template**: Mark Minervini, "Trade Like a Stock Market Wizard"
- **CANSLIM**: William O'Neil, "How to Make Money in Stocks"
---
PM/ORB StrategySignals based on the Premarket high, low, first five minute high and low price lines, once the signal displayed watch for the bounce from respective lines, do not rely completely on this indicator use MACD, VWAP and RSI as confirmation
VX-CALIBR - Risk Size HUD by Ikaru-s-VX-CALIBR — Risk Size HUD by Ikaru-s-
VX-CALIBR is a minimalist, futures-focused risk sizing HUD designed for fast, precise position sizing.
Set your risk in USD, enter your stop price manually, and VX-CALIBR instantly calculates:
Stop-loss distance (points)
Optimal contract size (NQ / MNQ)
Margin usage (optional gate)
A clean neon stop-line visually marks your SL on the chart, while the HUD stays lightweight, readable, and distraction-free.
Key Features
USD-based risk sizing
Manual stop input (stable & reliable)
Automatic contract calculation (NQ / MNQ)
Neon stop-loss marker on chart
Optional margin gate & usage display
Customizable HUD size, opacity & accent color
Built for speed, clarity, and futures traders
Designed For
Nasdaq / Futures traders
Prop firm & evaluation accounts
Manual execution & market entries
Traders who value precision over clutter
Notes
VX-CALIBR is a risk management tool, not a signal or strategy.
All calculations are based on the provided stop price and live market price.
Adel Session Levels (London/NY/Tokyo)Overview This indicator is designed for SMC (Smart Money Concepts) and ICT traders who rely on session liquidity to find trade setups. It automatically marks the Open, High, Low, and Mid (Equilibrium) levels for the three major trading sessions: Tokyo (Asia), London, and New York.
Inspired by the clean visual style of the "Adel Levels" indicator, this script draws horizontal lines that extend to the right of the chart, keeping your workspace clean while making it easy to spot future reactions to past session levels.
Key Features
🛡️ Smart London Freeze Logic: Unlike standard session indicators, this script includes a "Freeze" feature for the London session. As soon as the New York session opens (default 14:30 UTC), the London High and Low levels stop updating. This preserves the true "London Range" established prior to the NY overlap, allowing you to see if NY price action respects or sweeps the original London liquidity.
🌏 UTC Default Times: The indicator comes pre-configured with the official stock exchange hours in UTC, removing the guesswork for Forex and Indices traders:
Tokyo (Asia): 00:00 - 06:00 UTC
London: 08:00 - 16:30 UTC
New York: 14:30 - 21:00 UTC
📏 Equilibrium (Mid) Levels: Automatically calculates the 50% level of each session's range. This is crucial for identifying "Discount" vs. "Premium" pricing within a specific session.
👀 Clean Visualization: Lines for the current session automatically extend into the empty space on the right (customizable distance), allowing you to plan trades before price reaches the level.
⚙️ Fully Customizable:
Toggle individual sessions on/off.
Adjust line width, colors, and text size.
Turn specific levels (Open, Mid, High/Low) on or off depending on your strategy.
How to Use
Liquidity Sweeps: Use the extended High/Low lines to identify areas where price may sweep session liquidity (Judas Swing) before reversing.
Retracements: Use the Mid (Dashed Line) as a target for retracements. If price breaks a session High, it often returns to retest the session Mid or Open.
The "London Freeze": Watch the London High/Low specifically after New York opens. Since these lines stop moving at the NY open, they serve as fixed static reference points for the initial London range.
Settings
Label Distance: Controls how far into the future the lines extend (in bars).
Timezones: All session inputs are fully adjustable to match your specific broker or strategy requirements.
Risk Disclaimer: This tool is for informational purposes only and does not constitute financial advice. Always manage your risk.
market-data[t90]Core Functionality
The dashboard tracks five key metrics across multiple time horizons (Current, 24-Hour Change, and 30-Day Trend):
Open Interest (OI): Tracks the total value of outstanding derivative contracts. Rising OI alongside rising price typically confirms a strong trend, while falling OI suggests a squeeze or trend exhaustion.
Premium/Funding: Visualizes the cost of carry or price discrepancy between Perpetual and Spot markets. This is a vital gauge for identifying extreme bullish or bearish sentiment.
Spot Volume: Real-time volume data from the underlying spot market to confirm "real" buying and selling pressure.
Perpetual Volume: High-frequency derivative volume to track speculative activity.
Perp/Spot Ratio: A unique ratio that compares speculative volume to organic spot volume. High ratios often precede periods of high volatility or potential liquidations.
Key Features
Automatic Ticker Mapping: The script intelligently detects if you are on a Spot or Perp chart and automatically fetches the corresponding data from Binance to populate the table.
Visual Trend Indicators: Uses color-coded logic to highlight short-term momentum (1-day) versus long-term trend health (30-day).
Customizable UI: Fully adjustable table positioning and sizing to fit any chart layout or screen resolution.
Live Status Check: Includes a data-integrity monitor to ensure you are viewing the most up-to-date market information.
How to Use
Spotting Divergences: If the Perpetual volume is surging while Spot volume remains flat (High Perp/Spot Ratio), the market may be over-leveraged and prone to a "flush."
Confirming Breakouts: A healthy price breakout should ideally be accompanied by rising Open Interest and positive Spot volume growth.
Sentiment Extremes: Monitor the "Premium" section; extreme positive or negative values often signal that the crowd is "all-in" on one side, hinting at a potential reversal.
Disclaimer: This tool is for informational and educational purposes only. Market data is sourced from third-party providers and may be subject to latency. Trading involves significant risk.
ADR from 50 SMA - Histogram & LabelMore inside the script
INDICATOR PURPOSE:
This indicator measures how far price has moved from the 50-period SMA
in terms of Average Daily Range (ADR). It helps identify:
- When stocks are overextended and may be due for pullback/consolidation
- Potential entry/exit points based on momentum extremes
- Position trimming opportunities when price is stretched
INTERPRETATION:
- Positive values = Price is ABOVE the 50 SMA
- Negative values = Price is BELOW the 50 SMA
- Higher absolute values = More extreme/stretched moves
- Values >2 or <-2 typically indicate overextended conditions
Macro Risk SentimentOverview
This indicator provides a simple traffic light for your trading: green means go, red means slow down.
The background color appears directly on your price chart and in the oscillator pane below. When green, macro conditions favor risk assets and you can trade with full conviction. When red, the indicator suggests reducing position sizes, tightening stops, or stepping aside entirely.
The oscillator pane shows the underlying calculation so you can see how close the market is to flipping regimes.
The Core Idea
Markets move in risk cycles. When institutional money is confident, it flows into equities, high-yield bonds, and away from safe havens. When fear takes over, money rotates into treasuries, the dollar strengthens, and volatility spikes.
This indicator reads those flows by monitoring four markets simultaneously:
Risk-On Signals (good for stocks when rising)
TLT - Long-term Treasury bonds
JNK - High-yield corporate credit
Risk-Off Signals (bad for stocks when rising)
DXY - US Dollar strength
VIX - Market volatility
When bonds and credit are strong relative to their recent history while the dollar and volatility are weak, the background turns green. You have a tailwind. When the opposite occurs, the background turns red. You are fighting the current.
How It Works
Step 1: Z-Score Normalization
Each input is converted to a z-score: how many standard deviations the current value is from its 252-day rolling average. This puts all four inputs on a comparable scale regardless of their absolute price levels.
Step 2: Composite Calculation
Macro Score = (TLT z-score + JNK z-score) minus (DXY z-score + VIX z-score)
Risk-on inputs contribute positively when elevated. Risk-off inputs subtract when elevated. The result is clamped between -1.5 and +1.5 and smoothed with EMAs.
Step 3: State Machine
The indicator uses crossover-based transitions with memory:
RISK ON triggers when the smoothed macro line crosses above its signal line.
RISK OFF triggers when the macro line crosses below its signal line, or when price breaks below its EMA while the macro value is negative (double confirmation exit).
How to Use It
Green Background - Full Steam Ahead
Macro conditions support risk-taking. This is when trend-following strategies tend to work best. Use normal position sizes, take breakout trades, and hold winners longer.
Red Background - Reduce Risk
The macro wind is against you. Consider smaller positions, quicker profit-taking, or sitting out entirely. Mean-reversion setups may work better than trend-following during these periods. Many major drawdowns occur during red regimes.
The Oscillator Pane
The colored line is the macro reading, the white line is its signal. When the colored line crosses above the signal, conditions turn bullish. When it crosses below, conditions turn bearish. The zero line represents neutral. Positive values mean macro conditions are better than the one-year average.
What Makes This Original
This implementation combines z-score normalization across multiple asset classes with a state machine approach that reduces whipsaws. The price filter acts as a circuit breaker but only triggers exits when macro conditions are also deteriorating, preventing premature exits during temporary price weakness.
Settings Guide
Main Settings
Z-Score Lookback (default 252) - Period for calculating mean and standard deviation. 252 bars equals one trading year on daily charts.
Macro EMA (default 7) - Smoothing applied to the raw composite score.
Signal EMA (default 8) - Secondary smoothing for the crossover signal line.
Price Filter
Enable Price Filter (default On) - When enabled, price breaking below the EMA triggers an exit only if the macro value is also negative.
EMA Length (default 20) - The EMA period for the price filter.
Data Sources
Each source (TLT, JNK, DXY, VIX) can be enabled or disabled and weighted from 0 to 3. Default is equal weighting (1.0) for all sources.
Limitations
This is a daily-timeframe indicator. On intraday charts, signals reflect yesterday's macro reading until the day closes.
The z-score lookback creates recency bias. What was normal over the past year may not reflect longer-term historical norms.
Intermarket correlations can change. What worked in recent decades may shift in different monetary regimes.
Not all equity drawdowns come with macro warning. Flash crashes and idiosyncratic events can occur without macro deterioration.
The indicator identifies conditions, not predictions. Green does not guarantee gains. Red does not guarantee losses.
Disclaimer
This indicator is for educational and informational purposes only. It does not constitute financial advice.
Green background does not mean buy. Red background does not mean sell. These are environmental readings to help you calibrate your risk-taking, not trade signals.
Past intermarket relationships do not guarantee future behavior. Always conduct your own research. Consider your personal risk tolerance. Never risk more than you can afford to lose.
India Union Budget Days Marker🇮🇳 India Union Budget Day Marker
This indicator marks Indian Union Budget presentation days directly on the chart using a single vertical line, making it easy to visually identify how markets behave around budget announcements.
The dates are hard-coded for historical accuracy and extended to future years based on the standard 1st February schedule.
What this indicator does
Draws one vertical line on each Union Budget day
Covers historical budget dates from 1980 onward
Marks future budget days up to the next 5 years, assuming 1st February
Works on daily and intraday charts
Does not repaint and does not rely on external data
Why this is useful
Study volatility, gaps, and trend behavior on budget days
Analyze pre-budget and post-budget price action
Identify structural changes, continuations, or reversals
Useful for investors, swing traders, and intraday traders
Customization
You can adjust:
Line color
Line style (solid, dashed, dotted)
Line thickness
Important notes
Vertical lines appear only when price data exists for that date
Future budget lines will show automatically when those dates are reached.
Past years include both interim and full budgets where applicable.
Recommended use
Combine this indicator with:
Price action analysis
Trend and bias tools
Volatility or range expansion studies
Event-based market behavior analysis
This indicator is designed to provide context, not signals.
Use it to understand when an important macro event occurred, not to predict market direction.
HFT Price Action Framework[by Abhishek]This indicator helps traders spot high-probability BUY & SELL opportunities by combining trend direction and momentum into a simple, clean visual format.
It is designed to remove noise and keep you focused on only quality trade setups.
✨ Key Features
✅ Clear BUY / SELL signals
✅ Identifies trend direction
✅ Works on all timeframes
✅ Suitable for Intraday & Swing Trading
✅ Can be used on Stocks, Indices, Crypto & Forex
📊 How to Use
🔹 BUY Signal: Appears when the trend turns bullish with strong momentum
🔹 SELL Signal: Appears when the trend turns bearish or momentum weakens
🔹 Best results when used with support & resistance or price action confirmation
🛡 Risk Management
Always use a proper stop-loss and risk management.
No indicator is 100% accurate — discipline matters more than signals.
⚠️ Disclaimer
This indicator is for educational purposes only.
It does not provide financial advice.
The creator is not responsible for any profit or loss incurred
Optimal Day Trading System🚥 How to Trade with ODTS
The indicator provides visual cues on the chart (triangles) and a real-time Status Table to help you make decisions.
Signal Definitions
Buy Signal (Green Triangle): Price is above the Sunya line and the Primary Cycle is trending up.
Strong Buy (Lime Triangle): All criteria are met, plus the Secondary Cycle has also turned bullish. This indicates "confluence".
Sell Signal (Red Triangle): Price is below the Sunya line and the Primary Cycle is trending down.
Strong Sell (Maroon Triangle): Both Primary and Secondary cycles are aligned with a price break below the Sunya line.
Real-Time Status Table
Located at the top right, this table gives you an instant "health check" of the current asset:
Price > Sunya: Confirms if the current price is above or below the FLD.
Cycle Dir: Shows the slope of the primary trend.
Position: Tells you if price is "Inside" the envelope (ranging) or "Above/Below" (overextended).
📈 Best Practices
Confluence is Key: The strongest trades occur when the Signal column in the table shows "STRONG BUY" or "STRONG SELL," meaning multiple cycles are in agreement.
Envelope Extremes: If the Status Table shows the Position as "ABOVE" or "BELOW" the envelope, be cautious about entering new trades, as the price may be overextended and due for a reversion to the Basis (mean).
Timeframe Synergy: Use the 15-minute timeframe for swing trade entries and the 1-minute or 5-minute for precise day trading executions.
Moon Declination & More [BlueprintResearch]🌒 MOON DECLINATION & MORE
A comprehensive lunar declination visualization showing Moon, Sun, and node declinations, with phase coloring, zodiac sign tracking, and future projections.
Part of the Blueprint Research open-source ephemeris project.
█ WHAT'S INCLUDED
• Moon Declination — The Moon's angular distance from the celestial equator, oscillating rapidly (~27 days)
• Sun Declination — Optional overlay showing the Sun's seasonal declination (±23.4°)
• Node Declinations — North (☊) and South (☋) node lines forming the Moon's orbital envelope
• Future Projections — Project all lines up to 500 bars into the future
• Zodiac Crossing Markers — Indicates when the North Node reaches a particular zodiac degree. Keep in mind, nodes move through the zodiac in reverse.
█ CONCEPTS
Declination measures how far north or south a celestial body appears from the celestial equator. The Moon's declination oscillates rapidly, while its maximum range shifts slowly over the 18.6-year nodal cycle.
Node Declination Envelope:
The North (☊) and South (☋) node lines mark the envelope of the Moon's orbit—the theoretical maximum northern and southern declinations the Moon can reach.
Lunar Standstills:
The 18.6-year nodal cycle determines when the Moon reaches its most extreme declinations. During a major standstill, the Moon can exceed ±28° declination. During a minor standstill, the Moon's range is limited to approximately ±18°.
Out-of-Bounds (OOB):
When the Moon moves beyond ±23.44° declination, it exceeds the Sun's maximum reach and is considered "Out of Bounds."
█ COLORING OPTIONS
Phase Coloring (Moon)
Color the Moon's declination line by lunar phase:
• New Moon (0-90°): Slate silver
• First Quarter (90-180°): Mint
• Full Moon (180-270°): Bright gold
• Last Quarter (270-360°): Soft violet
Zodiac Sign Coloring (Nodes)
Color the node lines by their zodiac sign. When enabled, a color legend appears at the top, showing all 12 signs for reference.
█ ZODIAC FEATURES
Zodiac Sign Coloring
Color the North and South Node lines according to their zodiac sign positions.
Zodiac Crossing
Marks when the North Node crosses a specific zodiac degree. Select any sign and degree (0-29) to track. The North Node moves retrograde through the zodiac over an 18.6-year cycle.
█ RESEARCH FEATURES
Standstill Thresholds
Horizontal reference lines at key declination levels:
• ±28.6° Major Standstill (peak of the 18.6-year cycle)
• ±18.3° Minor Standstill (trough of the cycle)
• ±23.4° Out-of-Bounds threshold
OOB Highlighting
Optional background shading when the Moon exceeds the OOB threshold.
Node Equatorial Crossings
Crosshair markers indicate when the node's declination crosses 0° (equatorial passage).
Reference Line Labels
Labels at projection endpoints with an adjustable offset for readability.
█ FEATURES
• Moon declination with optional lunar phase coloring
• Sun declination overlay
• North and South node declinations (☊ and ☋)
• Future projections up to 500 bars
• Zodiac sign coloring with a color legend
• Zodiac degree-crossing markers
• Node equatorial-crossing markers
• Out-of-Bounds background highlighting
• Reference line labels with offset control
• Customizable line widths and colors
• Informative tooltips for all settings
• Works on all timeframes
█ HOW TO USE
1 — Add the indicator to your chart
2 — Configure which elements to display (Moon, Sun, Nodes)
3 — Enable future projections to view upcoming declination values
4 — Enable Zodiac coloring to track node sign positions
5 — Set a Zodiac Crossing degree to mark when the North Node crosses that point
6 — Enable Standstill Thresholds to show reference lines
7 — Toggle phase coloring to visualize the lunar cycle
█ THEORY
Lunar Theory: ELP2000-82 by Chapront-Touzé & Chapront
Solar Theory: VSOP87 for Sun position and phase calculation
Reference: Meeus, "Astronomical Algorithms" (2nd Ed., 1998)
█ LIMITATIONS
• Truncated ELP2000-82 theory (~10 arcseconds precision)
• Future projections assume consistent bar timing
• Phase coloring uses 4 phases (not the 8 traditional phases)
• Mean nodes only (no perturbation corrections)
█ OPEN SOURCE
Blueprint Research Ephemeris Libraries:
• lib_elp2000_moon — Lunar position and mean node calculations
• lib_vsop_core — Solar position and coordinate utilities
• lib_ephemeris — Unified planetary API
Third-Party Libraries:
• hsvColor by @kaigouthro — HSV color utilities (MPL 2.0)
© 2025-2026 BlueprintResearch (Javonnii) • CC BY-NC-SA 4.0
5-Day & 20-Day Prior MA Lines (Gap Label)
Daily 5 & 20 Moving Average Levels
This indicator plots the Daily 5-period and Daily 20-period moving averages as horizontal levels on any timeframe. Each level starts at the first bar of the trading day and extends only to the current price, keeping the chart clean and focused on the active session.
The levels update once per day using confirmed daily data and are designed to act as intraday bias, support, and resistance references. Labels are aligned on the right side for a minimal, institutional-style presentation.
Useful for:
* Intraday trading on lower timeframes
* Identifying daily trend bias
* Mean reversion and pullback setups
* Futures, stocks, ETFs, and options
No future extension, no repainting, and no unnecessary clutter.
Chuy's Max DrawDownOutput Behavior
0% → no drawdown
-5% → 5% drop from peak
-20% → 20% max drawdown in selected period
PDH/PDL, PWH/PWL, TDH/TDL + Key Levels for Nifty50This indicator plots high-probability intraday and short-term reference zones including Previous Day High/Low (PDH/PDL), Previous Week High/Low (PWH/PWL), Today’s High/Low (TDH/TDL), and key psychological price levels such as the nearest round 1000 level along with +200, +500, and +800 extensions. All levels are displayed as zones rather than thin lines to better reflect real market interaction, liquidity, and reaction areas.
Primarily for Nifty50
GB-Numbers by AlgoKingsGB-Numbers by AlgoKings
RISK DISCLAIMER: This indicator is an analytical tool for educational purposes only, not financial advice. Trading carries substantial risk of loss. This tool does not guarantee profitable trades. Always use proper risk management and never risk more than you can afford to lose.
WHAT IS GB-NUMBERS?
GB-Numbers displays Goldbach mathematical time windows directly on the chart, marking both historical bars and future time periods where time components align with selected Goldbach numbers. Unlike other Goldbach indicators that filter price patterns, this tool shows pure time analysis - when mathematical harmonics occur regardless of price action.
Example: If minute=23 at current bar, label displays "23". If next bar at 11:35 will have minute=35, indicator projects label 60 bars forward showing when this time window will occur.
UNDERLYING METHODOLOGY
This indicator combines three analytical layers:
1. GOLDBACH NUMBER MATCHING
Uses mathematical time component analysis based on Goldbach conjecture principles:
GOLDBACH NUMBER SET:
Master list of 23 key numbers: 0, 3, 11, 17, 29, 41, 47, 53, 59, 71, 83, 89, 97, 100, 7, 14, 23, 35, 44, 50, 56, 65, 77
These numbers represent temporal harmonics derived from number theory analysis. Users can select custom subset via comma-separated list for both Future and History modes.
TIME COMPONENT CALCULATION:
For any given bar timestamp, algorithm extracts four components in selected timezone (New York or Zurich):
- Minute (m): Minute of hour (0-59)
- Hour (h): Hour of day (0-23)
- Sum (h + m): Addition of hour and minute
- Difference (|h - m|): Absolute difference between hour and minute
Example timestamp 14:35:
- m = 35
- h = 14
- h + m = 49
- |h - m| = 21
MATCHING LOGIC:
Two matching modes available:
EXACT MODE:
Number matches if ANY time component exactly equals Goldbach number:
if (m == n) or (h == n) or (h+m == n) or (|h-m| == n)
→ Exact match, display number
ALL MODE (±1 tolerance):
Number matches if ANY time component equals Goldbach number ±1:
if (m == n±1) or (h == n±1) or (h+m == n±1) or (|h-m| == n±1)
→ Near match, display number
Technical implementation:
gbMatch() function tests single number against timestamp's four components. gbMatches() loops through number array, calls gbMatch() for each, returns three arrays: all matches, exact matches, approximate matches. Display uses exact or all based on mode setting.
2. FUTURE TIME PROJECTION
Projects Goldbach matches up to 60 bars into the future:
INITIALIZATION PHASE:
When reaching barstate.islastconfirmedhistory (end of historical data), algorithm performs forward scan:
- Loops from bars_back=-1 to bars_back=-60
- Calls time("", bars_back=idx) to get future timestamps
- Tests each timestamp against selected Goldbach numbers
- Creates labels at future bar positions showing matching numbers
REAL-TIME UPDATES:
On each new bar during live trading (barstate.islast):
- Tests single timestamp 60 bars ahead (time("", bars_back=-60))
- Creates new label if matches found
- Purges oldest future label if it reached current time (last.t <= time)
- Updates all future label y-coordinates to current high for visibility
Rolling window:
Maintains constant 60-bar forward projection. As chart progresses, oldest future label converts to current bar, new label added 60 bars ahead, creating rolling wave of future time windows.
Visual management:
Future labels positioned at high price for visibility. On each bar, all future labels updated to current high (set_y(high)) so they remain visible as price moves. When future bar becomes current, label deleted from nexts array.
3. HISTORICAL BAR MARKING
Marks past bars where Goldbach matches occurred:
DETECTION:
On each new bar (time != previous time):
- Tests current bar timestamp against historical Goldbach array
- If matches found, creates label at bar's high
- Label text contains matched numbers sorted descending, newline-separated
ARRAY MANAGEMENT:
Maintains rolling history array with configurable size (0-400 bars):
- Unshifts new Bar object (contains timestamp and label reference)
- When array exceeds history limit, pops oldest and deletes label
- Enables dynamic history depth adjustment without performance degradation
VERTICAL OFFSET:
Optional vertical offset parameter (0-9) adds newlines to label text, pushing numbers higher above bar. Each increment adds one newline, creating visual separation when multiple indicators overlap.
Difference from future:
Historical labels remain at creation coordinates. Future labels dynamically adjust to current high. Historical mode optional (can be disabled), future mode default enabled.
WHY CLOSED-SOURCE?
This script protects proprietary algorithms:
- Goldbach number set: Proprietary selection of 23 specific numbers (0, 3, 11, 17, 29, 41, 47, 53, 59, 71, 83, 89, 97, 100, 7, 14, 23, 35, 44, 50, 56, 65, 77) derived from mathematical research
- Future projection engine: Rolling 60-bar forward scan using time("", bars_back=-idx) with dynamic label positioning (set_y updates), purge logic (last.t <= time), and initialization phase optimization (single loop on islastconfirmedhistory vs bar-by-bar processing)
- Dual-mode matching: Separate exact and approximate match arrays with user-selectable filtering, requiring complex conditional logic in gbMatch() that tests four time components with tolerance windows
- Label lifecycle management: Two independent Bar arrays (nexts for future, bars for history) with different update patterns - futures update y-coordinate every bar, history remains static, futures purge by timestamp comparison, history purges by array size
- Timezone abstraction: Single timezone parameter affects all time component calculations (minute, hour extraction) uniformly across historical and future projections
Standard time indicators show current time only. This script provides dual-timeline analysis with mathematically filtered time windows across past and future.
TECHNICAL COMPONENTS
Core structures:
- Bar Object: Container for timestamp (t) and label reference, used in both bars (history) and nexts (future) arrays
- Goldbach arrays: nextGbArray (user-selected for future), barGbArray (user-selected or all 23 for history)
Time component extraction:
- minute(time, timezone): Extracts minute component (0-59)
- hour(time, timezone): Extracts hour component (0-23)
- Arithmetic: h + m for sum, |h - m| for difference
Future projection:
- Initialization: for idx = -1 to -60: test time("", bars_back=idx)
- Live update: test time("", bars_back=-60) on each new bar
- Purge: if (nexts.last().t <= time) pop and delete
- Position update: for all nexts: set_y(high)
Historical marking:
- Detection: if (time != t0) test gbMatches(barGbArray, time, timezone)
- Creation: label.new(time, high, matches.join(" "))
- Purge: if (bars.size() > barHistory) pop and delete
HOW TO USE
Setup:
1. Apply to any chart (works on all symbols and timeframes)
2. Select Timezone (New York or Zurich) for Goldbach calculation
3. Configure Future section: Enable, select Exact/All mode, enter GB/CE numbers, choose color
4. Configure History section: Enable, select Exact/All mode, enter GB/CE numbers or enable "All GB/CE", set history depth, choose color
5. Adjust Text Size and Vertical Offset as needed
Chart Timeframe:
Works on any timeframe. Lower timeframes (1m-5m) show more frequent matches. Higher timeframes (1H-Daily) show fewer, potentially more significant time windows.
Interpretation:
FUTURE (Blue labels by default):
- Labels appear up to 60 bars ahead of current bar
- Numbers show which Goldbach numbers will match at that future time
- Labels move vertically with price to stay visible
- When future bar becomes current, label disappears
- Used for anticipating upcoming mathematical time windows
HISTORY (Gray labels by default):
- Labels appear on past bars where Goldbach matches occurred
- Numbers show which Goldbach numbers matched at that time
- Labels remain at bar's high price (static)
- Quantity controlled by History parameter (0-400 bars)
- Used for reviewing past mathematical time windows
Label content:
Single number (e.g., "23") = One time component matched one Goldbach number
Multiple numbers (e.g., "35 50") = Multiple time components matched different Goldbach numbers, displayed vertically stacked
No label = No Goldbach matches at that timestamp
SETTINGS EXPLAINED
Settings:
- Timezone: Choose New York or Zurich for time component calculation (chart timezone does not affect this)
- Text Size: Label text size for all numbers (Tiny, Small, Normal, Large)
Future:
- Enable: Show/hide future time projection (60 bars ahead)
- Exact: Enable for exact matches only, disable for ±1 tolerance
- GB/CE List: Comma-separated Goldbach numbers to test for future bars (e.g., "23,35")
- Color: Label color for future time windows
History:
- Enable: Show/hide historical bar marking
- Exact: Enable for exact matches only, disable for ±1 tolerance
- All GB/CE: Enable to test all 23 master Goldbach numbers
- GB/CE List: Disable "All GB/CE" to enter custom comma-separated list (e.g., "23,35")
- History: Number of past bars to show (0-400)
- Color: Label color for historical markings
- Vertical Offset: Adds newlines above numbers (0-9), pushes labels higher for multi-indicator setups
Timezone selection:
New York (America/New_York) = EST/EDT timezone
Zurich (Europe/Zurich) = CET/CEST timezone
Chart display timezone does not affect Goldbach calculations. You can view charts in any timezone while calculating Goldbach numbers in New York or Zurich time.
Exact vs All mode:
- Exact: Stricter, only shows exact matches (m=n, h=n, h+m=n, |h-m|=n)
- All: Looser, shows exact and near matches (±1 tolerance)
- Future and History have independent mode settings
Custom number selection:
Enter numbers separated by commas with no spaces: 23,35,50,77
Invalid numbers (not in master list of 23) automatically filtered out
Minimum: 1 number
Maximum: all 23 numbers (or enable "All GB/CE" for History)
Common Configurations:
- ICT Focus: Future enabled with "23,35", History disabled (clean chart, anticipatory)
- Full Analysis: Future enabled with "23,35", History enabled with "All GB/CE", History=60
- Research Mode: Future disabled, History enabled with custom numbers, History=400 (maximum lookback)
- Minimal: Both Future and History enabled with same short list like "35,65", History=20
Vertical offset usage:
If running multiple indicators that create labels at highs, use Vertical Offset to separate GB-Numbers labels. Each increment adds one newline, pushing labels progressively higher. Useful when combining with GB-Evolve or other label-based indicators.
UPDATES
This script is actively maintained. Updates released through TradingView's native update system. For technical questions, use the comment section below.
GB-FVG by AlgoKingsGB-FVG by AlgoKings
RISK DISCLAIMER: This indicator is an analytical tool for educational purposes only, not financial advice. Trading carries substantial risk of loss. This tool does not guarantee profitable trades. Always use proper risk management and never risk more than you can afford to lose.
WHAT IS GB-FVG?
GB-FVG identifies Fair Value Gaps that form during Goldbach mathematical time windows. Unlike standard FVG indicators that display all price imbalances, this tool filters for gaps created at specific time harmonics based on Goldbach number theory, highlighting institutional order flow events that occur during mathematically significant moments.
Example: At 11:35 (minute=35, hour=11, sum=46, difference=24), if minute matches Goldbach number 35 AND a three-candle gap forms, the indicator displays this FVG. Standard gaps forming at non-Goldbach times are ignored.
UNDERLYING METHODOLOGY
This indicator combines three analytical layers:
1. THREE-CANDLE FVG DETECTION
Identifies price imbalances using precise gap analysis:
BULLISH FVG:
Candle 3 (two bars back) high < Candle 1 (current) low = Gap between bars that price never traded
BEARISH FVG:
Candle 3 (two bars back) low > Candle 1 (current) high = Gap between bars that price never traded
Technical implementation:
- Uses request.security with lookahead_on to access confirmed bar data (high , low , high , low )
- For bullish FVG: Gap top = low , Gap bottom = high
- For bearish FVG: Gap top = low , Gap bottom = high
- Detects new FVGs when time exceeds previous time (new bar completed on indicator timeframe)
Bar array management:
Maintains rolling array of 10 most recent bars from indicator timeframe. On each security.isNew event, unshifts new bar and pops oldest. Enables lookback for three-bar pattern comparison without repeated security calls.
Higher timeframe precision:
When indicator timeframe exceeds chart timeframe (e.g., 1H FVG on 5m chart), hCtf and lCtf methods search backward through chart bars to find exact bar that created gap extreme, providing precise visual placement.
2. GOLDBACH TIME FILTERING
Only displays FVGs that form during Goldbach number time windows:
GOLDBACH NUMBER SET:
Master list of 23 key numbers: 0, 3, 11, 17, 29, 41, 47, 53, 59, 71, 83, 89, 97, 100, 7, 14, 23, 35, 44, 50, 56, 65, 77
These numbers represent temporal harmonics derived from number theory. Users can select all numbers or specify custom subset.
TIME COMPONENT CALCULATION:
For middle bar of three-candle pattern (bar that created the gap), algorithm extracts four components in selected timezone:
- Minute (m): Minute of hour (0-59)
- Hour (h): Hour of day (0-23)
- Sum (h + m): Addition of hour and minute
- Difference (|h - m|): Absolute difference between hour and minute
MATCHING LOGIC:
FVG only drawn if middle bar timestamp matches ANY Goldbach number ±1:
if (m == n) or (h == n) or (h+m == n) or (|h-m| == n)
→ Exact match, FVG qualifies
if (m == n±1) or (h == n±1) or (h+m == n±1) or (|h-m| == n±1)
→ Near match, FVG qualifies
Example: At 14:35, if user selected Goldbach 35:
- m = 35 → Exact match → FVG qualifies
- Gap drawn with label "35"
Filter effectiveness:
Standard FVG indicator might show 50+ gaps on 5m chart. GB-FVG shows only 5-10 gaps that align with Goldbach timing, reducing noise and highlighting mathematically significant imbalances.
3. MITIGATION TRACKING
Monitors gap fill status with body-based or wick-based options:
MITIGATION TYPES:
- Body Close: FVG considered filled when candle closes inside gap
- Wick Touch: FVG extends until touched (when "Mitigate on body close" disabled)
STATE MANAGEMENT:
- Active: Gap unfilled, box extends to future (x2 = time + offset)
- Mitigated: Price closed inside gap, box stops at mitigation bar
Progressive tracking:
On each new bar from indicator timeframe, if "Mitigate on body close" enabled:
- Bullish FVG: if close <= gap.bottom, set isMit=true, x2=time
- Bearish FVG: if close >= gap.top, set isMit=true, x2=time
Visual consequences:
Active FVGs extend dynamically to future bars. Mitigated FVGs freeze at mitigation point. Unlike standard FVG indicators that show partial fills, GB-FVG uses binary state (active/mitigated).
WHY CLOSED-SOURCE?
This script protects proprietary algorithms:
- Goldbach filtering integration: Combines gbMatches() function with FVG detection, testing middle bar timestamp (s2.t) against user-selected Goldbach array, only creating Fvg object when matches found
- Multi-timeframe precision: hCtf and lCtf methods that search through chart bars using offset calculations (ctfBarCount * idx) and mintick rounding to locate exact bar that created higher timeframe gap extreme
- Bar array synchronization: Security object maintains rolling 10-bar array with isNew flag coordination, preventing duplicate processing while enabling three-bar lookback without repeated security calls
- Time component matching: gbMatch function implementing four-component test (m, h, h+m, |h-m|) with ±1 tolerance against each Goldbach number, returning match status and exact/approximate classification
- Mitigation state machine: isMit flag with body-close detection (close <= l for bullish, close >= h for bearish) that freezes box extension (x2) at mitigation timestamp rather than current time
Standard FVG indicators show all gaps. GB-FVG adds Goldbach timing layer requiring complex timestamp extraction, component arithmetic, and match filtering before gap visualization.
TECHNICAL COMPONENTS
Core structures:
- Bar Object: Stores OHLC and timestamp for single bar from indicator timeframe
- Security Object: Manages request.security calls, maintains Bar array (size=10), tracks isNew flag, provides hCtf/lCtf precision methods
- Fvg Object: Contains gap coordinates (x, h, x2, l), Goldbach numbers text, isMit state, box drawing object
- Option Object: Centralized settings for timezone, Goldbach array, history, colors, mitigation type
Goldbach matching:
- gbMatch(n, t, timezone): Tests single Goldbach number against single timestamp's four components with ±1 tolerance
- gbMatches(nArray, t, timezone): Tests array of Goldbach numbers against timestamp, returns arrays
FVG detection:
- Bullish: if (s3.h < s1.l and gbMatches(array, s2.t) has matches) create FVG
- Bearish: if (s3.l > s1.h and gbMatches(array, s2.t) has matches) create FVG
- Label: Goldbach numbers joined with commas (e.g., "23,35,65")
Mitigation:
- if (sBodyMit and close inside gap) set isMit=true, x2=close_time
- if (not sBodyMit) always extend to future: x2 = time("", bars_back = -4)
HOW TO USE
Setup:
1. Apply to any chart (works on all symbols and timeframes)
2. Select FVG Timeframe (must be >= chart timeframe)
3. Choose Timezone (New York or Zurich) for Goldbach calculation
4. Select "All GB/CE" to use all 23 numbers, or enter custom list
5. Enter custom numbers as comma-separated values (e.g., "23,35,65,77")
6. Enable/disable "Mitigate on body close" for mitigation behavior
Chart Timeframe Requirements:
Chart timeframe must be equal to or lower than FVG Timeframe setting. For 1H FVG analysis, use 1H or lower chart (5m, 15m, 30m, 1H all valid). Cannot use 4H chart for 1H FVG.
Interpretation:
- Green box = Bullish FVG at Goldbach time (gap up, unfilled)
- Red box = Bearish FVG at Goldbach time (gap down, unfilled)
- Numbers in box = Goldbach numbers that matched middle bar timestamp
- Box extends right = Active FVG (not yet mitigated)
- Box stops = Mitigated FVG (price closed inside gap)
- Multiple numbers = Multiple time components aligned with different Goldbach numbers
Visual placement:
Box spans from gap bottom to gap top vertically. Horizontally spans from gap formation bar to current time (active) or mitigation bar (filled). Numbers display at right edge of box.
SETTINGS EXPLAINED
Settings:
- Timeframe: Select FVG detection timeframe (any timeframe >= chart TF valid)
- Timezone: Choose New York or Zurich for Goldbach time component calculation
- All GB/CE: Enable to use all 23 master Goldbach numbers
- GB/CE List: Disable "All GB/CE" to enter custom comma-separated list (e.g., "23,35,65,77")
- History: Number of FVGs to display (default: 9)
- Text Size: Label text size for Goldbach numbers (Auto, Tiny, Small, Normal, Large)
- Text: Text color for Goldbach number labels
- Up: Box color for bullish FVGs
- Down: Box color for bearish FVGs
- Mitigate on body close: Enable to stop box extension when price closes inside gap, disable to extend until current time
Timeframe selection:
Must select timeframe equal to or higher than chart. Examples:
- Chart 5m, FVG 15m = Valid
- Chart 5m, FVG 1H = Valid
- Chart 1H, FVG 15m = Invalid (error message shown)
Timezone selection:
New York (America/New_York) = EST/EDT timezone
Zurich (Europe/Zurich) = CET/CEST timezone
Chart display timezone does not affect Goldbach calculations. You can view charts in Tokyo time while calculating Goldbach numbers in New York time.
Custom number selection:
Enter numbers separated by commas with no spaces: 23,35,65,77
Invalid numbers (not in master list of 23) automatically filtered out
Minimum: 1 number (or enable "All GB/CE")
Maximum: all 23 numbers
Mitigation behavior:
- Enabled: Boxes stop extending when price closes inside gap (recommended for cleaner chart)
- Disabled: Boxes extend to current time regardless of fills (shows all historical gaps)
UPDATES
This script is actively maintained. Updates released through TradingView's native update system. For technical questions, use the comment section below.
GB-Evolve by AlgoKingsGB-Evolve by AlgoKings
RISK DISCLAIMER: This indicator is an analytical tool for educational purposes only, not financial advice. Trading carries substantial risk of loss. This tool does not guarantee profitable trades. Always use proper risk management and never risk more than you can afford to lose.
WHAT IS GB-EVOLVE?
GB-Evolve identifies potential market turning points using Goldbach mathematical timing analysis combined with price pivot detection. The indicator marks bars where time components align with specific Goldbach numbers while simultaneously forming three-bar swing patterns, suggesting confluence between mathematical time cycles and price structure.
Example: At 11:23 (hour=11, minute=23, sum=34, difference=12), if minute matches Goldbach number 23 AND price forms a swing high, the indicator marks this as a potential pivot. If confirmed by subsequent bars, the label changes color.
UNDERLYING METHODOLOGY
This indicator combines three analytical layers:
1. GOLDBACH NUMBER MATCHING
Uses mathematical time component analysis based on Goldbach conjecture principles:
GOLDBACH NUMBER SET:
Master list of 23 key numbers: 0, 3, 11, 17, 29, 41, 47, 53, 59, 71, 83, 89, 97, 100, 7, 14, 23, 35, 44, 50, 56, 65, 77
These numbers represent temporal harmonics derived from number theory analysis. Users can select all numbers or specify custom subset via comma-separated list.
TIME COMPONENT CALCULATION:
For any given bar timestamp, algorithm extracts four components in selected timezone (New York or Zurich):
- Minute (m): Minute of hour (0-59)
- Hour (h): Hour of day (0-23)
- Sum (h + m): Addition of hour and minute
- Difference (|h - m|): Absolute difference between hour and minute
Example timestamp 14:35:
- m = 35
- h = 14
- h + m = 49
- |h - m| = 21
MATCHING LOGIC:
Number matches if ANY time component equals Goldbach number ±1 (tolerance window):
- Exact match: Component exactly equals Goldbach number
- Near match: Component equals Goldbach number ±1
Technical implementation:
if (m == n) or (h == n) or (h+m == n) or (|h-m| == n)
→ Exact match
if (m == n±1) or (h == n±1) or (h+m == n±1) or (|h-m| == n±1)
→ Near match
Multi-bar window: Algorithm checks current bar, previous bar, and next bar timestamps to identify matches across pivot formation window.
2. THREE-BAR PIVOT DETECTION
Identifies swing highs and swing lows using classic three-bar pattern:
SWING HIGH:
high < high (current bar makes higher high than previous)
Pattern confirmed when: high < high > high (middle bar exceeds both neighbors)
SWING LOW:
low > low (current bar makes lower low than previous)
Pattern confirmed when: low > low < low (middle bar below both neighbors)
STATE TRANSITIONS:
- Potential Pivot: Current bar creates new extreme (high < high or low > low)
- Confirmed Pivot: Three-bar pattern completes with middle bar as pivot
Label management:
When bar forms potential pivot, creates label with matching Goldbach numbers. If bar later exceeds this extreme, label deleted (pivot invalidated). If bar confirms three-bar pattern, label color changes from gray to green (bullish) or red (bearish).
3. DYNAMIC LABEL UPDATES
Sophisticated label lifecycle management:
CREATION PHASE:
When current bar exceeds previous bar (high < high or low > low):
- Calls gbMatches() to test all Goldbach numbers against time , time , and time("", bars_back = -1)
- Collects matching numbers into array
- Sorts descending for highs, ascending for lows
- Creates label with joined numbers as text
INVALIDATION PHASE:
One bar later, if new bar exceeds previous pivot:
- high >= high → Delete high label (pivot broken)
- low <= low → Delete low label (pivot broken)
This prevents false pivots from persisting on chart.
CONFIRMATION PHASE:
Two bars later, if three-bar pattern confirmed:
- high < high > high → Change high label color to red (bearish reversal confirmed)
- low > low < low → Change low label color to green (bullish reversal confirmed)
Array management maintains only 3 most recent bars to enable this state machine.
WHY CLOSED-SOURCE?
This script protects proprietary algorithms:
- Goldbach matching engine: Custom gbMatch() function that tests four time components (m, h, h+m, |h-m|) against each Goldbach number with ±1 tolerance, implemented as nested conditional logic that processes 23 master numbers against multiple timestamp combinations
- Multi-bar window scanning: gbMatches() function that tests array of Goldbach numbers against array of timestamps (current, previous, next bars), using nested loops with break optimization when match found
- Goldbach number set: Proprietary selection of 23 specific numbers (0, 3, 11, 17, 29, 41, 47, 53, 59, 71, 83, 89, 97, 100, 7, 14, 23, 35, 44, 50, 56, 65, 77) derived from mathematical research
- State machine logic: Bar array management (size=3) with label lifecycle tracking through potential → invalidated/confirmed states, using get(1) and get(2) array indexing for historical bar access
- Label update mechanism: Dynamic textcolor changes (set_textcolor) without redrawing entire object, preserving label coordinates while updating visual state
Standard pivot indicators use price-only logic. This script combines mathematical time harmonics with price structure for confluence-based pivot identification.
TECHNICAL COMPONENTS
Core structures:
- Bar Object: Container for labelH (high label) and labelL (low label), maintained in 3-element rolling array
- Goldbach array: User-selected or full set of 23 master numbers, filtered through gbFilterArray() validation
Time component extraction:
- minute(time, timezone): Extracts minute component (0-59)
- hour(time, timezone): Extracts hour component (0-23)
- Arithmetic: h + m for sum, |h - m| for difference
Pivot detection:
- Potential: if (high < high) create label with gbMatches(gbArray, [time , time, time(-1)], timezone)
- Invalidation: if (high >= high ) delete label
- Confirmation: if (high < high > high ) change label color to red
HOW TO USE
Setup:
1. Apply to any chart (works on all symbols and timeframes)
2. Select Timezone (New York or Zurich) for Goldbach calculation
3. Choose "All GB/CE" to use all 23 numbers, or disable to enter custom list
4. Enter custom numbers as comma-separated values (e.g., "23,35,50")
5. Adjust text size and colors for labels
Chart Timeframe:
Works on any timeframe. Lower timeframes (1m-15m) show more frequent matches. Higher timeframes (1H-Daily) show fewer, potentially more significant confluences.
Interpretation:
- Gray label above bar = Potential swing high at Goldbach time (not yet confirmed)
- Gray label below bar = Potential swing low at Goldbach time (not yet confirmed)
- Red label above bar = Confirmed swing high (bearish reversal)
- Green label below bar = Confirmed swing low (bullish reversal)
- Numbers in label = Goldbach numbers that matched time components
- Multiple numbers = Multiple time components aligned with different Goldbach numbers
Label appearance:
Labels display at exact pivot point (high for swing highs, low for swing lows). Numbers sorted descending for highs, ascending for lows. Disappears if pivot invalidated by subsequent bar exceeding the extreme.
SETTINGS EXPLAINED
Settings:
- Timezone: Choose New York or Zurich for time component calculation (chart timezone does not affect this)
- All GB/CE: Enable to use all 23 master Goldbach numbers
- GB/CE List: Disable "All GB/CE" to enter custom comma-separated list (e.g., "23,35,44,50,77")
- Text Size: Label text size (Tiny, Small, Normal, Large)
- Potential Pivot: Label color for unconfirmed pivots (default: gray)
- Confirmed Pivot: Label colors for confirmed pivots (green for bullish, red for bearish)
Timezone selection:
New York (America/New_York) = EST/EDT timezone
Zurich (Europe/Zurich) = CET/CEST timezone
Your chart's display timezone does not affect Goldbach calculations. You can view charts in any timezone while calculating Goldbach numbers in New York or Zurich time.
Custom number selection:
Enter numbers separated by commas with no spaces: 23,35,50
Invalid numbers (not in master list of 23) automatically filtered out
Minimum: 1 number, Maximum: all 23 numbers
UPDATES
This script is actively maintained. Updates released through TradingView's native update system. For technical questions, use the comment section below.






















