The Institutional Anchor (Daily OC Zone)The Institutional Anchor (Daily OC)
This indicator is a high-performance tool for traders who rely on "Institutional Candles" or "Opening Candles" (OC) to define their daily bias. Built on the latest Pine Script® v6 engine, it provides a stable, non-repainting foundation for identifying key institutional support and resistance levels.
Core Features & Technical Edge
1. Dual-Mode Zone Definition
Traders have different ways of defining institutional strength. This script supports both methods to suit your specific strategy:
Body-Only Mode: Focuses on the "Real Move" by using the Open and Close of the anchor candle.
Full Range Mode (Wicks): Accounts for total liquidity grabs and volatility by including the High and Low.
2. Precision Equilibrium (Mean Threshold)
In institutional trading, the 50% level of a candle is the "Fair Value" or Mean Threshold.
Includes a customizable Midline with independent styling (Solid, Dashed, Dotted).
Automatically calculates the exact mathematical center, helping you spot high-probability rejections at the "Equilibrium" of the move.
3. Professional Visualization Suite
Global Timezone Alignment: A built-in UTC Offset ensures you can align with New York (UTC-5), London (UTC+0), or your specific exchange time without manual calculations.
Auto-Naming System: Automatically labels zones with the Day of the Week (e.g., "Monday OC") to help you track weekly cycles and "Power of 3" (Accumulation/Manipulation/Distribution).
Historical Memory: Choose to show only the current day's active zone for a clean workspace, or display historical zones to find "nested" levels from previous days.
4. Dynamic Price Action Alerts
Stay notified without being glued to the screen. The script includes pre-configured, logically consistent alert conditions:
Equilibrium Touch: Triggers the moment price interacts with the 50% Mean Threshold.
Boundary Breach: Notifies you when price exits or taps the upper or lower edges of the zone.
5. Universal Market Compatibility
BTC & Crypto Optimized: Handles 24/7 data streams flawlessly without logic gaps.
Forex Precision: Perfect for London Open or Midnight Open strategies on pairs like EUR/USD.
Non-Repainting: Once the anchor hour closes, the zone is locked, providing a reliable reference point for the rest of the trading day.
How to Use
Market Open Hour: Enter the hour (24h format) of your chosen anchor candle (e.g., 2 for 2:00 AM).
UTC Offset: Match the offset to your preferred trading session time.
Customize Style: Adjust colors, transparency, and line styles to match your chart theme.
Индикаторы и стратегии
&BAMM&
This indicator shows a break of the peak and a pullback if the trend was upward and the path changed to downward, along with an indication of the targets, and the opposite in a downward trend.
Pattern Finder Pro [M/W Recognition]Description
PatternFinder detects M patterns (bearish) and W patterns (bullish) with three variants each.
Now includes **optional volume confirmation** to filter for higher-probability setups.
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にする運用がおすすめです。
Multi-Timeframe Volume Profile - Auto HVN WallsMulti-Timeframe Volume Profile - Auto HVN Walls
Overview This indicator provides a highly flexible Volume Profile solution that operates across multiple timeframes (Session, Weekly, Monthly, Yearly). Unlike standard profiles, this tool features a unique "Auto HVN Wall" detection system. It automatically identifies meaningful High Volume Nodes (HVNs) within the profile structure and extends them forward as potential support and resistance zones, creating a dynamic map of market structure as it develops.
Key Features
Multi-Timeframe Support: Switch seamlessly between Session, Weekly, Monthly, and Yearly profiles.
Auto HVN Walls (Structure Detection): The script analyzes the profile shape in real-time. When it detects significant clusters of volume (HVNs), it automatically draws extended lines ("walls"). These walls often act as magnets or support/resistance levels where price has previously found acceptance.
Session Filtering: When in "Session" mode, you can define specific time windows (e.g., 0930-1615) to isolate Regular Trading Hours (RTH) volume, ignoring overnight data.
Auto-Scaling Width (Monthly Mode): For Monthly profiles, the histogram width dynamically changes throughout the month. It starts wide at the beginning of the month to be visible and gradually narrows as the month progresses, keeping your chart clean.
High Precision: Uses lower timeframe data (user-selectable) to build the profile, ensuring accuracy even on higher timeframe charts.
Alerts: Built-in alert conditions for price crossing the developing POC, VAH, or VAL.
How It Works
Data Accumulation: The script fetches lower timeframe volume and price data (e.g., 5-minute data on a 1-hour chart) to construct a precise volume histogram.
Wall Detection: It runs a smoothing algorithm over the volume profile. If a price level accumulates volume significantly higher than the average (controlled by the Volume Threshold Multiplier), it marks that level as a "Wall" and extends it.
Value Area: Standard Value Area High (VAH), Value Area Low (VAL), and Point of Control (POC) are calculated and displayed for the selected period.
Settings Guide
Profile Period: Choose between Session, Weekly, Monthly, or Yearly.
Session Time: (Only active in "Session" mode) Define the start and end times for the profile (e.g., 0930-1615).
Calculation Precision: Determines the lower timeframe used to build the profile. Lower is more precise but may load slower.
The Walls:
Smoothing Factor: How much to smooth the volume data before finding walls. Higher = fewer, more significant walls.
Volume Threshold: How much volume is needed to trigger a wall.
Extend Walls: If checked, walls extend infinitely to the right.
Auto-Scale Width: (Monthly Only) dynamically adjusts the profile width based on the day of the month.
Use Case This tool is ideal for auction market theorists and volume profile traders who want to visualize where value is building in real-time and identify "sticky" price levels (Walls) where the market is likely to rotate or consolidate.
Disclaimer This script and the information presented here are for educational and informational purposes only. They do not constitute financial advice, investment recommendations, or trading signals. Trading in financial markets involves a significant risk of loss and is not suitable for all investors. Past performance of any trading system or methodology is not necessarily indicative of future results. Use this tool at your own discretion and risk.
ICT Entry V1 [TS_Indie]📌 Description – ICT Entry V1
This trading system is based on price action, combined with FVG, iFVG, and liquidity, and it uses the mechanism from the indicator “Smallest Swing ” to validate swings that become liquidity.
⚙️ Core Logic & Working Mechanism
I won’t explain FVG in detail, as most traders are already familiar with it.
Let’s focus on the mechanism of iFVG instead.
The concept of iFVG is based on a supply-to-demand flip and a demand-to-supply flip within an FVG zone.
For an iFVG to be confirmed, the candle close must break through the FVG.
A wick alone does not count as a valid iFVG confirmation.
The confirmation of market structure swings uses a pivot length mechanism combined with price action.
It validates a swing by detecting a structure break formed by candles making new highs or new lows.
📈 Buy Setup
1.Liquidity sweep on the demand side, with price closing above the liquidity level.
2.A demand zone is formed as FVG and iFVG, where iFVG is located above FVG.
3.The gap between the upper box of FVG and the lower box of iFVG must be within the defined Min and Max range.
4.Market Structure must be in a Bullish trend.
5.Place a Pending Order at the upper box of FVG and set Stop Loss at the lower box of FVG (Entry and Stop Loss can be adjusted using Entry Zone and ATR-based Stop Loss).
📉 Sell Setup
1.Liquidity sweep on the supply side, with price closing below the liquidity level.
2.A supply zone is formed as FVG and iFVG, where iFVG is located below FVG.
3.The gap between the lower box of FVG and the upper box of iFVG must be within the defined Min and Max range.
4.Market Structure must be in a Bearish trend.
5.Place a Pending Order at the lower box of FVG and set Stop Loss at the upper box of FVG (Entry and Stop Loss can be adjusted using Entry Zone and ATR-based Stop Loss).
⚙️ Liquidity Sweep Conditions
➯ When a liquidity sweep occurs on the demand side, the system will start looking for Buy Setup conditions.
➯ When a liquidity sweep occurs on the supply side, the system will immediately switch to looking for Sell Setup conditions.
➯ The system will always prioritize the most recent liquidity sweep and search for setups based on that direction.
➯ The liquidity sweep condition will be invalidated when price closes back below (for demand sweep) or above (for supply sweep) the most recently swept liquidity level.
⭐ Pending Order Cancellation Conditions
A Pending Order will be canceled under the following conditions:
1.A new Price Action signal appears on either the Buy or Sell side.
2.When Time Session is enabled, the Pending Order is canceled once price exits the selected session.
🕹 Order Management Rule
When there is an active open position, the indicator restricts the creation of new Pending Orders to prevent overlapping positions.
⚠️ Disclaimer
This indicator is designed for educational and research purposes only. It does not guarantee profits and should not be considered financial advice. Trading in financial markets involves significant risk, including the potential loss of capital.
🥂 Community Sharing
If you find parameter settings that work well or produce strong statistical results, feel free to share them with the community so we can improve and develop this indicator together.
The Blessed Trader Ph. | Double EMA + RSI (20) Strategy v1.0📊 The Blessed Trader Ph.
Double EMA + RSI (20) Strategy — v1.0
1️⃣ Strategy Overview
This is a trend-following breakout strategy designed to:
Catch strong directional moves
Filter out weak trades using momentum confirmation
Control risk with ATR-based stop-loss and take-profit
It works best in trending markets such as:
Crypto (BTC, ETH, altcoins)
Forex (major & minor pairs)
Indices (NAS100, US30, SPX)
2️⃣ Indicators Used
🔹 Double EMA Channel
EMA 20 High → Dynamic resistance
EMA 20 Low → Dynamic support
These two EMAs create a price channel:
Break above → bullish strength
Break below → bearish weakness
Unlike a single EMA on close, using High & Low EMAs helps:
Reduce fake breakouts
Confirm real price expansion
🔹 RSI (20)
Measures momentum strength
RSI > 50 → bullish momentum
RSI < 50 → bearish momentum
RSI is used only as a filter, not as an overbought/oversold signal.
🔹 ATR (14)
Measures market volatility
Used to calculate:
Stop Loss (1.5 × ATR)
Take Profit (3.0 × ATR)
This makes the strategy:
Adaptive to any market
Effective across timeframes
3️⃣ Trade Rules (Very Important)
✅ BUY (LONG) Conditions
A buy trade is opened only when all conditions are met:
Price closes above EMA 20 High
RSI (20) is above 50
Candle is confirmed (bar close)
➡️ This means:
“Price has broken resistance with strong momentum.”
❌ SELL / EXIT Conditions
The long trade is closed when:
Price closes below EMA 20 Low
RSI (20) is below 50
➡️ This signals:
“Trend strength is weakening or reversing.”
🛑 Stop Loss & 🎯 Take Profit
Stop Loss = Entry − (ATR × 1.5)
Take Profit = Entry + (ATR × 3.0)
Risk–Reward ≈ 1 : 2
This protects capital and lets winners run.
4️⃣ Why This Strategy Works
✔ Trades with the trend
✔ Avoids ranging markets
✔ Uses confirmation, not prediction
✔ Non-repainting (bar close only)
✔ Works on any timeframe
5️⃣ 🔥 Why Heikin Ashi Candles Improve Results
What are Heikin Ashi candles?
Heikin Ashi candles smooth price action by averaging price data instead of using raw OHLC values.
Benefits for THIS strategy:
✅ 1. Cleaner Trend Detection
Fewer false EMA breakouts
Smoother closes above EMA High
Stronger continuation signals
✅ 2. Reduced Whipsaws
RSI stays more stable
Fewer fake buy signals during consolidation
✅ 3. Better Trade Holding
Keeps you in trends longer
Avoids early exits caused by noise
6️⃣ How to Use Heikin Ashi with This Strategy
On TradingView:
Open your chart
Click Candles
Select Heikin Ashi
Apply the strategy
📌 Important Tip
EMAs & RSI will now be calculated using Heikin Ashi data
This is ideal for trend-following, not scalping ranges
7️⃣ Best Settings & Recommendations
⏱ Timeframes
5m / 15m → Crypto & Forex intraday
1H / 4H → Swing trading
Daily → Position trading
📈 Market Conditions
Best in strong trends
Avoid low-volatility ranges
🎯 Pro Tip
Combine with:
Higher-timeframe trend bias
Session filter (London / New York)
Volume confirmation
8️⃣ Final Advice from
🙏 The Blessed Trader Ph.
“This strategy doesn’t predict — it confirms.
Be patient. Wait for clean Heikin Ashi closes.
Trade less, but trade better.”
Gold Macro Projection ModelGOLD MACRO PROJECTION MODEL
Multi-Factor Fair Value Estimation for Gold
OVERVIEW
The Gold Macro Projection Model estimates gold's fair value based on its historical relationships with key macroeconomic drivers. By synthesizing data from silver , M2 money supply , the US Dollar Index , TIPS (real rates proxy) , and major equity indices , this indicator projects where gold should theoretically be trading—helping traders identify potential overvaluation and undervaluation conditions.
HOW IT WORKS
This indicator employs three complementary projection methodologies :
Correlation-Weighted Z-Score Composite (50% weight)
Calculates rolling correlations between gold and each input factor. Factors with stronger correlations receive more influence. Each factor is normalized to a z-score, combined into a composite, then converted back to gold's price scale.
Silver/Gold Ratio Mean Reversion (35% weight)
The silver/gold ratio historically exhibits mean-reverting behavior. This component projects gold's implied price based on current silver prices and the historical average ratio.
M2 Money Supply Relationship (15% weight)
Gold tracks monetary expansion over long time horizons. This anchors the projection to the fundamental relationship between gold and the monetary base.
INPUT FACTORS
Silver — Strong positive correlation; precious metals move together
M2 Money Supply — Positive correlation; gold as inflation hedge
US Dollar Index (DXY) — Typically negative correlation; inverse relationship
TIPS ETF — Real interest rate proxy; gold responds to real yields
Equity Indices — Variable correlation; risk-on/risk-off dynamics
VISUAL ELEMENTS
Yellow Line — Actual gold price
Aqua Line — Projected fair value
Green Fill — Gold trading below projection (potentially undervalued)
Red Fill — Gold trading above projection (potentially overvalued)
Aqua Bands — Standard deviation envelope around projection
INFO TABLE
The indicator displays a real-time information panel showing:
Current actual vs. projected price
Divergence percentage and Z-score
Rolling correlations for each factor
Dynamic weight allocation
Buy/Sell signal based on divergence extremes
SIGNAL INTERPRETATION
STRONG BUY — Z-score below -2 (extremely undervalued)
BUY — Z-score between -2 and -1 (moderately undervalued)
NEUTRAL — Z-score between -1 and +1 (fairly valued)
SELL — Z-score between +1 and +2 (moderately overvalued)
STRONG SELL — Z-score above +2 (extremely overvalued)
SETTINGS
Correlation Period — Lookback for correlation calculations (default: 60)
Regression Period — Lookback for mean/standard deviation (default: 120)
Smoothing Period — EMA smoothing for projection line (default: 10)
Auto Weights — Toggle between correlation-based or manual weights
Band Multiplier — Standard deviation multiplier for bands (default: 1.5)
ALERTS
Gold Extremely Undervalued — Z crosses below -2
Gold Extremely Overvalued — Z crosses above +2
Gold Crossed Above Projection
Gold Crossed Below Projection
BEST PRACTICES
Use on daily timeframe for most reliable signals
Combine with the companion Gold Divergence Oscillator for timing
Disclaimer: This indicator is for educational purposes only. Past correlations do not guarantee future relationships. Always use proper risk management.
HaP RSIComprehensive Guide to HaP RSI Indicator
Introduction
The HaP RSI indicator is a custom technical analysis tool designed to replicate the logic and structure of the HaP MACD indicator but applied to the Relative Strength Index (RSI). This indicator combines traditional RSI concepts with advanced smoothing techniques, dynamic signal generation, and visual cues to help traders identify potential entry and exit points, trend strength, and momentum shifts.
This document provides an exhaustive explanation of the indicator's logic, its components, and practical strategies for trading with it.
Logic and Structure of HaP RSI
The HaP RSI indicator is built on the foundation of the RSI oscillator, which measures the speed and change of price movements to identify overbought and oversold conditions. The indicator enhances RSI by incorporating the following elements:
RSI Calculation: Uses a customizable length (default 10) and allows selection of smoothing type (EMA or SMA) for flexibility.
Signal Line: A moving average of the RSI (default length 9) that acts as a reference for crossovers and trend confirmation.
DEMA Logic: Double Exponential Moving Average applied to RSI and its signal line to generate dynamic dot signals for entries and exits.
Visual Elements: Midline at 50, Overbought/Oversold levels at 70 and 30, color-coded dots (Blue, Green, Orange, Red) for intuitive interpretation.
Conditions and Signal Generation
The indicator uses a sophisticated set of conditions to determine market states and generate actionable signals:
Buy Condition: Triggered when the DEMA of RSI is above the DEMA of its signal line AND the DEMA signal line is rising. This indicates strengthening bullish momentum.
First Signal Dot: Appears as a Blue dot when the buy condition becomes true for the first time after being false. This marks the start of a potential bullish phase.
Ongoing Signal Dot: Appears as Green if RSI is rising or Orange if RSI is falling while the buy condition remains true. This provides real-time feedback on momentum strength.
Exit Dot: Appears as Red when the buy condition turns false after being true, signaling a potential end to the bullish phase.
Crossovers: RSI crossing above its signal line (bullish) or below (bearish) are calculated but hidden by default, offering additional confirmation if enabled.
Trading Strategies Using HaP RSI
The HaP RSI indicator can be used in multiple ways to enhance trading decisions. Below are detailed strategies and best practices:
1. Entry Strategies
Enter long positions when a Blue dot appears, confirming the start of bullish momentum. Ideally, combine this with RSI above the midline (50) and price action breaking resistance.
Add to positions or scale in when Green dots appear, indicating continued bullish strength.
2. Exit Strategies
Exit or tighten stops when a Red dot appears, signaling weakening momentum.
Consider partial exits on Orange dots if momentum slows but the trend remains intact.
3. Trend Confirmation
Use the midline (50) as a regime filter: RSI above 50 generally favors long trades, while below 50 favors shorts.
Overbought/Oversold levels (70/30) can help identify exhaustion points for reversals or caution zones.
4. Risk Management
Always combine HaP RSI signals with stop-loss placement based on recent swing lows/highs.
Avoid chasing signals in low-volatility environments; confirm with volume or higher timeframe trend.
Advanced Usage and Best Practices
Combine HaP RSI with other indicators like moving averages or price action patterns for confluence.
Use alerts for Blue and Red dots to automate monitoring and reduce missed opportunities.
Backtest the indicator on multiple timeframes (H1 recommended) to optimize settings for your trading style.
Summary
HaP RSI is a powerful tool that blends RSI's simplicity with advanced signal logic, making it suitable for trend-following, momentum trading, and swing strategies. Its visual clarity and dynamic alerts allow traders to act decisively while managing risk effectively.
VolMo Algorithm [Pro]VolMo Algorithm - Volume Momentum Oscillator
📊 Overview
VolMo Algorithm is a professional-grade composite momentum oscillator that synthesizes three critical market dimensions into a single, unified signal designed for institutional-level analysis.
This indicator was engineered to cut through market noise by fusing:
Volatility Band Analysis - Mean reversion detection through dynamic price envelopes
Dual EMA Momentum - Trend identification via fast/slow crossover mechanics
Swing Structure Recognition - Context awareness through pivot-based structure
⚙️ How It Works
The Composite Signal Formula
text
VolMo = (Momentum Score × MD Weight) + (Band Position Score × DTB Weight)
Component Description
Momentum Score Normalized momentum (Fast EMA - Slow EMA) expressed in standard deviations
Band Position Score Price location within volatility bands indicating stretch/compression
Signal Interpretation
Value Range Market State
> 0 Bullish momentum bias
< 0 Bearish momentum bias
> +2.0 Overbought (mean reversion likely)
< -2.0 Oversold (mean reversion likely)
🎯 Key Features
✅ Adaptive Histogram - Color-coded by momentum direction AND acceleration
Bright colors = Momentum accelerating
Dim colors = Momentum decelerating
✅ Signal Line Crossovers - Early warning for trend changes
✅ Overbought/Oversold Zones - Statistical extremes for mean reversion plays
✅ Triple Confirmation System - Signals when momentum, price, AND bands align
✅ Real-Time Dashboard - At-a-glance status including:
Current trend state with directional icons
Signal strength meter (0-100%)
Band position percentage
Momentum acceleration status
Active confirmation status
✅ 5 Color Themes - Neon Pro, Classic, Ocean, Sunset, Monochrome + Custom
✅ Comprehensive Alerts - Trend changes, crossovers, OB/OS entries, confirmations
Barometer Barometer is a comprehensive market state analysis tool that synthesizes multiple market dimensions into a single, actionable reading. Like a weather barometer predicts atmospheric conditions, this indicator forecasts market "weather" by combining trend, volatility, volume, range, and momentum analysis.
Stop guessing about market conditions. The Barometer tells you exactly what state the market is in and quantifies it with a score from -12 to +12.
█ THE BAROMETER CONCEPT
The indicator creates a composite score by analyzing five key market dimensions:
📈 TREND ANALYSIS (Score: -3 to +3)
• Short-term trend (fast EMA)
• Medium-term trend (intermediate EMA)
• Long-term trend (slow EMA)
• MA alignment bonus when all aligned
📊 VOLATILITY ANALYSIS (Score: -2 to +2)
• ATR percentile ranking
• High/Low volatility detection
• Expansion/Contraction identification
📦 VOLUME ANALYSIS (Score: -2 to +2)
• Volume relative to moving average
• Climax and dry-up detection
• Volume trend analysis
📐 RANGE ANALYSIS (Score: -2 to +2)
• Bar range vs average range
• Expansion/Contraction states
• Wide bar and narrow bar detection
🚀 MOMENTUM ANALYSIS (Score: -2 to +2)
• RSI-based momentum scoring
• Overbought/Oversold detection
• Optional component
█ MARKET STATES
The composite score translates into five market states:
🔥 STRONG BULL (Score ≥ 5)
Most conditions aligned bullish
High probability trend continuation
Aggressive long opportunities
📈 BULL (Score 2-4)
Generally bullish conditions
Some components may be neutral
Standard long setups favored
➖ NEUTRAL (Score -1 to +1)
Mixed or transitional conditions
Caution advised
Wait for clarity
📉 BEAR (Score -2 to -4)
Generally bearish conditions
Some components may be neutral
Standard short setups favored
❄️ STRONG BEAR (Score ≤ -5)
Most conditions aligned bearish
High probability trend continuation
Aggressive short opportunities
VRVP Clone + Multi-POC -- PerroGordoVRVP Clone + Multi-POC
Overview
VRVP Clone + Multi-POC replicates TradingView's native Visible Range Volume Profile with several practical enhancements. The indicator displays volume distribution across price levels for the visible chart range, which is useful for identifying high-volume nodes, support/resistance zones, and areas of price acceptance.
The main differentiator from the built-in VRVP is support for multiple Point of Control (POC) lines with an intelligent peak detection algorithm. Instead of just showing the single highest-volume level, you can identify distinct volume clusters across different price zones.
Features
Dynamic Visible Range
Recalculates automatically on scroll or zoom
Analyzes only visible bars
Profile width scales proportionally to view
Multiple POC Detection (1-8 levels)
Volume Nodes Mode: Peak detection algorithm finds local volume maxima across distinct price clusters
Highest Rows Mode: Traditional approach - top N rows by raw volume
Configurable minimum separation between nodes to prevent bunching
Individual colors for each POC level
Volume Display Modes
Up/Down: Split bars showing buy vs. sell volume with black outlines for visual separation
Total: Single bar colored by dominant direction
Delta: Net volume (buy minus sell)
Delta Intensity: Gradient coloring indicating buyer/seller dominance strength per row
Value Area
Configurable percentage (default 70%)
VAH and VAL lines with customizable styles
Separate colors for volume inside vs. outside the Value Area
Positioning Options
Left or Right placement
Adjustable profile width as percentage of visible range
Row configuration via "Number of Rows" or "Ticks Per Row"
Additional Features
Statistics table showing bars analyzed, total volume, up/down percentages, price vs POC
POC price labels on chart
Line style options (Solid, Dashed, Dotted)
+++++
How It Works
Volume from each bar is distributed across price rows based on the bar's high-low range. The allocation is proportional - if a bar spans 3 rows with 60% overlap on one row, that row receives 60% of the bar's volume.
Volume Nodes Mode identifies local peaks in the distribution (rows where volume exceeds both neighbors), then selects the highest peaks while enforcing minimum separation. This surfaces distinct support/resistance clusters rather than stacking all POC lines in a single high-volume area.
+++++
Settings
Inputs
Setting - Description
Rows Layout - "Number of Rows" or "Ticks Per Row"
Row Size - Number of rows (24-200) or ticks per row
Volume - "Up/Down", "Total", "Delta", or source selection
Value Area % - Percentage of volume for Value Area (default 70%)
Profile Width % - Width as percentage of visible bars
Placement - "Right" or "Left" side of chart
Enhancements
Setting - Description
Number of POCs | 1-8 POC lines |
POC Mode - "Volume Nodes" (peak detection) or "Highest Rows" (traditional)
Min Node Separation - Minimum rows between nodes (0 = auto-calculate)
Delta Intensity Mode - Gradient coloring by dominance
Show Stats Table - Display analysis statistics
Style
Setting - Description
Up/Down Volume Colors - Buy/sell volume colors
Value Area Colors - Colors for VA regions
POC/VAH/VAL Colors - Line colors and styles
POC 2-8 Colors - Colors for additional POC levels
+++++
Applications
Support/Resistance Identification
High-volume nodes tend to act as price magnets. Multiple POCs reveal layered S/R zones that aren't visible with a single POC.
Fair Value Reference
The Value Area represents where 70% of volume traded. Price tends to revert to this zone.
Volume Gap Analysis
Low-volume areas between POCs indicate prices that were rejected quickly - potential breakout or breakdown levels.
Market Structure
Multiple POCs across price levels show where the market has found acceptance, useful for distinguishing range-bound conditions from trending moves.
+++++
Practical Notes
Volume Nodes mode with 3-5 POCs works well for identifying distinct S/R clusters
Higher row counts give more granular analysis on lower timeframes
Delta Intensity mode quickly shows buyer/seller dominance at each level without the visual noise of split bars
If POCs are too clustered, increase Min Node Separation; if too spread out, decrease it or set to 0 for auto
The stats table vs POC comparison is useful for quick directional bias assessment
+++++
Requirements
Any instrument with volume data
Works well on futures, forex, and liquid equities
Pine Script v6
+++++
Version History
v1.1
- Added Volume Nodes mode with peak detection
- Expanded to 8 POC levels
- Added Min Node Separation setting
- Fixed POC label positioning for left placement
- Added black outlines to Up/Down volume bars
v1.0
- Initial release replicating VRVP with multi-POC enhancement
- Delta Intensity mode
- Statistics table
Today's Session High/Low + Previous LevelsDescription
This indicator combines multiple powerful tools into one clean overlay:
Today’s Session High & Low for Asia, London and New York, automatically drawn only for the current trading day.
Previous High & Low levels based on configurable timeframes (hour, day, week, month or year), including optional filtering and area zones.
EMA Trend Table showing EMA20, EMA50 and EMA200 alignment across multiple timeframes with clear bullish/bearish status.
Designed to help traders quickly identify key intraday levels, higher-timeframe liquidity zones and overall market trend at a glance.
Killzones [Tradeuminati]Killzones is a precise TradingView indicator designed to display the most important institutional trading windows (“Killzones”) based strictly on New York local time.
The indicator focuses on accurate session timing, automatic asset classification, and stable chart behavior without affecting price scale or candle colors.
🔹 Included Killzones (NY Local Time)
London Killzone
02:00 – 05:00
New York Killzone (AM)
Indices & Index CFDs: 09:30 – 11:00
All other assets (Forex, Crypto, Commodities such as Gold, DXY): 07:00 – 10:00
New York PM Killzone
14:00 – 15:00
🔹 Asset Logic (Fully Automatic & Locked)
- Indices and Index CFDs are detected automatically
- Forex, Crypto, Commodities (e.g. Gold/XAUUSD, DXY) always use the 07:00–10:00 New York Killzone
- Stocks (Equities) are completely excluded
→ no lines, no table, no status display
This ensures the indicator is purpose-built for intraday trading in highly liquid markets and intentionally not designed for stock charts.
🔹 Chart Visualization
- Vertical session lines are drawn statically at the start of each New York trading day
- Lines are not dependent on bar timestamps
- No distortion of the price scale
- Session lines are shown only on intraday timeframes below 4H
- Line color, width, and style are fully adjustable
🔹 Status Table (Top Right)
- Clear overview of all Killzones with start and end times
- Live status indicator (green/red) based on the real current time (timenow), not the last printed candle
- The table remains visible on all timeframes (except stocks)
🔹 Technical Highlights
- Pure New York time–based logic, independent of chart timezone
- No future-bar plotting
- Stable across different brokers and CFD feeds
- Does not interfere with other indicators or candle coloring
⚠️ Disclaimer
This indicator is intended for technical analysis only and does not constitute trading or investment advice.
ROC+ADX Trend & Momentum System### Code Analysis: ROC+ADX Trend & Momentum System (v5 Pine Script)
#### **Core Function**
This Pine Script indicator integrates **Rate of Change (ROC)** and **Average Directional Index (ADX)** to build a professional trend-momentum trading system, which identifies trend strength, momentum changes, price divergences and generates actionable long/short trading signals for financial markets (stocks, crypto, forex). It features coordinated visual display, adaptive volatility adjustment and a comprehensive scoring mechanism for trend evaluation.
#### **Key Features (Concise)**
1. **Hybrid Indicator Logic**
Combines **ROC (12/6-period, EMA-smoothed)** (measures price momentum) and **ADX (14-period)** (identifies trend strength/direction, with +DI/-DI for trend bias), forming a dual-dimension analysis of trend + momentum.
2. **Adaptive Dynamic Threshold**
Adjusts momentum thresholds in real time based on **14-period ATR volatility**; higher market volatility raises thresholds, lower volatility lowers them, ensuring signal accuracy across different market conditions.
3. **Multi-Category Trading Signals**
Generates 4 core signal types: trend breakout (long/short), momentum boost/drop, trend reversal, and price-ROC bullish/bearish divergence, all filtered by ADX trend validity.
4. **Comprehensive Trend Scoring System**
Calculates a **0-100 trend score** (integrates ADX strength, ROC momentum, direction consistency, momentum persistence) and classifies trend intensity into 5 levels (Extreme/Strong/Medium/Weak/None).
5. **Coordinated Visual Display**
Supports scalable unified display for ROC & ADX values (custom scale factors), with color-coded lines, momentum histograms, heatmap background and reference lines for intuitive trend judgment.
6. **Informative Dashboard & Alerts**
Embeds a top-right info panel showing real values (ROC, ADX, volatility), trend level and active signals; includes multi-tier alert conditions for all key signals (breakout, reversal, divergence).
7. **High Customizability**
Full input configurability for all core parameters (periods, thresholds, scale factors) and visual toggles (show/hide ROC/ADX, signals, heatmap, reference lines).
#### **Technical Highlights**
- Uses EMA smoothing for ROC/ADX to reduce false signals;
- Identifies ROC momentum & acceleration for precise trend phase judgment;
- ADX grading (strong/weak/oscillation) filters invalid signals in sideways markets;
- Color-coded elements (lines, histograms, heatmap) reflect real-time trend/momentum status;
- Non-overlay layout ensures clear separation from price charts, optimized for multi-screen analysis.
First Opening Price of the YearOverview
This indicator identifies and plots the opening price of the first trading session of the calendar year. The "Yearly Open" is a significant psychological level for traders and institutions, often serving as a major pivot point for the entire year's trend.
How it Works
The script utilizes Pine Script v5's persistent variables to track the year change.
Detection: It compares the current bar's year (year) with the previous bar's year (year ).
Storage: When a discrepancy is found (indicating a new year has started), the script captures the open price of that specific bar.
Persistence: Using the var keyword, this price is stored in memory and carried forward for every subsequent bar of the year without being recalculated.
Visualization: The price is plotted as a series of blue crosses (style_cross) to clearly mark the level on the chart.
Chart Analysis & Examples
The following examples demonstrate how this simple level dictates market structure across different assets:
Historical Pivot Points (S&P 500):
This chart demonstrates how the Yearly Open acts as a critical pivot. Notice in 2022 how price struggled around the open before dropping, while in 2023 and 2024, the yearly open provided a solid base for the subsequent rallies.
Trend Confirmation (Bitcoin):
In strong trending markets, the Yearly Open serves as a trailing support. As seen in this Bitcoin example, price maintaining its position above the blue line confirms a sustained bullish bias for the year, acting as a "floor" for the trend.
Market Structure & Bias (Gold):
This example highlights the "Line in the Sand" concept. The indicator clearly marks the starting point of the year, allowing traders to instantly gauge if the asset is net positive or negative year-to-date. It filters out the noise and focuses on the macro direction.
How to Use
Traders can use this indicator to determine the higher-timeframe bias:
Bullish Bias: When the current price is trading above the blue crosses, the market is considered to be positive relative to the start of the year.
Bearish Bias: When the current price is trading below the blue crosses, the market is negative relative to the start of the year.
Settings
This script is "plug and play" and requires no manual input adjustments. It automatically detects the timeframe and year changes based on the chart data provided.
Disclaimer
This tool is for informational purposes only and DOES NOT constitute financial advice. Always manage your risk appropriately.
EXPANSION MODELTrading algo has been optimized to pin point key areas in the market where large order reside.
Works best with XXXUSD pairs as a trend following model.
Spot Futures Divergence & Auction ContextSpot–Futures Divergence & Auction Context
Spot–Futures Divergence & Auction Context is a contextual market analysis indicator designed to help traders understand where the market is positioned and when structural divergence is meaningful.
This tool compares spot and futures price structure using confirmed swing pivots and overlays that information with VWAP location, auction regime, and higher-timeframe (HTF) trend context.
⚠️ This indicator is NOT a buy/sell signal generator.
It is intended for discretionary decision support and market context only.
🔍 What This Indicator Shows
1️⃣ Spot–Futures Structural Divergence
Identifies divergence between spot and futures swing structure
Highlights where derivatives are leading or lagging cash markets
Uses confirmed pivots only (non-repainting)
2️⃣ Divergence Quality (DIV-A / DIV-B)
DIV-A: Divergence aligned with HTF trend
DIV-B: Divergence against or without HTF alignment
Helps distinguish high-quality context from early warnings
3️⃣ VWAP Context & Deviation Bands
Session VWAP plotted on futures
Optional VWAP deviation bands (±1σ / ±2σ / ±3σ) for auction stretch context
Bands are visual only, not signals
4️⃣ Auction Regime Detection
Classifies market as BALANCED or IMBALANCED
Helps avoid divergence during strong trend / directional auctions
5️⃣ Options Bias Panel (Context Only)
Provides a high-level directional or volatility bias, such as:
CALL BIAS
PUT BIAS
SELL PREMIUM
WAIT
This bias is informational, not an instruction to trade.
⚙️ Key Settings Explained
Futures / Execution Symbol
Select the futures or derivative symbol you are trading (e.g., NIFTY1!, BANKNIFTY1!, ES1!, BTCUSDT.P).
Spot / Cash Reference Symbol
Select the corresponding spot or cash index used for structural comparison.
Divergence Display Mode
Show All → Displays all divergences
Hide in Imbalanced → Suppresses divergences during strong directional auctions
DIV-A only in Imbalanced → Shows only HTF-aligned divergences on trend days
This is a discipline and visibility control, not a signal filter.
VWAP Deviation Bands
Optional visual bands to assess how far price is trading from fair value.
Best used for context, not entries.
🧭 How to Use (1-Page User Guide)
Recommended Workflow
Start with auction regime
Balanced → mean-reversion context
Imbalanced → trend / momentum context
Observe VWAP location
Near VWAP → fair value
Extended → stretched auction
Note Spot–Futures divergence
DIV-A → higher contextual importance
DIV-B → early warning or risk signal
Use Options Bias panel
As a guideline, not a trigger
Especially useful for options and volatility strategies
🚫 When to Ignore Divergence
Strong imbalanced trend with steep VWAP slope
News-driven or event-driven sessions
Very early session before structure forms
⚠️ Important Disclaimers
This indicator does not generate buy/sell signals.
No profitability or performance claims are made.
Past behavior does not guarantee future results.
Trading futures, options, and leveraged products involves significant risk.
Use this tool for analysis and education only.
📊 Best Use Cases
Index futures & options
Spot vs derivative structure analysis
Intraday auction and VWAP-based context
Risk awareness and trade selection support
ICT Big Round Numbers (00, 20, 50, 80)This indicator plots "Big Round Numbers", a term for "psychological" or "institutional" forex price levels that occur at 00, 20, 50, & 80 levels in FX markets. The concept is from the work of Michael J. Huddleston aka The Inner Circle Trader ( ICT ). www.youtube.com
DeeptestDeeptest: Quantitative Backtesting Library for Pine Script
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ OVERVIEW
Deeptest is a Pine Script library that provides quantitative analysis tools for strategy backtesting. It calculates over 100 statistical metrics including risk-adjusted return ratios (Sharpe, Sortino, Calmar), drawdown analysis, Value at Risk (VaR), Conditional VaR, and performs Monte Carlo simulation and Walk-Forward Analysis.
█ WHY THIS LIBRARY MATTERS
Pine Script is a simple yet effective coding language for algorithmic and quantitative trading. Its accessibility enables traders to quickly prototype and test ideas directly within TradingView. However, the built-in strategy tester provides only basic metrics (net profit, win rate, drawdown), which is often insufficient for serious strategy evaluation.
Due to this limitation, many traders migrate to alternative backtesting platforms that offer comprehensive analytics. These platforms require other language programming knowledge, environment setup, and significant time investment—often just to test a simple trading idea.
Deeptest bridges this gap by bringing institutional-level quantitative analytics directly to Pine Script. Traders can now perform sophisticated analysis without leaving TradingView or learning complex external platforms. All calculations are derived from strategy.closedtrades.* , ensuring compatibility with any existing Pine Script strategy.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ ORIGINALITY AND USEFULNESS
This library is original work that adds value to the TradingView community in the following ways:
1. Comprehensive Metric Suite: Implements 112+ statistical calculations in a single library, including advanced metrics not available in TradingView's built-in tester (p-value, Z-score, Skewness, Kurtosis, Risk of Ruin).
2. Monte Carlo Simulation: Implements trade-sequence randomization to stress-test strategy robustness by simulating 1000+ alternative equity curves.
3. Walk-Forward Analysis: Divides historical data into rolling in-sample and out-of-sample windows to detect overfitting by comparing training vs. testing performance.
4. Rolling Window Statistics: Calculates time-varying Sharpe, Sortino, and Expectancy to analyze metric consistency throughout the backtest period.
5. Interactive Table Display: Renders professional-grade tables with color-coded thresholds, tooltips explaining each metric, and period analysis cards for drawdowns/trades.
6. Benchmark Comparison: Automatically fetches S&P 500 data to calculate Alpha, Beta, and R-squared, enabling objective assessment of strategy skill vs. passive investing.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ KEY FEATURES
Performance Metrics
Net Profit, CAGR, Monthly Return, Expectancy
Profit Factor, Payoff Ratio, Sample Size
Compounding Effect Analysis
Risk Metrics
Sharpe Ratio, Sortino Ratio, Calmar Ratio (MAR)
Martin Ratio, Ulcer Index
Max Drawdown, Average Drawdown, Drawdown Duration
Risk of Ruin, R-squared (equity curve linearity)
Statistical Distribution
Value at Risk (VaR 95%), Conditional VaR
Skewness (return asymmetry)
Kurtosis (tail fatness)
Z-Score, p-value (statistical significance testing)
Trade Analysis
Win Rate, Breakeven Rate, Loss Rate
Average Trade Duration, Time in Market
Consecutive Win/Loss Streaks with Expected values
Top/Worst Trades with R-multiple tracking
Advanced Analytics
Monte Carlo Simulation (1000+ iterations)
Walk-Forward Analysis (rolling windows)
Rolling Statistics (time-varying metrics)
Out-of-Sample Testing
Benchmark Comparison
Alpha (excess return vs. benchmark)
Beta (systematic risk correlation)
Buy & Hold comparison
R-squared vs. benchmark
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ QUICK START
Basic Usage
//@version=6
strategy("My Strategy", overlay=true)
// Import the library
import Fractalyst/Deeptest/1 as *
// Your strategy logic
fastMA = ta.sma(close, 10)
slowMA = ta.sma(close, 30)
if ta.crossover(fastMA, slowMA)
strategy.entry("Long", strategy.long)
if ta.crossunder(fastMA, slowMA)
strategy.close("Long")
// Run the analysis
DT.runDeeptest()
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ METRIC EXPLANATIONS
The Deeptest table displays 23 metrics across the main row, with 23 additional metrics in the complementary row. Each metric includes detailed tooltips accessible by hovering over the value.
Main Row — Performance Metrics (Columns 0-6)
Net Profit — (Final Equity - Initial Capital) / Initial Capital × 100
— >20%: Excellent, >0%: Profitable, <0%: Loss
— Total return percentage over entire backtest period
Payoff Ratio — Average Win / Average Loss
— >1.5: Excellent, >1.0: Good, <1.0: Losses exceed wins
— Average winning trade size relative to average losing trade. Breakeven win rate = 100% / (1 + Payoff)
Sample Size — Count of closed trades
— >=30: Statistically valid, <30: Insufficient data
— Number of completed trades. Includes 95% confidence interval for win rate in tooltip
Profit Factor — Gross Profit / Gross Loss
— >=1.5: Excellent, >1.0: Profitable, <1.0: Losing
— Ratio of total winnings to total losses. Uses absolute values unlike payoff ratio
CAGR — (Final / Initial)^(365.25 / Days) - 1
— >=10%: Excellent, >0%: Positive growth
— Compound Annual Growth Rate - annualized return accounting for compounding
Expectancy — Sum of all returns / Trade count
— >0.20%: Excellent, >0%: Positive edge
— Average return per trade as percentage. Positive expectancy indicates profitable edge
Monthly Return — Net Profit / (Months in test)
— >0%: Profitable month average
— Average monthly return. Geometric monthly also shown in tooltip
Main Row — Trade Statistics (Columns 7-14)
Avg Duration — Average time in position per trade
— Mean holding period from entry to exit. Influenced by timeframe and trading style
Max CW — Longest consecutive winning streak
— Maximum consecutive wins. Expected value = ln(trades) / ln(1/winRate)
Max CL — Longest consecutive losing streak
— Maximum consecutive losses. Important for psychological risk tolerance
Win Rate — Wins / Total Trades
— Higher is better
— Percentage of profitable trades. Breakeven win rate shown in tooltip
BE Rate — Breakeven Trades / Total Trades
— Lower is better
— Percentage of trades that broke even (neither profit nor loss)
Loss Rate — Losses / Total Trades
— Lower is better
— Percentage of unprofitable trades. Together with win rate and BE rate, sums to 100%
Frequency — Trades per month
— Trading activity level. Displays intelligently (e.g., "12/mo", "1.5/wk", "3/day")
Exposure — Time in market / Total time × 100
— Lower = less risk
— Percentage of time the strategy had open positions
Main Row — Risk Metrics (Columns 15-22)
Sharpe Ratio — (Return - Rf) / StdDev × sqrt(Periods)
— >=3: Excellent, >=2: Good, >=1: Fair, <1: Poor
— Measures risk-adjusted return using total volatility. Annualized using sqrt(252) for daily
Sortino Ratio — (Return - Rf) / DownsideDev × sqrt(Periods)
— >=2: Excellent, >=1: Good, <1: Needs improvement
— Similar to Sharpe but only penalizes downside volatility. Can be higher than Sharpe
Max DD — (Peak - Trough) / Peak × 100
— <5%: Excellent, 5-15%: Moderate, 15-30%: High, >30%: Severe
— Largest peak-to-trough decline in equity. Critical for risk tolerance and position sizing
RoR — Risk of Ruin probability
— <1%: Excellent, 1-5%: Acceptable, 5-10%: Elevated, >10%: Dangerous
— Probability of losing entire trading account based on win rate and payoff ratio
R² — R-squared of equity curve vs. time
— >=0.95: Excellent, 0.90-0.95: Good, 0.80-0.90: Moderate, <0.80: Erratic
— Coefficient of determination measuring linearity of equity growth
MAR — CAGR / |Max Drawdown|
— Higher is better, negative = bad
— Calmar Ratio. Reward relative to worst-case loss. Negative if max DD exceeds CAGR
CVaR — Average of returns below VaR threshold
— Lower absolute is better
— Conditional Value at Risk (Expected Shortfall). Average loss in worst 5% of outcomes
p-value — Binomial test probability
— <0.05: Significant, 0.05-0.10: Marginal, >0.10: Likely random
— Probability that observed results are due to chance. Low p-value means statistically significant edge
Complementary Row — Extended Metrics
Compounding — (Compounded Return / Total Return) × 100
— Percentage of total profit attributable to compounding (position sizing)
Avg Win — Sum of wins / Win count
— Average profitable trade return in percentage
Avg Trade — Sum of all returns / Total trades
— Same as Expectancy (Column 5). Displayed here for convenience
Avg Loss — Sum of losses / Loss count
— Average unprofitable trade return in percentage (negative value)
Martin Ratio — CAGR / Ulcer Index
— Similar to Calmar but uses Ulcer Index instead of Max DD
Rolling Expectancy — Mean of rolling window expectancies
— Average expectancy calculated across rolling windows. Shows consistency of edge
Avg W Dur — Avg duration of winning trades
— Average time from entry to exit for winning trades only
Max Eq — Highest equity value reached
— Peak equity achieved during backtest
Min Eq — Lowest equity value reached
— Trough equity point. Important for understanding worst-case absolute loss
Buy & Hold — (Close_last / Close_first - 1) × 100
— >0%: Passive profit
— Return of simply buying and holding the asset from backtest start to end
Alpha — Strategy CAGR - Benchmark CAGR
— >0: Has skill (beats benchmark)
— Excess return above passive benchmark. Positive alpha indicates genuine value-added skill
Beta — Covariance(Strategy, Benchmark) / Variance(Benchmark)
— <1: Less volatile than market, >1: More volatile
— Systematic risk correlation with benchmark
Avg L Dur — Avg duration of losing trades
— Average time from entry to exit for losing trades only
Rolling Sharpe/Sortino — Dynamic based on win rate
— >2: Good consistency
— Rolling metric across sliding windows. Shows Sharpe if win rate >50%, Sortino if <=50%
Curr DD — Current drawdown from peak
— Lower is better
— Present drawdown percentage. Zero means at new equity high
DAR — CAGR adjusted for target DD
— Higher is better
— Drawdown-Adjusted Return. DAR^5 = CAGR if max DD = 5%
Kurtosis — Fourth moment / StdDev^4 - 3
— ~0: Normal, >0: Fat tails, <0: Thin tails
— Measures "tailedness" of return distribution (excess kurtosis)
Skewness — Third moment / StdDev^3
— >0: Positive skew (big wins), <0: Negative skew (big losses)
— Return distribution asymmetry
VaR — 5th percentile of returns
— Lower absolute is better
— Value at Risk at 95% confidence. Maximum expected loss in worst 5% of outcomes
Ulcer — sqrt(mean(drawdown^2))
— Lower is better
— Ulcer Index - root mean square of drawdowns. Penalizes both depth AND duration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ MONTE CARLO SIMULATION
Purpose
Monte Carlo simulation tests strategy robustness by randomizing the order of trades while keeping trade returns unchanged. This simulates alternative equity curves to assess outcome variability.
Method
Extract all historical trade returns
Randomly shuffle the sequence (1000+ iterations)
Calculate cumulative equity for each shuffle
Build distribution of final outcomes
Output
The stress test table shows:
Median Outcome: 50th percentile result
5th Percentile: Worst 5% of outcomes
95th Percentile: Best 95% of outcomes
Success Rate: Percentage of simulations that were profitable
Interpretation
If 95% of simulations are profitable: Strategy is robust
If median is far from actual result: High variance/unreliability
If 5th percentile shows large loss: High tail risk
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ WALK-FORWARD ANALYSIS
Purpose
Walk-Forward Analysis (WFA) is the gold standard for detecting strategy overfitting. It simulates real-world trading by dividing historical data into rolling "training" (in-sample) and "validation" (out-of-sample) periods. A strategy that performs well on unseen data is more likely to succeed in live trading.
Method
The implementation uses a non-overlapping window approach following AmiBroker's gold standard methodology:
Segment Calculation: Total trades divided into N windows (default: 12), IS = ~75%, OOS = ~25%, Step = OOS length
Window Structure: Each window has IS (training) followed by OOS (validation). Each OOS becomes the next window's IS (rolling forward)
Metrics Calculated: CAGR, Sharpe, Sortino, MaxDD, Win Rate, Expectancy, Profit Factor, Payoff
Aggregation: IS metrics averaged across all IS periods, OOS metrics averaged across all OOS periods
Output
IS CAGR: In-sample annualized return
OOS CAGR: Out-of-sample annualized return ( THE key metric )
IS/OOS Sharpe: In/out-of-sample risk-adjusted return
Success Rate: % of OOS windows that were profitable
Interpretation
Robust: IS/OOS CAGR gap <20%, OOS Success Rate >80%
Some Overfitting: CAGR gap 20-50%, Success Rate 50-80%
Severe Overfitting: CAGR gap >50%, Success Rate <50%
Key Principles:
OOS is what matters — Only OOS predicts live performance
Consistency > Magnitude — 10% IS / 9% OOS beats 30% IS / 5% OOS
Window count — More windows = more reliable validation
Non-overlapping OOS — Prevents data leakage
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ TABLE DISPLAY
Main Table — Organized into three sections:
Performance Metrics (Cols 0-6): Net Profit, Payoff, Sample Size, Profit Factor, CAGR, Expectancy, Monthly
Trade Statistics (Cols 7-14): Avg Duration, Max CW, Max CL, Win, BE, Loss, Frequency, Exposure
Risk Metrics (Cols 15-22): Sharpe, Sortino, Max DD, RoR, R², MAR, CVaR, p-value
Color Coding
🟢 Green: Excellent performance
🟠 Orange: Acceptable performance
⚪ Gray: Neutral / Fair
🔴 Red: Poor performance
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ IMPLEMENTATION NOTES
Data Source: All metrics calculated from strategy.closedtrades , ensuring compatibility with any Pine Script strategy
Calculation Timing: All calculations occur on barstate.islastconfirmedhistory to optimize performance
Limitations: Requires at least 1 closed trade for basic metrics, 30+ trades for reliable statistical analysis
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ QUICK NOTES
➙ This library has been developed and refined over two years of real-world strategy testing. Every calculation has been validated against industry-standard quantitative finance references.
➙ The entire codebase is thoroughly documented inline. If you are curious about how a metric is calculated or want to understand the implementation details, dive into the source code -- it is written to be read and learned from.
➙ This description focuses on usage and concepts rather than exhaustively listing every exported type and function. The library source code is thoroughly documented inline -- explore it to understand implementation details and internal logic.
➙ All calculations execute on barstate.islastconfirmedhistory to minimize runtime overhead. The library is designed for efficiency without sacrificing accuracy.
➙ Beyond analysis, this library serves as a learning resource. Study the source code to understand quantitative finance concepts, Pine Script advanced techniques, and proper statistical methodology.
➙ Metrics are their own not binary good/bad indicators. A high Sharpe ratio with low sample size is misleading. A deep drawdown during a market crash may be acceptable. Study each function and metric individually -- evaluate your strategy contextually, not by threshold alone.
➙ All strategies face alpha decay over time. Instead of over-optimizing a single strategy on one timeframe and market, build a diversified portfolio across multiple markets and timeframes. Deeptest helps you validate each component so you can combine robust strategies into a trading portfolio.
➙ Screenshots shown in the documentation are solely for visual representation to demonstrate how the tables and metrics will be displayed. Please do not compare your strategy's performance with the metrics shown in these screenshots -- they are illustrative examples only, not performance targets or benchmarks.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ HOW-TO
Using Deeptest is intentionally straightforward. Just import the library and call DT.runDeeptest() at the end of your strategy code in main scope. .
//@version=6
strategy("My Strategy", overlay=true)
// Import the library
import Fractalyst/Deeptest/1 as DT
// Your strategy logic
fastMA = ta.sma(close, 10)
slowMA = ta.sma(close, 30)
if ta.crossover(fastMA, slowMA)
strategy.entry("Long", strategy.long)
if ta.crossunder(fastMA, slowMA)
strategy.close("Long")
// Run the analysis
DT.runDeeptest()
And yes... it's compatible with any TradingView Strategy! 🪄
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ CREDITS
Author: @Fractalyst
Font Library: by @fikira - @kaigouthro - @Duyck
Community: Inspired by the @PineCoders community initiative, encouraging developers to contribute open-source libraries and continuously enhance the Pine Script ecosystem for all traders.
if you find Deeptest valuable in your trading journey, feel free to use it in your strategies and give a shoutout to @Fractalyst -- Your recognition directly supports ongoing development and open-source contributions to Pine Script.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
█ DISCLAIMER
This library is provided for educational and research purposes. Past performance does not guarantee future results. Always test thoroughly and use proper risk management. The author is not responsible for any trading losses incurred through the use of this code.
Mod_Capital MA 50 & MA 200 🔥 WHY ARE MA 50 AND MA 200 SO IMPORTANT?
These two moving averages are the key reference levels used by institutions, banks, and hedge funds to analyze the market.
📌 MA 50
Represents the medium-term trend
Acts as an active trading zone
Often holds price during pullbacks and corrections
📌 MA 200
Represents the long-term trend
Shows the overall market “health”
A major reference level for investors
🟢 Golden Cross & 🔴 Death Cross
🟢 Golden Cross
When MA 50 crosses above MA 200
→ A long-term bullish signal
🔴 Death Cross
When MA 50 crosses below MA 200
→ A long-term bearish signal
Breakout LevelsBreakout Levels - User Guide
Overview
The Breakout Levels indicator automatically detects and displays significant breakout candles across multiple timeframes. A breakout occurs when price makes a strong, decisive move - identified by candles with unusually large bodies relative to average volatility.
These breakout levels often act as future support/resistance zones, making them valuable reference points for trading decisions.
What is a Breakout?
A breakout is detected when a candle's body size (the distance between open and close) is significantly larger than normal. By default, the script looks for candles that are 2x the ATR (Average True Range) or larger.
Example:
If the 14-period ATR is $5, a candle with a $10+ body would qualify as a breakout
These represent strong, committed moves by the market
The script marks the high of bullish breakouts and the low of bearish breakouts
Settings Guide
Timeframes
Toggle which timeframes to monitor for breakouts:
Show Daily Breakouts - Green/Red levels from daily chart breakouts
Show 4H Breakouts - 4-hour timeframe breakouts
Show 1H Breakouts - 1-hour timeframe breakouts
Show 15M Breakouts - 15-minute timeframe breakouts
Tip: When running on a 15-minute chart, you can see breakouts from all higher timeframes simultaneously.
Lookback (How Far Back to Display)
Controls how many bars back to show levels for each timeframe:
TimeframeDefaultWhat it Means15M50 bars~12.5 hours of breakout history1H200 bars~8 days of breakout history4H250 bars~42 days of breakout historyDaily300 bars~300 days (nearly 1 year)
Why adjust this?
Increase to see more historical levels (may clutter chart)
Decrease to focus only on recent breakouts
Older levels are still stored, just not displayed
Detection Settings
Breakout Candle Size (x ATR)
Default: 2.0
Range: 1.0 to 5.0
What it does: Multiplier for what qualifies as a "big" candle
SettingSensitivityUse Case1.0-1.5Very sensitiveCatches more breakouts, but may include false moves2.0Balanced (default)Good mix of quality and quantity3.0-5.0Very selectiveOnly the most explosive moves
Recommendation: Start with 2.0 and adjust based on your market and trading style.
Visual Settings
Bullish Breakout Color
Default: Green with 60% transparency
Marks levels where price broke upward strongly
Bearish Breakout Color
Default: Red with 60% transparency
Marks levels where price broke downward strongly
Show Labels
Toggle labels on/off
Labels display: BO
Example: "4H BO 150.25"
Turn OFF for cleaner charts when you just want the lines
How to Use This Indicator
1. Identify Key Breakout Zones
Breakout levels often become magnets where price returns later:
Former resistance (where price broke up) becomes future support
Former support (where price broke down) becomes future resistance
2. Look for Confluence
When multiple timeframe breakouts cluster near the same price:
15M + 1H + 4H breakouts all near $150 = strong level
More confluence = more significant level
3. Watch for Retests
After a breakout, price often returns to test that level:
Bullish breakout retest from above = potential long entry
Bearish breakout retest from below = potential short entry
4. Combine with Other Analysis
Use breakout levels alongside:
Your own support/resistance analysis
Volume profiles
Fibonacci levels
Candlestick patterns at these levels
Practical Examples
Example 1: Clean Breakout and Retest
Daily candle closes up with a huge body (2.5x ATR)
Green line drawn at the high of that candle
Price pulls back 3 days later and bounces exactly off that green line
Trade opportunity: Long entry at the retest with stop below
Example 2: Failed Breakout
4H bearish breakout draws a red line at the low
Price immediately reverses back above the level
Signal: The breakout was false - consider this a stop hunt zone
Example 3: Multi-Timeframe Confluence
Daily breakout at $100
4H breakout at $100.50
1H breakout at $99.80
Strong cluster zone: $99.80-$100.50 becomes a major decision point
Best Practices
DO:
✅ Start with default settings (2.0x ATR, default lookbacks)
✅ Use on a 15-minute chart to see all timeframes
✅ Look for price reactions at these levels before trading
✅ Combine with volume - breakouts with high volume are more reliable
✅ Turn off labels when chart gets too busy
DON'T:
❌ Treat every line as guaranteed support/resistance
❌ Set breakout multiplier too low (<1.5) - creates noise
❌ Ignore the context - check what's happening in the broader market
❌ Trade blindly at these levels without confirmation
Troubleshooting
"Too many lines on my chart"
Reduce the lookback settings
Turn off some timeframes (maybe just show Daily + 4H)
Increase the breakout multiplier to 2.5 or 3.0
"Not showing any levels"
Lower the breakout multiplier to 1.5
Increase lookback settings
Check that at least one timeframe toggle is ON
Verify the market had actual volatility during the period
"Labels are cluttering the chart"
Turn off "Show Labels" in settings
Lines will remain, labels disappear
Technical Notes
ATR Period: 14 (industry standard, not adjustable in this version)
Max Lines: 500 (Pine Script limitation)
Duplicate Filter: Levels within 0.3% of ATR are considered duplicates and filtered
Chart Type: Works on any chart timeframe, optimized for 15-minute
Asset Type: Works on stocks, forex, crypto, futures
Summary
The Breakout Levels indicator gives you a systematic way to identify where strong, committed market moves occurred. These levels often act as future decision points. Use them as reference zones to watch for price reactions, not as automatic trade signals.
Quick Start:
Add indicator to a 15-minute chart
Leave default settings (2.0x ATR)
Watch how price interacts with the levels over the next few days
Adjust sensitivity based on your observations
Happy trading! 📈
PM/PW/PD/OVN/CD/CM/CW/ORB Highs & Lows + EMAs + ATH/ATL/52WTogglable:
Previous Month High / Low
Previous Week High / Low
Previous Day High / Low
Current Month High / Low
Current Week High / Low
Current Day High / Low
ORB High / Low
Overnight High / Low
Asia Session High / Low
London Session High / Low
All Time High / Low
52week High / Low
3 EMAs (default 21/34/55)
Dashboards + lines on chart






















