Probability-Based Adaptive Detection🙏🏻 PBAD (Probability-Based Adaptive Detection) : adaptive control tool for outliers || novelty detection, made for worst case data & processes, for the highest time complexity O(n^2) compared with the alternatives (would be explained in a sec). Thresholds are completely data driven and axiomatic, no need in provided hyperparameters, are not learned or optimized. The method accepts multiple weights, e.g. both temporal and volatility weights.
Method briefly explained (I can go deeper if any1 asks explicitly):
Performs weighted KDE on initial input data, finds KDE global maximum (mode), creates new “residuals” dataset by centering initial data around this value;
Performs weighted KDE on residuals, uses sigmoid based probability mass targets with increasing probability coverage to construct a set of non-disjoint High Density Intervals (also called HDR, HPD in Bayesian terms);
Uses these intervals to calculate analogs of centralized & standardized moments;
Uses these ^^ moments to construct a set of control thresholds. The scheme used in PBAD is not only based on a central threshold, or on neighboring ones, it utilizes all previous thresholds, gaining more information.
...
The most important part is to understand whether you really need PBAD. Because even tho it seems to be the best one given highest algocomplexity, irl it would work worse in cases when it’s not required by your data.
Here’s the menu (aka taxonomy omg) of methods you can use that would let you make the right choice:
Moment-Based Adaptive Detection (MBAD) :
Norm: L2
Time complexity: original O(n), successfully reduced to O(1) in online version
Use case: default, general purpose
Based on: method of moments (powers of residuals from mean)
Thresholds architecture: centralized
Quantile-Based Adaptive Detection (QBAD):
Norm: L1
Time complexity: O(nlogn)
Use case: either bad data Or process instability
Based on: quantile moments (dyadic percentiles of residuals from median)
Thresholds architecture: chained/recursive/sequential
Probability-Based Adaptive Detection (PBAD):
Norm: L0
Time complexity: O(n^2)
Use case: both bad data And process instability
Based on: probability moments (target probability masses of residuals from KDE mode)
Thresholds architecture: decentralized (for lack of a better name xd, the idea is that these thresholds gain information from the all other threshold and are Not exclusively based on the central or neighboring thresholds)
...
Examples of true use cases:
^^ an appropriate financial instrument to use PBAD
^^ and another one
...
Additional details about how to use it:
Keep the student5 kernel, it’s the best you can do. I added others mostly for comparisons and if you want to use the tool Not for its primary purpose (on a fine data)
“Calculate for N bars” and “Starting at bar N” options allow to reduce calculation period only on the N number of last bars or next bars from a chosen one. It's vital, because calculations here are heavy
Keep plotting offset at 1 (allows to visually compare current bar with the previous threshold values). This is the way it should be done on price data.
HLC3 is the optimal source input, unless you want to use your own better one point estimate of each datapoint (in the best case done by using PBAD itself on OHLC+ values).
In essence it should be used just like MBAD or QBAD, fade/push extensions and limit, fade/push/skip deviations & basis, or other strategies of your. Again, the only reason for 3 methods to exist is to be chosen for according data characteristics.
Btw:
This is the initial version, I don’t consider it perfected tbh, even tho it works as expected, however this method is very situational anyways.
In this script KDE function is modified to ensure the outcoming probabilities Do sum up to 1. I didn’t do this normalization in Weighted KDE Mode script , but there it’s not required since we just need a KDE global max.
see ya
∞
Statistics
Z-Score & StatsThis is an advanced indicator that measures price deviation from its mean using statistical z-scores, combined with multiple analytical features for trading signals.
Core Functionality-
Z-Score Calculation Engine:
The indicator uses a custom standardization function that calculates how many standard deviations the current price is from its rolling mean. Unlike simple moving averages, this provides a normalized view of price extremes. The calculation maintains a sliding window of data points, efficiently updating mean and variance values as new data arrives while removing old data points. This approach handles missing values gracefully and uses sample variance (rather than population variance) for more accurate statistical measurements.
Statistical Zones & Visual Framework:
The indicator creates a visual representation of statistical probability zones:
±1 Standard Deviation: Encompasses about 68% of normal price behavior (green zone)
±2 Standard Deviations: Covers approximately 95% of price movements (orange zone)
±3 Standard Deviations: Represents 99.7% probability range (red zone)
±3.5 and ±4 Thresholds: Extreme outlier levels that trigger special alerts
The z-score line changes color dynamically based on which zone it occupies, making it easy to identify the current market extremity at a glance.
Advanced Features:
Volume Contraction Analysis
The script monitors volume patterns to identify periods of reduced trading activity. It compares current volume against a moving average and flags when volume drops below a specified threshold (default 70%). Volume contraction often precedes significant price moves and is factored into the optimal entry detection system.
Momentum-Based Direction Model:
Rather than just showing current z-score levels, the indicator projects where the z-score is likely to move based on recent momentum. It calculates the rate of change in the z-score and extrapolates forward for a specified number of bars. This creates a directional arrow that indicates whether conditions are bullish (negative z-score with upward momentum) or bearish (positive z-score with downward momentum).
Divergence Detection System:
The script automatically identifies four types of divergences between price action and z-score behavior :-
Regular Bullish Divergence: Price makes lower lows while z-score makes higher lows, suggesting weakening downward pressure
Regular Bearish Divergence: Price makes higher highs while z-score makes lower highs, indicating exhaustion in the uptrend
Hidden Bullish Divergence: Price makes higher lows while z-score makes lower lows, confirming trend continuation in an uptrend
Hidden Bearish Divergence: Price makes lower highs while z-score makes higher highs, confirming downtrend continuation
The system uses pivot detection with configurable lookback periods and distance requirements, then draws connecting lines and labels directly on the chart when divergences occur.
Yearly Statistics Tracking:
The indicator maintains historical records of maximum z-score deviations over yearly periods (configurable bar count). This provides context by showing whether current extremes are unusual compared to typical annual ranges. The average yearly maximum helps traders understand if the current market is exhibiting normal volatility or exceptional conditions.
Mean Reversion Probability:
Based on the current z-score magnitude, the indicator calculates and displays the statistical probability that price will revert toward the mean. Higher absolute z-scores indicate stronger mean reversion probabilities, ranging from 38% at ±0.5 standard deviations to 99.7% at ±3 standard deviations.
Comprehensive Statistics Table:
A customizable on-chart table displays real-time statistics including:
Current z-score value with directional indicator
Predicted z-score based on momentum
Current year's maximum absolute z-score
Historical average yearly maximum
Mean reversion probability percentage
Zone status classification (Normal, Moderate, High, Extreme)
Directional bias (Bullish, Bearish, Neutral)
Active divergence status
Volume contraction status with ratio
Optimal setup detection (combining extreme z-scores with volume contraction)
Optimal Entry Setup Detection:
The most sophisticated feature identifies high-probability trading setups by combining multiple factors. An "Optimal Long" signal triggers when z-score reaches -3.5 or below AND volume is contracted. An "Optimal Short" signal appears when z-score exceeds +3.5 AND volume is contracted. This combination suggests extreme price deviation occurring on low volume, often preceding strong reversals.
Alert System:
The script includes a unified alert mechanism that triggers when z-score crosses specific thresholds:
Crossing above/below ±3.5 standard deviations (extreme levels)
Crossing above/below ±4 standard deviations (critical levels)
Alerts fire once per bar with confirmation (previous bar must be on opposite side of threshold) to avoid false signals.
Practical Application:
This indicator is designed for mean reversion traders who seek statistically significant price extremes. The combination of z-score measurement, volume analysis, momentum projection, and divergence detection creates a multi-layered confirmation system. Traders can use extreme z-scores as potential reversal zones, while the direction model and divergence signals help time entries more precisely. The volume contraction filter adds an additional layer of confluence, identifying moments when reduced participation may precede explosive moves back toward the mean.
Chart Attached: NSE GMR Airports, EoD 12/12/25
DISCLAIMER: This information is provided for educational purposes only and should not be considered financial, investment, or trading advice.Happy Trading
Session ATR Progression Tracker📊 Session ATR Progression Tracker - SIYL Regression Trading Tool
Track how much of your instrument's 7-day Average True Range (ATR) has been covered during the current trading session. This indicator is specifically designed for regression traders who follow the "Stay In Your Lane" (SIYL) methodology, helping you identify when the probability of mean reversion significantly increases. If you are interested in more on that check out Rod Casselli and tradersdevgroup.com.
🎯 Key Features:
• Real-time ATR Coverage Percentage - See at a glance what percentage of the 7-day ATR has been covered in the current session
• SIYL-Optimized Thresholds - See at a glance when the instrument has achieved 80% and 100% ATR coverage, the proven thresholds where mean reversion probability increases (customizable)
• Flexible Session Modes:
- Daily: Resets at calendar day change
- Session: Uses exchange-defined trading sessions
- Custom Session: Set your exact session start/end times (perfect for futures traders and international markets)
• Visual Alerts - Color-coded display (gray → orange → red) and optional background highlighting
• Repositionable Display - Choose from 9 screen positions to avoid chart clutter
• Session Markers - Green triangles mark the start of each new session
• Detailed Stats - View current range, ATR value, session high/low, and session status
💡 Why Use This Indicator?
This tool is built around a proven concept: regression trading becomes significantly more effective once a session has achieved at least 80% of its 7-day ATR. At this threshold, the probability of price reverting to mean increases substantially, creating higher-probability trade setups for SIYL practitioners.
Benefits for regression traders:
- Identify optimal entry points when mean reversion probability is highest (≥80% ATR coverage)
- Avoid premature regression entries before adequate range has been established
- Recognize when daily moves have "earned their range" and are ripe for reversal
- Time fade-the-move and counter-trend strategies with statistical backing
- Improve win rates by trading only after proven probability thresholds are met
⚙️ Setup Instructions:
1. Add the indicator to your chart
2. Select your preferred "Reset Mode" (recommend "Custom Session" for futures/international markets)
3. If using Custom Session, enter your session times in 24-hour format (e.g., 0930-1600 for US stocks, 1700-1600 for CME futures)
4. Adjust alert thresholds if desired (default: 80% and 100% - proven SIYL thresholds)
5. Position the display where it's most visible on your chart
📈 Works Across All Markets:
Stocks • Futures • Forex • Indices • Crypto • Commodities
Perfect for regression traders, mean reversion specialists, and SIYL practitioners who want to trade with probability on their side by entering only after the session has "earned its range."
---
Tip: For futures contracts with overnight sessions that span calendar days (like MES, MNQ, MYM), use "Custom Session" mode with your exchange's official session times for accurate tracking.
EMA Slope Angle V2 Auto Threshold# EMA Slope Angle Indicator
## Overview
The EMA Slope Angle Indicator visualizes the Exponential Moving Average (EMA) slope as an angle in degrees, providing traders with a clear, quantitative measure of trend strength and direction. The indicator features **automatic threshold calculation based on Gaussian distribution**, making it adaptive to any market and timeframe.
## Key Features
### 🎯 **Automatic Threshold Calculation (NEW!)**
- **Gaussian Distribution-Based**: Automatically calculates optimal thresholds from the 50% interquartile range (IQR) of historical angle data
- **Asset-Adaptive**: Thresholds adjust to each instrument's unique volatility and price characteristics
- **No Manual Tuning Required**: Simply enable "Use Auto Thresholds" and let the indicator optimize itself
### 📊 **Dynamic EMA Coloring**
- **Color Intensity**: EMA line color intensity reflects slope strength
- **Visual Feedback**:
- Green shades for uptrends (darker = stronger)
- Red shades for downtrends (darker = stronger)
- Gray for flat/neutral conditions
### 📈 **Regime Detection**
- **Three Regimes**: RISING, FALLING, and FLAT
- **Smart Classification**: Based on statistical distribution of angles
- **Non-Repainting**: All calculations use confirmed bars only
### 🔔 **Trend-Shift Signals**
- **Visual Arrows**: Automatic signals when transitioning from FLAT to RISING/FALLING
- **Configurable**: Enable/disable signals as needed
- **Reliable**: Only triggers on significant regime changes
### 📋 **KPI Dashboard**
- **Real-Time Metrics**: Current angle, regime, and last signal
- **Auto-Threshold Display**: Shows calculated thresholds when auto-mode is active
- **Statistics**: Optional angle distribution statistics
- **Clean Layout**: Top-right corner, non-intrusive
### 📊 **Angle Statistics (Optional)**
- **Distribution Analysis**: Histogram of angle ranges
- **Dynamic Buckets**: Automatically adjusts to data distribution when auto-mode is enabled
- **Percentage Breakdown**: See how often each angle range occurs
## Settings
### Main Settings
- **EMA Length**: Period for the Exponential Moving Average (default: 50)
- **Slope Lookback Bars**: Number of bars to calculate slope over (default: 5)
### Angle Settings
- **Use Auto Thresholds**: Enable automatic threshold calculation (recommended!)
- **Analysis Period**: Number of bars to analyze for distribution (default: 500)
- **Manual Thresholds**: Flat, Rising, and Falling triggers (used when auto-mode is off)
- **Max Angle for Color Saturation**: Maximum angle for color intensity scaling
### Display Options
- **Colors**: Customize uptrend, downtrend, and flat colors
- **Show Signals**: Enable/disable trend-shift arrows
- **Show Statistics**: Display angle distribution table
- **Show Dashboard**: Toggle KPI dashboard visibility
## How It Works
### Angle Calculation
The indicator calculates the angle between the current EMA value and the EMA value N bars ago:
```
Angle = arctan((EMA_now - EMA_then) / lookback) × 180° / π
```
### Auto-Threshold Calculation
When enabled, the indicator:
1. Analyzes historical angle data over the specified period
2. Calculates mean and standard deviation
3. Determines thresholds based on the 50% interquartile range (IQR):
- **Flat Threshold**: ±0.674σ (middle 50% of data)
- **Rising Trigger**: 75th percentile (mean + 0.674σ)
- **Falling Trigger**: 25th percentile (mean - 0.674σ)
### Regime Classification
- **FLAT**: Angle within ±Flat Threshold
- **RISING**: Angle ≥ Rising Trigger
- **FALLING**: Angle ≤ Falling Trigger
## Use Cases
### Trend Following
- Identify strong trends (high angle values)
- Spot trend reversals (regime changes)
- Filter trades based on trend strength
### Range Trading
- Detect flat/consolidation periods
- Avoid trading during choppy markets
- Enter when regime shifts from FLAT to RISING/FALLING
### Multi-Timeframe Analysis
- Apply to different timeframes for confirmation
- Use higher timeframe for trend direction
- Use lower timeframe for entry timing
## Tips for Best Results
1. **Enable Auto-Thresholds**: Let the indicator adapt to your instrument
2. **Adjust Analysis Period**: Use more bars for stable markets, fewer for volatile ones
3. **Combine with Price Action**: Use regime changes as confirmation, not standalone signals
4. **Multi-Timeframe**: Check higher timeframes for trend context
5. **Backtest First**: Test settings on historical data before live trading
## Technical Details
- **Non-Repainting**: All calculations use `barstate.isconfirmed`
- **Pine Script v6**: Latest version for optimal performance
- **Efficient**: Minimal computational overhead
- **Customizable**: Extensive settings for fine-tuning
## Version History
**v2.0** (Current)
- Added automatic threshold calculation based on Gaussian distribution
- Dynamic bucket adjustment for statistics
- Enhanced dashboard with auto-threshold display
- Improved regime detection using IQR method
**v1.0**
- Initial release with manual thresholds
- Basic EMA coloring
- Trend-shift signals
- KPI dashboard
## Support
For questions, suggestions, or bug reports, please leave a comment or contact the author.
---
**Disclaimer**: This indicator is for educational purposes only. Past performance does not guarantee future results. Always use proper risk management and never risk more than you can afford to lose.
**Keywords**: EMA, slope, angle, trend, automatic thresholds, Gaussian distribution, regime detection, non-repainting, adaptive
Expectativa de Juros (Fed)An indicator that measures future expectations for US interest rates, measured by the difference between the Fed's interest rate and pricing on the CME.
SCOTTGO - Buy Sell Volume📊 SCOTTGO - Buy Sell Volume Bars - Delta - Up Down Volume Bars
This indicator disaggregates the total volume traded on each bar into estimated Buying Volume and Selling Volume to visualize market pressure and dominance directly in a dedicated sub-pane.
Key Features:
Volume Disaggregation: Uses a standard formula to estimate how much of a bar's total volume was associated with upward (buying) pressure and how much was associated with downward (selling) pressure.
Visual Clarity: Plots the Buy Volume (teal, upward) and Sell Volume (red, downward) as separate columns against a transparent total volume background, allowing for quick assessment of pressure balance.
Real-Time Badge: A dynamic badge is fixed to the corner of the chart (default: Top Right) providing a numeric summary of the latest bar:
Buy %: Percentage of the bar's total volume estimated as Buying Volume.
Sell %: Percentage of the bar's total volume estimated as Selling Volume.
Delta %: The magnitude of the volume difference (Delta) as a percentage of total volume, indicating the strength of the dominant side.
Dominance Indicator: The background color of the badge changes dynamically to immediately signal whether Buying (customizable color, default: Teal) or Selling (customizable color, default: Red) pressure was dominant on the current bar.
Usage:
Traders can use this tool to identify periods of heavy accumulation (high Buy Volume) or distribution (high Sell Volume), providing insight into the conviction behind price movements.
SCOTTGO - RSI Divergence IndicatorRSI Divergence Indicator
This indicator combines the Relative Strength Index (RSI) with an automatic divergence detection system.
It is designed to help traders spot potential trend changes by:
Color-Coded RSI: The main RSI line dynamically changes color (e.g., green/red) above and below a user-defined threshold (default 50) to highlight strong or weak momentum instantly.
Divergence Signals: It automatically identifies and plots four types of RSI divergences (Regular Bullish, Hidden Bullish, Regular Bearish, and Hidden Bearish) between the price and the oscillator.
Custom Alerts: Includes alerts for all divergence types so you can be notified when a new signal is found.
This tool helps visualize momentum shifts and potential reversals in the market.
Simple Candle Strategy# Candle Pattern Strategy - Pine Script V6
## Overview
A TradingView trading strategy script (Pine Script V6) that identifies candlestick patterns over a configurable lookback period and generates trading signals based on pattern recognition rules.
## Strategy Logic
The strategy analyzes the most recent N candlesticks (default: 5) and classifies their patterns into three categories, then generates buy/sell signals based on specific pattern combinations.
### Candlestick Pattern Classification
Each candlestick is classified as one of three types:
| Pattern | Definition | Formula |
|---------|-----------|---------|
| **Close at High** | Close price near the highest price of the candle | `(high - close) / (high - low) ≤ (1 - threshold)` |
| **Close at Low** | Close price near the lowest price of the candle | `(close - low) / (high - low) ≤ (1 - threshold)` |
| **Doji** | Opening and closing prices very close; long upper/lower wicks | `abs(close - open) / (high - low) ≤ threshold` |
### Trading Rules
| Condition | Action | Signal |
|-----------|--------|--------|
| Number of Doji candles ≥ 3 | **SKIP** - Market is too chaotic | No trade |
| "Close at High" count ≥ 2 + Last candle closes at high | **LONG** - Bullish confirmation | Buy Signal |
| "Close at Low" count ≥ 2 + Last candle closes at low | **SHORT** - Bearish confirmation | Sell Signal |
## Configuration Parameters
All parameters are adjustable in TradingView's "Settings/Inputs" tab:
| Parameter | Default | Range | Description |
|-----------|---------|-------|-------------|
| **K-line Lookback Period** | 5 | 3-20 | Number of candlesticks to analyze |
| **Doji Threshold** | 0.1 | 0.0-1.0 | Body size / Total range ratio for doji identification |
| **Doji Count Limit** | 3 | 1-10 | Number of dojis that triggers skip signal |
| **Close at High Proximity** | 0.9 | 0.5-1.0 | Required proximity to highest price (0.9 = 90%) |
| **Close at Low Proximity** | 0.9 | 0.5-1.0 | Required proximity to lowest price (0.9 = 90%) |
### Parameter Tuning Guide
#### Proximity Thresholds (Close at High/Low)
- **0.95 or higher**: Stricter - only very strong candles qualify
- **0.90 (default)**: Balanced - good for most market conditions
- **0.80 or lower**: Looser - catches more patterns, higher false signals
#### Doji Threshold
- **0.05-0.10**: Strict doji identification
- **0.10-0.15**: Standard doji detection
- **0.15+**: Includes near-doji patterns
#### Lookback Period
- **3-5 bars**: Fast, sensitive to recent patterns
- **5-10 bars**: Balanced approach
- **10-20 bars**: Slower, filters out noise
## Visual Indicators
### Chart Markers
- **Green Up Arrow** ▲: Long entry signal triggered
- **Red Down Arrow** ▼: Short entry signal triggered
- **Gray X**: Skip signal (too many dojis detected)
### Statistics Table
Located at top-right corner, displays real-time pattern counts:
- **Close at High**: Count of candles closing near the high
- **Close at Low**: Count of candles closing near the low
- **Doji**: Count of doji/near-doji patterns
### Signal Labels
- Green label: "✓ Long condition met" - below entry bar
- Red label: "✓ Short condition met" - above entry bar
- Gray label: "⊠ Too many dojis, skip" - trade skipped
## Risk Management
### Exit Strategy
The strategy includes built-in exit rules based on ATR (Average True Range):
- **Stop Loss**: ATR × 2
- **Take Profit**: ATR × 3
Example: If ATR is $10, stop loss is at -$20 and take profit is at +$30
### Position Sizing
Default: 100% of equity per trade (adjustable in strategy properties)
**Recommendation**: Reduce to 10-25% of equity for safer capital allocation
## How to Use
### 1. Copy the Script
1. Open TradingView
2. Go to Pine Script Editor
3. Create a new indicator
4. Copy the entire `candle_pattern_strategy.pine` content
5. Click "Add to Chart"
### 2. Apply to Chart
- Select your preferred timeframe (1m, 5m, 15m, 1h, 4h, 1d)
- Choose a trading symbol (stocks, forex, crypto, etc.)
- The strategy will generate signals on all historical bars and in real-time
### 3. Configure Parameters
1. Right-click the strategy on chart → "Settings"
2. Adjust parameters in the "Inputs" tab
3. Strategy will recalculate automatically
4. Backtest results appear in the Strategy Tester panel
### 4. Backtesting
1. Click "Strategy Tester" (bottom panel)
2. Set date range for historical testing
3. Review performance metrics:
- Win rate
- Profit factor
- Drawdown
- Total returns
## Key Features
✅ **Execution Model Compliant** - Follows official Pine Script V6 standards
✅ **Global Scope** - All historical references in global scope for consistency
✅ **Adjustable Sensitivity** - Fine-tune all pattern detection thresholds
✅ **Real-time Updates** - Works on both historical and real-time bars
✅ **Visual Feedback** - Clear signals with labels and statistics table
✅ **Risk Management** - Built-in ATR-based stop loss and take profit
✅ **No Repainting** - Signals remain consistent after bar closes
## Important Notes
### Before Trading Live
1. **Backtest thoroughly**: Test on at least 6-12 months of historical data
2. **Paper trading first**: Practice with simulated trades
3. **Optimize parameters**: Find the best settings for your trading instrument
4. **Manage risk**: Never risk more than 1-2% per trade
5. **Monitor performance**: Review trades regularly and adjust as needed
### Market Conditions
The strategy works best in:
- Trending markets with clear directional bias
- Range-bound markets with defined support/resistance
- Markets with moderate volatility
The strategy may underperform in:
- Highly choppy/noisy markets (many false signals)
- Markets with gaps or overnight gaps
- Low liquidity periods
### Limitations
- Works on chart timeframes only (not intrabar analysis)
- Requires at least 5 bars of history (configurable)
- Fixed exit rules may not suit all trading styles
- No trend filtering (will trade both directions)
## Technical Details
### Historical Buffer Management
The strategy declares maximum bars back to ensure enough historical data:
```pine
max_bars_back(close, 20)
max_bars_back(open, 20)
max_bars_back(high, 20)
max_bars_back(low, 20)
```
This prevents runtime errors when accessing historical candlestick data.
### Pattern Detection Algorithm
```
For each bar in lookback period:
1. Calculate (high - close) / (high - low) → close_to_high_ratio
2. If close_to_high_ratio ≤ (1 - threshold) → count as "Close at High"
3. Calculate (close - low) / (high - low) → close_to_low_ratio
4. If close_to_low_ratio ≤ (1 - threshold) → count as "Close at Low"
5. Calculate abs(close - open) / (high - low) → body_ratio
6. If body_ratio ≤ doji_threshold → count as "Doji"
Signal Generation:
7. If doji_count ≥ cross_count_limit → SKIP_SIGNAL
8. If close_at_high_count ≥ 2 AND last_close_at_high → LONG_SIGNAL
9. If close_at_low_count ≥ 2 AND last_close_at_low → SHORT_SIGNAL
```
## Example Scenarios
### Scenario 1: Bullish Signal
```
Last 5 bars pattern:
Bar 1: Closes at high (95%) ✓
Bar 2: Closes at high (92%) ✓
Bar 3: Closes at mid (50%)
Bar 4: Closes at low (10%)
Bar 5: Closes at high (96%) ✓ (last bar)
Result:
- Close at high count: 3 (≥ 2) ✓
- Last closes at high: ✓
- Doji count: 0 (< 3) ✓
→ LONG SIGNAL ✓
```
### Scenario 2: Skip Signal
```
Last 5 bars pattern:
Bar 1: Doji pattern ✓
Bar 2: Doji pattern ✓
Bar 3: Closes at mid
Bar 4: Doji pattern ✓
Bar 5: Closes at high
Result:
- Doji count: 3 (≥ 3)
→ SKIP SIGNAL - Market too chaotic
```
## Performance Optimization
### Tips for Better Results
1. **Use Higher Timeframes**: 15m or higher reduces false signals
2. **Combine with Indicators**: Add volume or trend filters
3. **Seasonal Adjustment**: Different parameters for different seasons
4. **Instrument Selection**: Test on liquid, high-volume instruments
5. **Regular Rebalancing**: Adjust parameters quarterly based on performance
## Troubleshooting
### No Signals Generated
- Check if lookback period is too large
- Verify proximity thresholds aren't too strict (try 0.85 instead of 0.95)
- Ensure doji limit allows for trading (try 4-5 instead of 3)
### Too Many False Signals
- Increase proximity thresholds to 0.95+
- Reduce lookback period to 3-4 bars
- Increase doji limit to 3-4
- Test on higher timeframes
### Strategy Tester Shows Losses
- Review individual trades to identify patterns
- Adjust stop loss and take profit ratios
- Change lookback period and thresholds
- Test on different market conditions
## References
- (www.tradingview.com)
- (www.tradingview.com)
- (www.investopedia.com)
- (www.investopedia.com)
## Disclaimer
**This strategy is provided for educational and research purposes only.**
- Not financial advice
- Past performance does not guarantee future results
- Always conduct thorough backtesting before live trading
- Trading involves significant risk of loss
- Use proper risk management and position sizing
## License
Created: December 15, 2025
Version: 1.0
---
**For updates and modifications, refer to the accompanying documentation files.**
SigmaFlowSigmaFlow is a professional signal management connector designed to work with the SigmaFlow app. This indicator allows traders to structure trade setups (Entry, Stop Loss, TP1, TP2) on TradingView and send them into the SigmaFlow platform, where signals are managed, tracked, and delivered to Telegram.
Professional signal management — from TradingView to Telegram.
How SigmaFlow Works:
Sends trade data from TradingView to Telegram via the SigmaFlow platform.
SigmaFlow handles signal management, organization, history tracking, performance metrics, and Telegram delivery.
What It Does NOT Do:
Does not generate trading signals
Does not provide investment advice
Does not execute trades
Requirements:
TradingView plan with webhook alerts*
Active SigmaFlow account*
Disclaimer
SigmaFlow is a signal management and delivery tool only. All trade ideas are created manually by users. Trading involves risk and past performance does not guarantee future results.
BTC - Bitcoin Strategic Dashboard by RM Title: BTC - Bitcoin Strategic Dashboard | RM
Overview & Philosophy
The Bitcoin Strategic Dashboard is a comprehensive analytics tool designed to provide deeper market context beyond simple price action.
While a standard chart displays price history, this dashboard focuses on the structural health of the market. It aims to answer clearer questions: Is the asset statistically overextended? Is the current volatility compressed or expanding? How is Bitcoin currently correlating with traditional equity markets?
This script aggregates key data points—Performance, Risk, Valuation, and Macro Correlations—into a single, organized table. It is designed to be a quiet, high-density reference tool that sits unobtrusively in the corner of your screen, helping to contextualize daily price movements without cluttering your workspace.
Methodology & Module Breakdown
The dashboard is divided into 5 strategic modules. Here is exactly how to read them, how they are calculated, and how to interpret the data.
1. PERFORMANCE
This section answers: "Is Bitcoin actually beating the traditional market, and by how much?"
BTC Return : The raw percentage growth of Bitcoin.
Timeframes: 1-Year (Tactical Trend) and 4-Year (The Halving Cycle).
Alpha (vs SPX / Gold):
Meaning : "Alpha" measures true outperformance. It tells you how much better your capital worked in Bitcoin compared to the S&P 500 (Stocks) or Gold.
Calculation : We use a Relative Growth Ratio. Instead of simple subtraction, we calculate the growth factor of BTC divided by the growth factor of the Benchmark.
Interpretation :
Green: Bitcoin is outperforming. It is the superior vehicle for capital.
Red: Bitcoin is underperforming traditional assets (Opportunity Cost is high).
2. RISK PROFILE
This section answers: "How dangerous is the market right now?"
Drawdown (DD):
Meaning : The percentage loss from the 1-Year High.
Interpretation : Deep Drawdowns (e.g., > -50%) historically signal generational buying opportunities (Deep Red). Small Drawdowns (< -5%) signal we are near "Discovery Mode" (Blue/Green).
Sharpe Ratio:
Meaning : The industry standard for "Risk-Adjusted Return." It asks: "Is the profit worth the stress?"
Timeframe : Annualized over 365 Days.
Interpretation :
> 1.0: Good. The return justifies the risk.
> 2.0: Excellent. (Dark Green).
< 0.0: Bad. You are taking risk for negative returns.
Sortino Ratio:
Meaning : Similar to Sharpe, but it only counts downside volatility as "risk." Bitcoin often rallies aggressively (Good Volatility); Sortino ignores the upside "risk" and focuses only on minimizing losses.
Volatility (Vol) & Rank:
Meaning : How violently the price is moving.
Calculation : We compare the current 30-Day Volatility against the last 4 Years of volatility history (Rank 0-100).
Interpretation (The Squeeze Strategy) :
BLUE (Cold / <25%): Volatility is historically low. The market is "compressed." Big moves often follow these periods.
RED (Hot / >75%): Volatility is extreme. High risk of mean reversion or panic.
3. VALUATION & MOMENTUM
This section answers: "Is Bitcoin cheap or expensive?"
Mayer Multiple (MM):
Meaning: A "Godfather" of Bitcoin ratios.
Calculation : Current Price divided by the 200-Day Moving Average.
Interpretation :
< 0.8 (Blue): Historically "Cheap."
1.0: Fair Value (Price = Trend).
> 2.4 (Red): Speculative Bubble territory.
RSI (Relative Strength Index):
Timeframe : 14 Days.
Interpretation : >70 suggests the market is overheated (Red). <30 suggests oversold conditions (Blue).
Trend (ADX) :
Meaning : The Average Directional Index measures the strength of a trend, not the direction.
Interpretation : Values >25 (Green) indicate a strong trend is present. Values <20 (Gray) indicate a choppy/sideways market (no trend).
vs 200W (Macro):
Meaning : The distance to the 200-Week Moving Average.
Interpretation : This line is historically the "Cycle Bottom" or "Absolute Support" for Bitcoin. Being close to it (or below it) is rare and often marks cycle lows.
4. MACRO CORRELATIONS
This section answers: "Is Bitcoin moving on its own, or just following the Stock Market?"
vs TradFi (SPX):
Timeframe : 90-Day Correlation Coefficient.
Interpretation :
High Positive (Red): BTC is just acting like a tech stock. No "Safe Haven" status.
Negative/Zero (Green): BTC is "decoupled." It is moving independently of Wall Street.
vs DXY (US Dollar):
Interpretation : Bitcoin usually moves inverse to the Dollar.
Negative (Green): Normal healthy behavior.
Positive (Red): Warning signal. If both DXY and BTC rise, something is breaking in the system.
5. HISTORICAL LEDGER
A Year-by-Year breakdown of returns.
Feature : You can toggle the comparison column in the settings to compare Bitcoin against either S&P 500 or Gold.
Usage : Helps visualize the cyclical nature of returns (e.g., the 4-year cycle pattern of Green-Green-Green-Red).
How to Read the Visuals (Heatmap)
The dashboard uses a standardized Bloomberg-style heatmap to let you assess the market state in milliseconds:
🟢 Green: Profit / Good Performance / Positive Alpha.
🔴 Red: Loss / Overheating / High Risk.
🔵 Blue: "Cold" / Cheap / Low Volatility (Potential Buy Zones).
🟠 Orange: Warning / High Drawdown.
⚫ Gray/Black: Neutral or Fair Value.
Settings & Customization
Visuals: Change the text size (Tiny, Small, Normal) to fit your screen resolution.
Modules: You can toggle individual sections on/off to save screen space.
Calculation: Switch the Historical Benchmark between "S&P 500" and "Gold" depending on your thesis.
Disclaimer
This script is for research and educational purposes only. The metrics provided (Sharpe, Sortino, Mayer Multiple) are derived from historical data and do not guarantee future performance. "Cheap" (Low Mayer Multiple) does not mean the price cannot go lower. Always manage your own risk.
Tags
bitcoin, btc, bloomberg, terminal, dashboard, onchain, mayer multiple, sharpe ratio, volatility, alpha, risk management, Rob Maths
Improved Candle Strategy (without daily squared)# Candle Pattern Trading Strategy
## Core Logic
Analyzes the last 5 candlesticks to identify "close at high" and "close at low" patterns, generating long/short signals.
## Trading Conditions
- **Long**: ≥2 bars closed at high in past 5 bars + current bar closes at high → Open long
- **Short**: ≥2 bars closed at low in past 5 bars + current bar closes at low → Open short
- **Filter**: If ≥3 doji patterns detected, skip trading
## Risk Management
- Stop Loss: Based on entry bar's high/low
- Take Profit: Risk × 2x multiplier
- Cooldown: No trading for 2 bars after entry
- Session Filter: No trading for first 5 bars after market open
## Configurable Parameters
- Lookback period, doji threshold, close proximity ratio, TP/SL ratio, cooldown bars, etc.
**Use Cases**: 1-minute and higher timeframes on stocks/futures
EM Levelsstdv levels for you using VIX and VXN for ES and NQ so hopefully it helps you try it out and have fun
Session HeatmapIntraday Seasonality
Overview
Analyzes historical patterns by time of day. Identifies when volatility, volume, and open interest changes tend to be highest or lowest.
Features
Multiple Metrics: TR (volatility), Volume, and Open Interest changes
Flexible Grouping: View patterns by weekday or month to spot day-of-week or seasonal effects
Heatmap Visualization: Blue (low) to Red (high) color scale for quick pattern recognition
Percentile Mode: Reduces outlier impact by using 5th-95th percentile range
Timezone Support: Display in UTC alongside your local time
Metrics Explained
TR: Volatility - when markets move most
Volume: Liquidity - when participation is highest
OI Increase: When new positions are opened
OI Decrease: When positions are closed
OI Net: Net open interest change
Usage
Set your timezone and preferred slot size (30min/1H)
Choose a date range (relative or custom)
Select a metric to analyze
Use "Group By" to see weekday or monthly patterns
Switch to Percentile color scale if outliers dominate
Notes
Chart timeframe should be equal to or smaller than Slot Size
OI metrics require Binance Perpetual symbols
DST is not automatically adjusted; consider seasonal shifts for US/EU sessions
Index Construction Tool🙏🏻 The most natural mathematical way to construct an index || portfolio, based on contraharmonic mean || contraharmonic weighting. If you currently traded assets do not satisfy you, why not make your own ones?
Contraharmonic mean is literally a weighted mean where each value is weighted by itself.
...
Now let me explain to you why contraharmonic weighting is really so fundamental in two ways: observation how the industry (prolly unknowably) converged to this method, and the real mathematical explanation why things are this way.
How it works in the industry.
In indexes like TVC:SPX or TVC:DJI the individual components (stocks) are weighted by market capitalization. This market cap is made of two components: number of shares outstanding and the actual price of the stock. While the number of shares holds the same over really long periods of time and changes rarely by corporate actions , the prices change all the time, so market cap is in fact almost purely based on prices itself. So when they weight index legs by market cap, it really means they weight it by stock prices. That’s the observation: even tho I never dem saying they do contraharmonic weighting, that’s what happens in reality.
Natural explanation
Now the main part: how the universe works. If you build a logical sequence of how information ‘gradually’ combines, you have this:
Suppose you have the one last datapoint of each of 4 different assets;
The next logical step is to combine these datapoints somehow in pairs. Pairs are created only as ratios , this reveals relationships between components, this is the only step where these fundamental operations are meaningful, they lose meaning with 3+ components. This way we will have 16 pairs: 4 of them would be 1s, 6 real ratios, and 6 more inverted ratios of these;
Then the next logical step is to combine all the pairs (not the initial single assets) all together. Naturally this is done via matrices, by constructing a 4x4 design matrix where each cell will be one of these 16 pairs. That matrix will have ones in the main diagonal (because these would be smth like ES/ES, NQ/NQ etc). Other cells will be actual ratios, like ES/NQ, RTY/YM etc;
Then the native way to compress and summarize all this structure is to do eigendecomposition . The only eigenvector that would be meaningful in this case is the principal eigenvector, and its loadings would be what we were hunting for. We can multiply each asset datapoint by corresponding loading, sum them up and have one single index value, what we were aiming for;
Now the main catch: turns out using these principal eigenvector loadings mathematically is Exactly the same as simply calculating contraharmonic weights of those 4 initial assets. We’re done here.
For the sceptics, no other way of constructing the design matrix other than with ratios would result in another type of a defined mean. Filling that design matrix with ratios Is the only way to obtain a meaningful defined mean, that would also work with negative numbers. I’m skipping a couple of details there tbh, but they don’t really matter (we don’t need log-space, and anyways the idea holds even then). But the core idea is this: only contraharmonic mean emerges there, no other mean ever does.
Finally, how to use the thing:
Good news we don't use contraharmonic mean itself because we need an internals of it: actual weights of components that make this contraharmonic mean, (so we can follow it with our position sizes). This actually allows us to also use these weights but not for addition, but for subtraction. So, the script has 2 modes (examples would follow):
Addition: the main one, allows you to make indexes, portfolios, baskets, groups, whatever you call it. The script will simply sum the weighted legs;
Subtraction: allows you to make spreads, residual spreads etc. Important: the script will subtract all the symbols From the first one. So if the first we have 3 symbols: YM, ES, RTY, the script will do YM - ES - RTY, weights would be applied to each.
At the top tight corner of the script you will see a lil table with symbols and corresponding weights you wanna trade: these are ‘already’ adjusted for point value of each leg, you don’t need to do anything, only scale them all together to meet your risk profile.
Symbols have to be added the way the default ones are added, one line : one symbol.
Pls explore the script’s Style setting:
You can pick a visualization method you like ! including overlays on the main chart pane !
Script also outputs inferred volume delta, inferred volume and inferred tick count calculated with the same method. You can use them in further calculations.
...
Examples of how you can use it
^^ Purple dotted line: overlay from ICT script, turned on in Style settings, the contraharmonic mean itself calculated from the same assets that are on the chart: CME_MINI:RTY1! , CME_MINI:ES1! , CME_MINI:NQ1! , CBOT_MINI:YM1!
^^ precious metals residual spread ( COMEX:GC1! COMEX:SI1! NYMEX:PL1! )
^^ CBOT:ZC1! vs CBOT:ZW1! grain spread
^^ BDI (Bid Dope Index), constructed from: NYSE:MO , NYSE:TPB , NYSE:DGX , NASDAQ:JAZZ , NYSE:IIPR , NASDAQ:CRON , OTC:CURLF , OTC:TCNNF
^^ NYMEX:CL1! & ICEEUR:BRN1! basket
^^ resulting index price, inferred volume delta, inferred volume and inferred tick count of CME_MINI:NQ1! vs CME_MINI:ES1! spread
...
Synthetic assets is the whole new Universe you can jump into and never look back, if this is your way
...
∞
Vertical Time LinesVertical Time Lines is an indicator that draws vertical lines at specific times of each day on the price chart.
⚙️ Main Features
Up to 5 independent time lines
Precise hour and minute editing (HH:MM)
Individual enable/disable option per line
Customizable line color and style
Works on any asset and any timeframe
📝 Note
Due to Pine Script limitations, the lines are drawn using UTC time, not the time zone configured on the chart.
Lines are generated only when a candle exists exactly at the configured minute. If candles for the specified hours and minutes are not visible on the chart, the lines will not be displayed.
Custom ORBIT GSK-VIZAG-AP-INDIA🚀 Custom ORBIT — Opening Range Breakout & Reversal Indicator
This indicator automatically calculates and plots the Opening Range (OR) high and low levels for a user-defined session and duration. It is designed to assist intraday traders by providing immediate visual signals for both price breakouts and subsequent reversals from these key levels.
The indicator is particularly suitable for markets with defined trading hours, such as the Indian indices (Nifty, Bank Nifty), given its default time settings are based on GMT+5:30.
⚙️ How It Works (Indicator Logic)
The indicator operates based on three main logical components: time definition, level calculation, and signal generation.
1. Time Session and Range Definition: All time calculations are based on GMT+5:30 (Indian Standard Time/IST). The script defines a specific trading session from a customizable start time (default 9:15 AM) to a session end time (default 3:30 PM). The Opening Range (OR) is established during the initial duration, which is set by the rangeMinutes input (default 15 minutes, meaning the OR is calculated from 9:15 AM to 9:30 AM).
2. Level Calculation and Plotting: During the initial range duration, the script captures the absolute highest price (OR High) and the absolute lowest price (OR Low). Once this period ends, two horizontal lines—a green line for the OR High and a red line for the OR Low—are drawn and automatically extended across the chart for the remainder of the active trading session. The visual style of these lines can be customized to Dotted, Dashed, or Solid.
3. Breakout and Reversal Logic: The indicator actively tracks the market's state relative to the OR levels to generate four distinct signals:
Break Up: A signal is generated when the closing price crosses over the OR High, indicating potential upward momentum.
Break Down: A signal is generated when the closing price crosses under the OR Low, indicating potential downward momentum.
Reversal Down: This yellow signal occurs only after a price has already broken above the OR High (Break Up state), and then the price moves back into the range (closing below the ORH), suggesting a failed breakout.
Reversal Up: This yellow signal occurs only after a price has already broken below the OR Low (Break Down state), and then the price moves back into the range (closing above the ORL), suggesting a failed breakdown.
💡 Suggested Use Cases
The signals generated by this indicator can be used in two primary ways:
Breakout Trading: A trader may enter a long position on a "Break Up" signal or a short position on a "Break Down" signal. A common risk management practice is to use the opposite OR level (ORL for long trades, ORH for short trades) as a stop-loss reference.
Faded Breakout / Reversal Trading: Look for the yellow "Reversal Up" or "Reversal Down" signals. These signals indicate a rejection of the OR level, and a trader may take a counter-trend position with the expectation that the price will return to the consolidation range or move toward the opposite OR level.
⚠️ Educational Disclaimer
This indicator is for educational and illustrative purposes only. It provides technical signals based on mathematical calculation of price action and should not be construed as financial advice, trading advice, or a solicitation to buy or sell any financial instrument. Trading carries a high level of risk, and you may lose more than your initial deposit. Past performance is not indicative of future results. Always consult with a qualified financial professional before making any investment decisions.
Market Session Terrain Monitor vs 1.0 (UTC)Summary
Market Session Terrain Monitor helps traders understand where the market is within its normal intraday behavior, not where it should go. It is a decision-support tool designed to reduce late entries, over-trading, and narrative bias by grounding intraday analysis in historical session statistics.
Purpose
Market Session Terrain Monitor provides statistical context for intraday market movement by analyzing how much each major trading session typically moves, how much it has moved so far, and what market state the current session inherits from previous sessions.
The indicator is designed to answer one core question:
Is the current session early, normal, or already expanded relative to its historical behavior?
This indicator does not predict direction and does not generate buy or sell signals. It is intended as a context and state-awareness tool to support independent, structure-based decision making.
Sessions Analyzed
The trading day is divided into three independent sessions, defined in UTC time:
• Asia
• London
• New York
Each session is analyzed separately using its own historical data. No session is assumed to control or predict the behavior of another.
Session Range
For each session, the indicator measures the session range, defined as the session high minus the session low. This captures how much the market actually moved during that session, regardless of direction.
P90 Expansion Benchmark
For each session, the indicator calculates a P90 expansion benchmark.
• P90 represents the range that only about ten percent of historical sessions exceed
• It reflects a large but repeatable expansion, not an extreme outlier
• It is used as a normalization reference so sessions with different volatility characteristics can be compared on equal terms
The P90 values are displayed in the table header in price units, such as USD, as a reference for scale.
Percent of P90
Current and previous session ranges are expressed as a percentage of that session’s own P90.
This shows:
• How much of a statistically large session has already been used
• Whether the session is still early, behaving normally, or approaching expansion
Rolling Comparative Table
The table displays three rows, ordered by time and anchored to the current active session:
• Current · Session
• Previous · Session
• Previous-2 · Session
Each row shows:
• Session name
• Session range in price units
• Session range as a percentage of that session’s P90
This rolling layout provides context about the market state inherited by the current session without implying causality.
How to Use the Indicator
The indicator helps with:
• Identifying whether a session is early or late in its statistical range
• Avoiding entries when a session is already stretched
• Recognizing compression versus expansion regimes
• Understanding the market state the current session inherits
The indicator does not:
• Predict direction
• Forecast highs or lows
• Assume that one session determines the next
Directional decisions should come from price structure, execution rules, and risk management.
Design Philosophy
• Range first, direction second
• State awareness over narrative
• Statistical normalization instead of absolute numbers
• Comparative, not predictive
The indicator intentionally avoids estimating remaining range or subtracting previous session movement, as those approaches introduce bias and false causality.
Suitable Markets
• Gold and silver
• Forex pairs
• Indices
• Other liquid instruments with clear session behavior
Intraday Volume Pulse GSK-VIZAG-AP-INDIA📊 Intraday Volume Pulse — by GSK-VIZAG-AP-INDIA
Overview:
This indicator displays a simple and effective intraday volume summary in table format, starting from a user-defined session time. It provides an approximate breakdown of buy volume, sell volume, cumulative delta, and total volume — all updated in real-time.
🧠 Key Features
✅ Session Start Control
Choose the session start hour and minute (default is 09:15 for NSE).
🌐 Timezone Selector
View volume data in your preferred timezone: IST, GMT, EST, CST, etc.
📈 Buy/Sell Volume Estimation Logic
Buy Volume: When candle closes above open
Sell Volume: When candle closes below open
Equal: Volume split equally if Open == Close
🔄 Daily Auto-Reset
All volume metrics reset at the start of a new trading day.
🎨 Color-Coded Volume Insights
Buy Volume: Green shade if positive
Sell Volume: Red shade if positive
Cumulative Delta: Dynamic red/green based on net pressure
Total Volume: Neutral gray with emphasis text
🧾 Readable Number Formatting
Volumes are displayed in "K", "L", and "Cr" units for easier readability.
📌 Table Positioning
Choose from top/bottom corners to best fit your layout.
⚠️ Note
All data shown is approximate and based on candle structure — it does not reflect actual order book or tick-level data. This is a visual estimation tool to guide real-time intraday decisions.
✍️ Signature
GSK-VIZAG-AP-INDIA
Creator of practical TradingView tools focused on volume dynamics and trader psychology.
Market Session Terrain Monitor v1.0Summary
Market Session Terrain Monitor helps traders understand where the market is within its normal intraday behavior, not where it should go. It is a decision-support tool designed to reduce late entries, over-trading, and narrative bias by grounding intraday analysis in historical session statistics.
Purpose
Market Session Terrain Monitor provides statistical context for intraday market movement by analyzing how much each major trading session typically moves, how much it has moved so far, and what market state the current session inherits from previous sessions.
The indicator is designed to answer one core question:
Is the current session early, normal, or already expanded relative to its historical behavior?
This indicator does not predict direction and does not generate buy or sell signals. It is intended as a context and state-awareness tool to support independent, structure-based decision making.
Sessions Analyzed
The trading day is divided into three independent sessions, defined in UTC time:
• Asia
• London
• New York
Each session is analyzed separately using its own historical data. No session is assumed to control or predict the behavior of another.
Session Range
For each session, the indicator measures the session range, defined as the session high minus the session low. This captures how much the market actually moved during that session, regardless of direction.
P90 Expansion Benchmark
For each session, the indicator calculates a P90 expansion benchmark.
• P90 represents the range that only about ten percent of historical sessions exceed
• It reflects a large but repeatable expansion, not an extreme outlier
• It is used as a normalization reference so sessions with different volatility characteristics can be compared on equal terms
The P90 values are displayed in the table header in price units, such as USD, as a reference for scale.
Percent of P90
Current and previous session ranges are expressed as a percentage of that session’s own P90.
This shows:
• How much of a statistically large session has already been used
• Whether the session is still early, behaving normally, or approaching expansion
Rolling Comparative Table
The table displays three rows, ordered by time and anchored to the current active session:
• Current · Session
• Previous · Session
• Previous-2 · Session
Each row shows:
• Session name
• Session range in price units
• Session range as a percentage of that session’s P90
This rolling layout provides context about the market state inherited by the current session without implying causality.
How to Use the Indicator
The indicator helps with:
• Identifying whether a session is early or late in its statistical range
• Avoiding entries when a session is already stretched
• Recognizing compression versus expansion regimes
• Understanding the market state the current session inherits
The indicator does not:
• Predict direction
• Forecast highs or lows
• Assume that one session determines the next
Directional decisions should come from price structure, execution rules, and risk management.
Design Philosophy
• Range first, direction second
• State awareness over narrative
• Statistical normalization instead of absolute numbers
• Comparative, not predictive
The indicator intentionally avoids estimating remaining range or subtracting previous session movement, as those approaches introduce bias and false causality.
Suitable Markets
• Gold and silver
• Forex pairs
• Indices
• Other liquid instruments with clear session behavior
Option Chain Pro+ [Max Pain + PCR]
# 📊 Option Chain Pro+ - Complete Options Trading System
## 🎯 Overview
**Option Chain Pro+** is the most comprehensive options analysis indicator for Indian indices (NIFTY, BANKNIFTY, FINNIFTY, MIDCAP, SENSEX, BANKEX). This professional-grade tool combines real-time option chain data, Greeks calculation, Max Pain analysis, Put-Call Ratio (PCR), and intelligent trading signals - all in one powerful indicator.
Perfect for both **premium sellers** and **directional option buyers**, this indicator provides actionable trading signals with specific strike recommendations and entry prices.
---
## ✨ KEY FEATURES
### 📈 **Complete Option Chain Display**
- **Real-time option prices** for Calls and Puts across multiple strikes
- **All 5 Greeks**: Delta (Δ), Gamma (Γ), Theta (θ), Vega (ν), Rho (ρ)
- **Implied Volatility (IV)** for each strike
- **Put-Call Ratio (PCR)** column showing sentiment at each strike level
- **Configurable strikes** (5-15 strikes, default: 9)
- **Color-coded highlighting** for easy identification:
- 🟠 Orange: ATM (At-The-Money) strike
- 🔴 Red: Max Pain strike (💀MP)
- 🟢 Green: Recommended Call buy (🚀)
- 🟣 Magenta: Recommended Put buy (🔻)
### 💀 **Max Pain Analysis**
- **Automatic calculation** of Max Pain point (where option buyers lose most)
- **Visual highlighting** in option chain table
- **Chart level** plotting (red dashed line)
- **Trading signals** based on distance from Max Pain
- **Most effective** in expiry week (last 3-5 days)
### 📊 **Put-Call Ratio (PCR) Analysis**
- **Overall PCR**: Total Put premium / Total Call premium
- **Strike-wise PCR**: Individual PCR at each strike level
- **Color-coded signals**:
- 🔴 Red (PCR > 1.5): Bearish - Heavy put buying
- 🟠 Orange (PCR 0.7-1.5): Neutral - Balanced
- 🟢 Green (PCR < 0.7): Bullish - Heavy call buying
- **Support/Resistance identification** from PCR levels
### 🎯 **Intelligent Trading Signals**
#### **Greek-Based Analysis (7 Indicators)**
1. **DELTA**: Direction bias (Bullish/Bearish/Neutral)
2. **GAMMA**: Risk assessment (High/Moderate/Low)
3. **THETA**: Time decay speed (Fast/Moderate/Slow)
4. **VEGA**: Volatility environment (High/Moderate/Low)
5. **VIX**: Fear gauge (High/Moderate/Low fear)
6. **PCR**: Market sentiment (Bearish/Neutral/Bullish)
7. **MAX PAIN**: Price magnet effect (Below/At/Above)
#### **💰 Premium Selling Signals**
- **Automated recommendations** for credit strategies
- Signals: SELL PREMIUM / HEDGE/PROTECT / NEUTRAL STRATEGY
- Perfect for Iron Condors, Credit Spreads, and premium collection
#### **🚀 Option Buying Signals**
- **Specific strike recommendations** for directional trades
- **Entry prices** displayed in real-time
- **Risk/Reward assessment**: FAVORABLE / MODERATE / UNFAVORABLE
- **Visual highlighting** in option chain for recommended strikes
- Separate signals for Calls (🚀) and Puts (🔻)
### 📐 **Advanced Greeks Calculation**
- **Black-Scholes model** implementation in Pine Script
- **Real-time calculation** for all strikes
- **Accurate pricing** using current market data
- **Configurable risk-free rate** (default: 6.5%)
- **IV estimation** from India VIX with multiplier option
---
## 🔧 HOW IT WORKS
### **Data Collection**
1. Fetches real-time spot/futures price
2. Calculates ATM (At-The-Money) strike automatically
3. Retrieves option prices for configured number of strikes
4. Pulls India VIX for volatility estimation
### **Greeks Calculation**
- Implements Black-Scholes model for European options
- Calculates Delta, Gamma, Theta, Vega, Rho for each strike
- Uses 3 days to expiry (configurable via expiry date input)
- Adjusts for Indian market conventions
### **Max Pain Calculation**
- Simulates price settlement at each strike
- Calculates total option buyer losses (Calls + Puts)
- Identifies strike with maximum buyer loss
- Updates in real-time as prices change
### **PCR Analysis**
- Computes Put/Call premium ratio at each strike
- Aggregates overall PCR across all strikes
- Color-codes based on sentiment thresholds
- Identifies support/resistance from extreme PCR values
### **Signal Generation**
Combines multiple factors:
- Greek values (especially Delta, Gamma, Theta)
- VIX level (volatility environment)
- PCR sentiment (fear/greed gauge)
- Max Pain distance (price magnet)
- Generates BUY or SELL recommendations with specific strikes
---
## 🎨 VISUAL COMPONENTS
### **Main Option Chain Table (17 Columns)**
Left to Right:
1. **Call Greeks**: Rho, Gamma, Theta, Vega, Delta
2. **Call IV**: Implied Volatility
3. **Call Price**: Premium
4. **Strike**: Strike price with markers (*ATM, 💀MP, 🚀, 🔻)
5. **PCR**: Put-Call Ratio (color-coded)
6. **Put Price**: Premium
7. **Put IV**: Implied Volatility
8. **Put Greeks**: Delta, Vega, Theta, Gamma, Rho
**Footer**: ATM IV | Overall PCR | Max Pain | VIX | VWAP
### **Trading Signals Table (16 Rows)**
1. **Header**: Indicator | Value | Signal | Action
2. **7 Analysis Rows**: Delta, Gamma, Theta, Vega, VIX, PCR, Max Pain
3. **Sell Strategy**: Recommendation for premium selling
4. **Buy Opportunity**: Recommendation for directional buying
5. **Buy Details**: Specific strike + Entry price
6. **Risk/Reward**: Assessment of buy opportunity
### **Chart Elements**
- **Price plot**: Underlying price (white line)
- **ATM line**: Orange dashed horizontal line
- **Max Pain line**: Red dashed horizontal line
---
## ⚙️ SETTINGS & CUSTOMIZATION
### **Plot Settings**
- **Spot Symbol**: NIFTY, BANKNIFTY, MIDCAP, FINNIFTY, SENSEX, BANKEX
- **Ref Strike**: Manual strike reference (used when Auto Tracking = NONE)
- **Expiry Date**: Format YYYY-MM-DD (e.g., 2025-12-19)
- **Auto Tracking**: SPOT / FUTURES / NONE
- FUTURES (recommended): Uses futures price for ATM calculation
- SPOT: Uses spot index price
- NONE: Uses manual Ref Strike
- **Dashboard Location**: Position of option chain table (9 positions)
- **Signals Location**: Position of trading signals table (9 positions)
### **Display Settings**
- **Number of Strikes**: 5-15 (default: 9)
- More strikes = Better Max Pain accuracy
- Fewer strikes = Faster loading
- **Color Scheme**: Dark / Light
- **Show Trading Signals**: Toggle signals table ON/OFF
- **Show Symbols (Debug)**: Display option symbols instead of prices
### **Strike Difference**
Configure strike intervals for each index:
- NIFTY: 50 (default)
- BANKNIFTY: 100 (default)
- MIDCAP: 25 (default)
- FINNIFTY: 50 (default)
- SENSEX: 100 (default)
- BANKEX: 100 (default)
### **Advanced Settings**
- **Risk Free Rate**: 6.5% (default) - Used in Greeks calculation
- **IV Multiplier**: 1.0 (default) - Adjust VIX-based IV estimation
### **Buy Strategy**
- **Buy Strike Distance (OTM)**: 1-5 strikes (default: 2)
- 1 = Closer to ATM (higher probability, lower leverage)
- 2 = Balanced (recommended)
- 3-5 = Further OTM (lower probability, higher leverage)
---
## 📚 TRADING STRATEGIES SUPPORTED
### **1. Premium Selling Strategies**
**When to use**: High Theta + Low VIX + High IV Rank
- Iron Condors
- Credit Spreads (Bull/Bear)
- Naked Put selling (cash-secured)
- Ratio spreads
**Signals to watch**:
- SELL STRATEGY = "SELL PREMIUM"
- Theta > -15 (fast decay)
- VIX > 15 (high premiums)
- Gamma < 0.002 (low risk)
### **2. Directional Buying**
**When to use**: Low VIX + High Gamma + Strong trend
- ATM/OTM Call buying (bullish)
- ATM/OTM Put buying (bearish)
- Debit spreads
**Signals to watch**:
- BUY OPPORTUNITY = "🚀 BUY CALL" or "🔻 BUY PUT"
- RISK/REWARD = "FAVORABLE"
- VIX < 13 (cheap options)
- Clear directional bias from Delta
### **3. Max Pain Trading (Expiry Week)**
**When to use**: Last 3 days before expiry
- Price gravitates toward Max Pain
- Fade extremes, buy toward Max Pain
**Example**:
- Max Pain: 26000
- Current: 25850 (below)
- Action: Buy 25900 CE, target 26000
### **4. PCR Contrarian**
**When to use**: Extreme PCR readings
- PCR > 1.5: Excessive fear → Sell Puts
- PCR < 0.7: Excessive greed → Sell Calls
### **5. Support/Resistance from PCR**
**When to use**: Identify key levels
- High PCR at strike = Strong support (Put wall)
- Low PCR at strike = Strong resistance (Call wall)
---
## 💡 HOW TO USE
### **Step 1: Setup**
1. Add indicator to NIFTY/BANKNIFTY chart
2. Set expiry date (Thursday for weekly, last Thursday for monthly)
3. Choose number of strikes (9 recommended)
4. Select Auto Tracking = FUTURES
5. Position tables (Option Chain: top_right, Signals: bottom_right)
### **Step 2: Analyze Greeks**
Check the **Trading Signals Table**:
- **Delta**: Market direction bias
- **Gamma**: Risk of sudden moves
- **Theta**: Speed of time decay
- **Vega**: Volatility environment
- **VIX**: Overall fear/greed
- **PCR**: Put/Call sentiment
- **Max Pain**: Price magnet
### **Step 3: Identify Opportunities**
**For Premium Selling**:
- Check "💰 SELL STRATEGY" row
- If "SELL PREMIUM" → Look for credit spread setups
- High Theta + Low Gamma = Ideal for selling
**For Option Buying**:
- Check "🎯 BUY OPPORTUNITY" row
- If "🚀 BUY CALL" or "🔻 BUY PUT" appears
- Note the recommended STRIKE and PRICE
- Check RISK/REWARD assessment
- FAVORABLE = Full position size
- MODERATE = Half position size
- UNFAVORABLE = Wait
### **Step 4: Execute**
1. Locate highlighted strike in option chain (🚀 green or 🔻 magenta)
2. Verify price matches recommendation
3. Execute trade with proper position sizing
4. Set stop loss: 50% of premium paid for buyers
5. Target: 100-150% profit (2-2.5x)
### **Step 5: Monitor**
- **Max Pain line**: Price tends to gravitate here near expiry
- **PCR values**: Watch for shifts in sentiment
- **Greeks changes**: Delta/Gamma shifts indicate trend changes
- **VIX spikes**: Exit short premium positions if VIX > 20
---
## 🎓 INTERPRETATION GUIDE
### **Delta Signals**
- **> 0.6**: Bullish bias → Sell Puts / Buy Calls
- **0.4-0.6**: Neutral → Iron Condor / Range strategies
- **< 0.4**: Bearish bias → Sell Calls / Buy Puts
### **Gamma Signals**
- **> 0.002**: High risk → Avoid selling, spreads only
- **0.001-0.002**: Moderate risk → Use defined risk strategies
- **< 0.001**: Low risk → Safe to sell premium
### **Theta Signals**
- **|θ| > 20**: Fast decay → Aggressive premium selling
- **|θ| 10-20**: Moderate decay → Credit spreads
- **|θ| < 10**: Slow decay → Buy options (cheaper)
### **Vega Signals**
- **> 12**: High volatility → Sell volatility (straddles/strangles)
- **8-12**: Moderate → Neutral strategies
- **< 8**: Low volatility → Buy options (underpriced)
### **VIX Signals**
- **> 15**: High fear → Sell premium (expensive options)
- **12-15**: Moderate → Neutral
- **< 12**: Low fear → Buy protection / Long options
### **PCR Signals**
- **> 1.5**: Bearish (Put heavy) → Contrarian: Sell Puts
- **0.7-1.5**: Neutral (Balanced) → Range strategies
- **< 0.7**: Bullish (Call heavy) → Contrarian: Sell Calls
### **Max Pain Signals**
- **Below Max Pain**: Upside bias → Buy Calls / Sell Puts
- **At Max Pain**: Consolidation → Iron Condor
- **Above Max Pain**: Downside bias → Buy Puts / Sell Calls
---
## 📊 EXAMPLE SCENARIOS
### **Scenario 1: Premium Selling Setup**
```
Greeks Analysis:
- Delta: 0.52 (Neutral)
- Gamma: 0.0010 (Low Risk)
- Theta: -18 (Fast Decay)
- Vega: 13.5 (High Vol)
- VIX: 16.5 (High Fear)
- PCR: 1.4 (Neutral)
Signal: SELL PREMIUM ✅
Action: Sell Iron Condor
Setup: Sell 26050 CE + 25850 PE, Buy wings
```
### **Scenario 2: Bullish Buy Setup**
```
Greeks Analysis:
- Delta: 0.58 (Bullish)
- Gamma: 0.0018 (High - Big moves expected)
- Theta: -12 (Moderate)
- Vega: 8.5 (Moderate)
- VIX: 11.2 (Low - Cheap options)
- PCR: 1.6 (Bearish - Contrarian opportunity)
- Max Pain: 26000, Current: 25850
Signal: 🚀 BUY CALL
Strike: 26050 CE
Price: 12.50
Risk/Reward: FAVORABLE ✅
Action: Buy 26050 CE at ₹12.50
Target: ₹25-30 (2x)
Stop: ₹6 (50% loss)
```
### **Scenario 3: Max Pain Trade**
```
Max Pain: 26000
Current Price: 25850 (150 points below)
Days to Expiry: 2
PCR: 1.2 (Neutral)
Signal: BELOW MAX PAIN → Upside Likely
Action: Buy 25900 CE
Reason: Price likely to move toward Max Pain
Target: 26000 (Max Pain level)
```
---
## ⚠️ IMPORTANT NOTES
### **Data Limitations**
- Uses **simplified Greeks** calculation (assumes 3 DTE by default)
- Option prices may have slight delays (TradingView data refresh)
- Max Pain calculation is **approximation** based on current premiums
- Not all option symbols may be available on TradingView
### **Best Practices**
1. **Verify prices** on your broker platform before trading
2. **Use during market hours** (9:15 AM - 3:30 PM IST) for accurate data
3. **Most effective** 3-5 days before expiry
4. **Combine with price action** and trend analysis
5. **Risk management**: Never risk more than 2% per trade
### **Optimization Tips**
- **Increase strikes** to 9-11 for better Max Pain accuracy
- **Use FUTURES** tracking for liquid indices (NIFTY, BANKNIFTY)
- **Enable debug mode** initially to verify symbols are correct
- **Adjust IV Multiplier** if VIX seems over/underestimated
---
## 🔄 UPDATES & SUPPORT
### **Version 1.0 Features**
✅ Complete option chain display (17 columns)
✅ All 5 Greeks calculation
✅ Max Pain analysis
✅ Put-Call Ratio (PCR) - Overall + Strike-wise
✅ Trading signals (Buy + Sell)
✅ Specific strike recommendations
✅ Risk/Reward assessment
✅ Support for 6 Indian indices
✅ Configurable strikes (5-15)
✅ Dark/Light color schemes
✅ Auto ATM tracking
### **Planned Updates**
🔜 OI (Open Interest) data integration
🔜 Historical Max Pain tracking
🔜 PCR trends and momentum
🔜 Custom alerts for signals
🔜 Multi-expiry analysis
🔜 Volatility smile/skew display
---
## 📖 EDUCATIONAL RESOURCES
### **Understanding Greeks**
- **Delta**: Rate of change in option price vs underlying (0-1 for calls, -1-0 for puts)
- **Gamma**: Rate of change of Delta (highest at ATM)
- **Theta**: Time decay per day (always negative for buyers)
- **Vega**: Sensitivity to volatility changes
- **Rho**: Sensitivity to interest rate changes (less important for short-term)
### **Max Pain Theory**
Max Pain suggests that market makers manipulate prices toward the strike where option buyers lose the most money. While controversial, it has statistical validity in expiry week when:
1. Volume is high
2. Market makers hedge positions
3. Pin risk causes clustering at certain strikes
### **PCR as Sentiment Indicator**
- PCR > 1: More put buying than call buying (bearish)
- PCR < 1: More call buying than put buying (bullish)
- **Contrarian use**: Extreme readings often precede reversals
- **Confirmation use**: With trend for continuation trades
---
## 🎯 WHO IS THIS FOR?
### ✅ **Perfect For:**
- Options traders (all experience levels)
- Premium sellers (credit strategies)
- Directional option buyers
- Intraday option traders
- Swing traders in options
- Risk managers
- Market makers
- Professional traders
### ✅ **Use Cases:**
- Daily options trading on NIFTY/BANKNIFTY
- Weekly expiry strategies
- Monthly expiry positioning
- Volatility trading
- Hedging portfolios
- Greeks-based strategies
- Statistical arbitrage
---
## ⚖️ DISCLAIMER
**This indicator is for educational and informational purposes only.**
- NOT financial advice or recommendation to buy/sell
- Past performance does not guarantee future results
- Options trading involves substantial risk of loss
- Greeks calculations are theoretical models
- Max Pain is not guaranteed to be reached
- Always verify data with your broker
- Use proper risk management and position sizing
- Consult a financial advisor before trading
**The author is not responsible for any trading losses.**
---
## 📞 SUPPORT
For questions, issues, or feature requests:
- Comment below this indicator
- Check TradingView documentation for Pine Script basics
- Review NSE option chain for symbol verification
---
## 🏆 WHY CHOOSE THIS INDICATOR?
### **Comprehensive**
- Most complete options analysis tool on TradingView
- Combines Greeks + Max Pain + PCR + Signals in one
### **Professional**
- Used by professional traders
- Based on proven Black-Scholes model
- Real-time calculations
### **Actionable**
- Specific strike recommendations
- Entry prices displayed
- Clear Buy/Sell signals
- Risk/Reward assessment
### **Customizable**
- Multiple indices supported
- Configurable strikes
- Adjustable parameters
- Flexible positioning
### **Visual**
- Color-coded for easy reading
- Highlighted opportunities
- Chart levels for reference
- Professional table layouts
---
## 🚀 GET STARTED
1. **Add to chart**: Click "Add to favorites" ⭐
2. **Apply to NIFTY or BANKNIFTY** chart
3. **Set expiry date** in settings
4. **Configure strikes** (9 recommended)
5. **Start trading** with professional insights!
---
**Happy Trading! 📊💰**
*If you find this indicator useful, please like, comment, and share!*
*Your feedback helps improve future versions.*
---
**Tags**: #options #greeks #nifty #banknifty #maxpain #pcr #delta #gamma #theta #vega #optionchain #india #nse #trading #signals
Call-Put Cross Strike Match [Pro]📊 Call-Put Cross Strike Match - Professional Options Trading Indicator
Advanced NSE Options Analysis with AI-Powered Trading Signals & Dynamic Display
🎯 Overview
The Call-Put Cross Strike Match is an institutional-grade options analysis tool designed exclusively for NSE NIFTY and BANKNIFTY traders. Built on Pine Script v6, this indicator combines sophisticated cross-strike matching algorithms with intelligent trading signal generation to identify optimal options trading opportunities in real-time.
What makes it unique:
Analyzes 25 call-put combinations simultaneously
Generates actionable BUY/SELL signals using professional strategies
Fully customizable display with 9 table positions and 6 size options
Simplified setup with semi-automatic ATM detection
Clean, clutter-free interface with only essential information
Perfect for intraday scalpers, premium sellers, and positional options traders.
✨ Key Features
1. 🔍 Advanced Cross-Strike Matching Algorithm
The indicator calculates price differences for all 25 combinations (5 call strikes × 5 put strikes) and identifies the best matches based on put-call parity.
How it works:
Compares each call option price with every put option price
Calculates absolute difference: |Call - Put |
Ranks all 25 combinations from lowest to highest difference
Highlights top 3 or top 5 matches with visual checkmarks
Visual indicators:
✓✓ (Double check) = Best match (lowest price difference)
✓ (Single check) = Good matches (top 3 or top 5)
Empty cells = No match (significant price difference)
Why this matters:
When Call ≈ Put at same strike, it indicates fair pricing and synthetic position opportunities. The indicator automatically finds these opportunities across different strike combinations.
2. 🎯 Intelligent Trading Signals (Last Column)
The indicator generates professional trading recommendations based on Call-Put price difference analysis:
Signal Types:
BUY CE - Long call opportunity (bullish)
SELL CE - Short call opportunity (premium selling)
BUY PE - Long put opportunity (bearish/hedge)
SELL PE - Short put opportunity (premium selling)
BULL - Moderate bullish bias
BEAR - Moderate bearish bias
ATM - Neutral market (near parity)
NEUTRAL - No clear bias
Color-Coded for Quick Decisions:
🟩 Green = Long opportunities (BUY CE, BULL)
🟥 Red = Short call opportunities (SELL CE)
🟧 Orange = Long put opportunities (BUY PE)
🟫 Maroon = Short put opportunities (SELL PE)
⬛ Gray = Neutral zones (ATM, NEUTRAL)
3. 🤖 Three Professional Signal Modes
SMART Mode (Recommended) 🎯
Context-aware institutional strategy that considers strike position relative to spot price.
Signal Logic:
text
OTM Call Expensive (C-P > threshold, Strike > Spot):
→ SELL CE (Premium selling opportunity)
ITM Call Underpriced (C-P > threshold, Strike < Spot):
→ BUY CE (Synthetic long opportunity)
OTM Put Expensive (C-P < -threshold, Strike < Spot):
→ SELL PE (Premium selling opportunity)
ITM Put Underpriced (C-P < -threshold, Strike > Spot):
→ BUY PE (Protection or synthetic short)
Near Parity (|C-P| < threshold/4):
→ ATM (Neutral market, straddle/strangle zone)
Moderate Imbalance:
→ BULL or BEAR (Directional bias without extreme pricing)
Best for: Professional traders, option writers, synthetic position builders
MOMENTUM Mode 📈
Trend-following strategy that rides market momentum.
Signal Logic:
text
Calls Expensive (C-P > threshold):
→ BUY CE (Follow bullish momentum)
Puts Expensive (C-P < -threshold):
→ BUY PE (Follow bearish momentum)
Near Parity:
→ NEUTRAL (No clear trend)
Best for: Intraday scalpers, directional traders, swing traders
MEAN REVERSION Mode 🔄
Counter-trend strategy focused on premium selling.
Signal Logic:
text
Calls Overpriced (C-P > threshold):
→ SELL CE (Collect inflated premium)
Puts Overpriced (C-P < -threshold):
→ SELL PE (Collect inflated premium)
Near Parity:
→ ATM (Fair value, no edge)
Best for: Option writers, theta decay strategies, credit spread traders
4. 🎨 Fully Customizable Display
Dynamic Table Positioning (9 Options):
Top: left, center, right
Middle: left, center, right
Bottom: left, center, right
Choose position based on your chart layout and other indicators.
Dynamic Table Sizing (6 Options):
Auto - Adapts to content
Tiny - Minimal space (for cluttered charts)
Small - Default, best balance
Normal - Medium size (1080p monitors)
Large - Big text (4K monitors)
Huge - Maximum size (presentations)
Text scales intelligently:
Headers, data, and checkmarks adjust proportionally
Checkmarks remain visible even in tiny mode
Info row stays readable at all sizes
5. ⚙️ Simplified Input System
Auto Mode (Recommended):
Enter just 5 strikes once at market open - used for both calls and puts.
Example for NIFTY at 25,900:
text
Strike 1: 25850 (ATM - 100)
Strike 2: 25900 (ATM - 50)
Strike 3: 25950 (ATM)
Strike 4: 26000 (ATM + 50)
Strike 5: 26050 (ATM + 100)
Manual Mode (Advanced):
Enter separate call and put strikes for cross-strike arbitrage analysis.
Why this matters:
50% fewer inputs compared to traditional indicators
One-time setup at market open
Rarely needs updating (only if market moves 100+ points)
6. 🎛️ Semi-Automatic ATM Detection
The indicator automatically:
Detects current NIFTY/BANKNIFTY spot price
Calculates ATM strike (rounded to nearest 50 or 100)
Marks ATM strikes with *ATM in the table
Displays ATM and spot price in info box
No manual recalculation needed!
7. 📊 Clean Information Display
Main Table (Top/Middle/Bottom):
CE \ PE matrix showing all strike combinations
Checkmarks (✓✓ and ✓) highlighting best matches
SIGNAL column with color-coded trading recommendations
Best Match footer showing optimal combination
Info row displaying symbol, signal mode, and spot price
Info Box (Bottom Left):
Symbol (NIFTY/BANKNIFTY)
Signal Mode (Smart/Momentum/Mean Reversion)
Current Spot Price
Detected ATM Strike
Best Matched Call Strike
Best Matched Put Strike
Match Difference
C-P value for best match
📋 Quick Setup Guide (3 Steps)
Step 1: Add Indicator
Open NIFTY or BANKNIFTY chart on TradingView
Add "Call-Put Cross Strike Match " from indicators
Step 2: Configure Basic Settings
text
Symbol Detection: Auto (reads from chart)
Expiry Date: 251219 (format: YYMMDD for 19-Dec-2025)
Strike Mode: Auto
Strike Interval: 50 (for NIFTY) or 100 (for BANKNIFTY)
Step 3: Enter Strikes
At market open (9:15 AM), check current price and enter 5 strikes:
text
Example: NIFTY at 25,937
Strike 1: 25850 (ATM - 100)
Strike 2: 25900 (ATM - 50)
Strike 3: 25950 (ATM) ← Rounded to nearest 50
Strike 4: 26000 (ATM + 50)
Strike 5: 26050 (ATM + 100)
That's it! The indicator handles everything else automatically.
💡 Real-World Use Cases
1. 📉 Premium Selling (Mean Reversion Mode)
Scenario: Looking for overpriced options to write
How to use:
Set Signal Mode to "Mean Reversion"
Set Threshold: 30 (NIFTY) or 75 (BANKNIFTY)
Look for SELL CE or SELL PE signals with ✓ or ✓✓
Sell naked options or credit spreads at those strikes
Target 30-50% profit or 3-5 days theta decay
Perfect for: Credit spreads, iron condors, covered calls, naked puts
2. 📈 Directional Trading (Momentum Mode)
Scenario: Scalping intraday moves
How to use:
Set Signal Mode to "Momentum"
Set Threshold: 15 (aggressive) or 25 (conservative)
BUY CE signal + ✓✓ = Long call entry
Enter with tight stop (20% of premium)
Target 30-50% gain within 1-2 hours
Perfect for: Intraday scalping, swing trading, trend following
3. 🔄 Synthetic Positions (Smart Mode)
Scenario: Building synthetic long/short with defined risk
How to use:
Set Signal Mode to "Smart"
Look for BUY CE at ITM strike + SELL PE at OTM strike
Both should have ✓ indicator (good parity)
Creates synthetic long position
Lower capital than buying futures
Perfect for: Professional traders, arbitrage, capital efficiency
4. ⚖️ ATM Strategy Optimization (Smart Mode)
Scenario: Finding optimal strikes for straddle/strangle
How to use:
Identify strike marked *ATM
Check if signal shows ATM (balanced market)
If BULL/BEAR → Market has directional bias, adjust accordingly
✓✓ indicates best matched strike for neutral strategies
Perfect for: Volatility trading, earnings plays, event trading
5. 🛡️ Hedging Optimization (Smart Mode)
Scenario: Protecting long equity positions
How to use:
Look for BUY PE signals (protection signals)
Avoid strikes with SELL PE (expensive hedges)
✓✓ shows best value for hedge entry
Optimize hedge timing and strike selection
Perfect for: Portfolio hedging, risk management, protective puts
⚙️ Settings Guide
Symbol Settings
Symbol Detection: Auto (recommended) or Manual
Manual Symbol: NIFTY or BANKNIFTY
Expiry Date: Format YYMMDD (e.g., 251219 = 19-Dec-2025)
Update every Thursday after 3:30 PM for next week's expiry
Strike Settings
Strike Mode: Auto (recommended) or Manual
Strike Interval:
50 for NIFTY
100 for BANKNIFTY
Trading Signals
Signal Mode: Smart / Momentum / Mean Reversion
Smart: Professional institutional strategy (default)
Momentum: Trend-following for scalpers
Mean Reversion: Premium selling for writers
Signal Threshold: Sensitivity in points
NIFTY Recommendations:
Conservative: 30-40 points (fewer, higher quality signals)
Balanced: 20-25 points (default)
Aggressive: 10-15 points (more signals, more noise)
BANKNIFTY Recommendations:
Conservative: 75-100 points
Balanced: 50-60 points (default)
Aggressive: 30-40 points
Algorithm Settings
Matching Mode:
Top 3: Shows 3 best matches (cleaner display)
Top 5: Shows 5 best matches (more opportunities)
Display Settings
Show Matching Table: Enable/disable main table
Table Position: Choose from 9 positions
top_right (default) - Doesn't block price action
middle_right - Centered vertical view
bottom_right - If top is crowded
Table Size: Choose from 6 sizes
small (default) - Best for most users
normal - For 1080p/4K monitors
tiny - If you have many indicators
📊 Understanding The Table
Table Layout Example:
text
CE \ PE | 25950 | 25900 | 25850 | 26000 | 26050 | SIGNAL
---------|-------|-------|-------|-------|-------|--------
25850 | | | | | | SELL PE
25900*ATM| | ✓ | | | | ATM
25950 | ✓✓ | | | | | BULL
26000 | | | | ✓ | | BUY CE
26050 | | | | | | SELL CE
---------|-------|-------|-------|-------|-------|--------
Best Match: 25950 / 25950 (0.25)
Info: NIFTY | Smart | Spot:25881.9
Reading the Table:
Rows (Left): Call option strike prices
Columns (Top): Put option strike prices
Cells: Checkmarks where Call ≈ Put
✓✓: Best match (minimum price difference)
✓: Good matches (top 3 or 5)
Empty: Prices too different (no match)
*ATM: Automatically detected at-the-money strike
SIGNAL Column: Actionable trading recommendation for each call strike
Info Box Metrics:
Symbol: Currently analyzed index
Signal Mode: Active strategy
Spot: Current underlying price
ATM: Calculated at-the-money strike
Best Call: Matched call strike
Best Put: Matched put strike
Match Diff: Price difference (lower = better)
C-P (Best): Call minus Put for best match
📈 Best Practices
Strike Selection & Maintenance
At Market Open (9:15 AM):
Check current price (e.g., NIFTY at 25,937)
Round to nearest interval (25,950 for 50 interval)
Enter 5 strikes: -100, -50, 0, +50, +100 from ATM
Update Frequency:
Usually no update needed entire day
Update only if market moves 100+ points from initial ATM
Typically 0-2 updates per trading session
Signal Interpretation by Confidence Level
High Confidence (✓✓ + Signal):
Best match indicator present
Strongest signal quality
Highest probability setup
Medium Confidence (✓ + Signal):
Good match present
Reliable signal
Acceptable risk/reward
Low Confidence (Signal without ✓):
No match indicator
Strike far from parity
Requires additional confirmation
Risk Management Rules
Never trade signals blindly. Always:
✅ Confirm with price action and support/resistance
✅ Check overall market trend (NIFTY/BANKNIFTY direction)
✅ Consider time decay (theta) for your position
✅ Monitor IV changes (implied volatility)
✅ Use proper position sizing (1-2% risk per trade)
✅ Set stop losses (20-30% of premium for longs)
✅ Have profit targets (30-50% for scalps)
Timeframe Selection
Intraday Trading:
Use 5-minute or 15-minute chart
Momentum or Smart mode
Lower threshold (aggressive)
Quick entries and exits
Positional Trading:
Use hourly or daily chart
Smart or Mean Reversion mode
Higher threshold (conservative)
Swing trade positions
Combining with Other Tools
Recommended complements:
Support/resistance levels (horizontal lines)
Trend indicators (EMA 20/50, SuperTrend)
Volume analysis (confirm breakouts)
India VIX (volatility context)
Option chain data (open interest)
🎓 Strategy Examples
Strategy 1: Professional Premium Selling
text
Mode: Mean Reversion
Threshold: 30 (NIFTY) / 75 (BANKNIFTY)
Timeframe: Daily
Rules:
1. Wait for SELL CE or SELL PE signal
2. Verify strike has ✓ or ✓✓ (good parity)
3. Check if OTM (Strike away from spot)
4. Sell option or create credit spread
5. Target: 30-50% profit or 3-5 days theta
6. Stop: If signal changes to BUY
Position: Naked short or credit spreads
Risk: Define with spreads or capital allocation
Strategy 2: Intraday Momentum Scalping
text
Mode: Momentum
Threshold: 15 (aggressive)
Timeframe: 5-minute
Rules:
1. Wait for BUY CE signal + ✓✓
2. Enter long call immediately
3. Stop loss: 20% of premium paid
4. Target 1: 30% gain (partial exit)
5. Target 2: 50% gain (full exit)
6. Exit if signal changes or 2 hours pass
Position: Long calls or long puts only
Risk: 1-2% of capital per trade
Strategy 3: Synthetic Long Position
text
Mode: Smart
Threshold: 25 (NIFTY) / 60 (BANKNIFTY)
Timeframe: Hourly
Rules:
1. Identify BUY CE signal at ITM strike
2. Identify SELL PE signal at OTM strike
3. Both should have ✓ indicator
4. Buy ITM call + Sell OTM put = Synthetic Long
5. Lower capital than futures
6. Defined risk (width of strikes)
Position: Call debit + Put credit
Risk: Net debit paid (defined risk)
Strategy 4: ATM Straddle Entry
text
Mode: Smart
Threshold: 20 (default)
Timeframe: Daily
Rules:
1. Find strike marked *ATM
2. Check signal shows "ATM" (neutral)
3. Verify ✓✓ at that strike
4. Sell ATM call + Sell ATM put
5. Collect maximum premium
6. Exit at 30% profit or before expiry
Position: Short straddle or iron condor
Risk: Use defined risk (iron condor recommended)
🔔 Important Notes
Data Accuracy
Indicator uses TradingView's NSE options data feed
Always verify prices independently before trading
Ensure market is open (9:15 AM - 3:30 PM IST)
Check for "-" in cells indicating missing data
Expiry Management
Update expiry date every week on Thursday post-closing
Format: YYMMDD (6 digits)
Weekly expiry: Every Thursday
Monthly expiry: Last Thursday of month
Strike Format
NIFTY: Multiples of 50 (25850, 25900, 25950...)
BANKNIFTY: Multiples of 100 (51800, 51900, 52000...)
Wrong strikes = No data in table
Performance Optimization
Indicator updates every bar close
No lag or performance issues
Works on all timeframes (1m to 1D)
Maximum 5 calls + 5 puts = 10 security calls (within limits)
⚠️ Disclaimer
Trading options involves substantial risk of loss and is not suitable for all investors. This indicator is provided for educational and informational purposes only. It does not constitute financial advice, investment advice, or trading advice.
Important disclaimers:
Options can expire worthless, resulting in 100% loss
Past performance of signals is not indicative of future results
Accuracy depends on TradingView's NSE data feed
Signals are mathematical analysis, not predictions
You are solely responsible for your trading decisions
The developer is not liable for any trading losses incurred while using this indicator.
Before trading, ensure you understand:
Options Greeks (Delta, Gamma, Theta, Vega, Rho)
Implied volatility and its impact
Time decay and expiration risks
Assignment risk for short positions
Liquidity and slippage considerations
Margin requirements and capital needs
Always:
Use proper risk management (1-2% per trade)
Trade with capital you can afford to lose
Paper trade before live trading
Consult with a licensed financial advisor
Start with small position sizes
Never risk more than you can afford to lose
📊 Technical Specifications
Platform: TradingView Pine Script v6
Exchanges: NSE (National Stock Exchange of India)
Instruments: NIFTY, BANKNIFTY options
Timeframes: All (1m, 5m, 15m, 1h, 1D)
Strikes Analyzed: 5 calls × 5 puts = 25 combinations
Security Calls: 10 (5 calls + 5 puts)
Table Positions: 9 (all corners and centers)
Table Sizes: 6 (auto to huge)
Signal Modes: 3 (Smart, Momentum, Mean Reversion)
Performance: Optimized, minimal lag
🎯 Who Should Use This?
✅ Perfect For:
Options Traders: Intraday and positional
Premium Sellers: Option writers and theta strategists
Arbitrage Traders: Synthetic position builders
Straddle/Strangle Traders: ATM strategy traders
Professional Traders: Institutional-grade analysis
Volatility Traders: IV imbalance exploiters
Scalpers: Quick intraday moves
❌ Not Suitable For:
Stock options traders (NSE index-specific)
Equity-only traders (requires options knowledge)
International markets (NSE format only)
Complete beginners (requires basic options understanding)
💬 FAQ
Q: Why manual strike entry? Why not fully automatic?
A: Pine Script's type system limits fully automatic strike generation from live data. However, setup takes just 30 seconds once at market open, and the indicator handles all analysis automatically throughout the day.
Q: How often should I update strikes?
A: Rarely! Only when market moves 100+ points from initial ATM. Usually 0-2 times per day, even in volatile markets.
Q: Which Signal Mode is best?
A: Smart mode (default) for professional trading. Use Momentum for intraday scalping, Mean Reversion for premium selling.
Q: Can I use this for stock options?
A: No. The indicator is designed specifically for NSE index options (NIFTY and BANKNIFTY) with NSE format.
Q: Does it work on mobile?
A: Yes, but table display is optimized for desktop/tablet screens. Use "tiny" or "small" size on mobile.
Q: What if I see "-" in cells?
A: Check expiry format (YYMMDD), verify strikes match NSE strikes, and ensure market is open.
Q: What's the difference between ✓✓ and ✓?
A: ✓✓ = Best match (lowest price difference), highest quality. ✓ = Good matches (top 3-5), reliable quality.
Q: Can I backtest this indicator?
A: The indicator shows live analysis. For backtesting options strategies, you'll need historical options data and separate backtesting tools.
Q: What does the info box show?
A: Bottom-left box shows key metrics: symbol, signal mode, spot price, ATM strike, best matched strikes, match difference, and C-P value.
Q: Why no chart plotting?
A: v1.0 focuses on clean table display with maximum information density. Chart plotting may be added in future versions based on user feedback.
🙏 Credits
Developed by a professional options trader for the Indian trading community. Inspired by institutional trading desks and market makers who use call-put parity for daily trading decisions.
Found This Helpful?
⭐ Rate 5 stars if it improved your trading
💬 Comment with your strategy results
🔔 Follow for updates and new indicators
📢 Share with fellow options traders
Feature Requests
Continuous improvement based on trader feedback. Suggest features in comments!
Planned Features (v2.0):
Multi-expiry comparison
Greeks display (Delta, Theta, Vega)
Historical signal performance stats
Custom signal formulas
Export to CSV functionality
🏷️ Tags for Search
#Options #OptionsTrading #NIFTY #BANKNIFTY #NSE #India #OptionChain #CallPut #PutCallParity #Straddle #Strangle #ATM #TradingSignals #OptionsStrategy #PremiumSelling #OptionsScanner #Derivatives #IntradayTrading #VolatilityTrading #Arbitrage #SyntheticPosition #OptionsGreeks #OptionsSelling #OptionsWriting #IndianStockMarket #NSEOptions #OptionsAnalysis #TechnicalAnalysis #AlgoTrading #QuantTrading #ProfessionalTrading #TradingIndicator #PineScript #TradingView
📝 Version History
v1.0 (Current - Dec 2025)
Pine Script v6 implementation
Cross-strike matching (5×5 matrix, 25 combinations)
Three signal modes (Smart, Momentum, Mean Reversion)
Trading signal generation with color coding
Dynamic table positioning (9 positions)
Dynamic table sizing (6 sizes)
Intelligent text scaling
Semi-automatic ATM detection
Auto symbol detection
Simplified input system (50% fewer inputs in Auto mode)
Clean information display
Info box with key metrics
NSE NIFTY & BANKNIFTY support
Start trading smarter with institutional-grade options analysis! 📈💰🚀
Disclaimer: Options trading is subject to market risk. Please read all scheme-related documents carefully before investing.
UT Bilgi Paneli (Ugur TUFAN) English Description
UT Info Panel (Advanced Performance & Correlation Dashboard)
UT Info Panel is a comprehensive dashboard designed to help traders analyze the performance of an asset over multiple timeframes and compare it instantly with other assets or benchmark indices.
This tool overlays on the main chart, providing critical data in a clean, organized table located at the top-right corner without cluttering your workspace.
Key Features:
Detailed Performance Analysis:
Displays percentage returns for Daily, Weekly, Monthly, 3-Month, 6-Month, and 1-Year periods.
High & Low Distance Metrics:
Calculates the percentage distance to the 52-week (1 Year) High and Low levels.
Shows the distance to the All-Time High (ATH), helping to visualize potential recovery or growth margins.
Smart Dual Mode:
Mode 1 (Index Harmony): If no comparison symbols are entered, it compares the current asset with a benchmark index (e.g., XU100). It visually indicates directional correlation (Harmony) with checkmarks (✔) or crosses (✖).
Mode 2 (Multi-Asset Comparison): By adding up to 5 different symbols in the settings, the table automatically expands to show a side-by-side performance comparison of all selected assets.
Localized Visualization:
Data is presented with clear color coding (Green for positive, Red for negative) for easy reading.
How to Use:
When added, it defaults to the harmony mode with the benchmark index.
Open settings to input up to 5 different symbols you wish to compare.
The table automatically adjusts its size and positions itself at the top right.
Deviation Burn + Pivots + Advanced stop + Midpoint CancelA session-based range strategy that places buy and sell orders at the session high and low, expecting price reactions from these levels.
Additional filters help avoid low-probability trades.






















