Support and Resistance levels from Options DataINTRODUCTION
This script is designed to visualize key support and resistance levels derived from options data on TradingView charts. It overlays lines, labels, and boxes to highlight levels such as Put Walls (gamma support), Call Walls (gamma resistance), Gamma Flip points, Vanna levels, and more.
These levels are intended to help traders identify potential areas of price magnetism, reversal, or breakout based on options market dynamics. All calculations and visualizations are based on user-provided data pasted into the input field, as Pine Script cannot directly fetch external options data due to platform limitations (explained below).
For convenience, my website allows users to interact with a bot that will generate the string for up to 30 tickers at once getting nearly real-time data on demand (data is cached for 15min). With the output string pasted into this indicator, it's a bliss to shuffle through your portfolio and see those levels for each ticker.
The script is open-source under TradingView's terms, allowing users to study, modify, and improve it. It draws inspiration from common options-derived metrics like gamma exposure and vanna, which are widely discussed in financial literature. No external code is copied without rights; all logic is original or based on standard mathematical formulas.
How the Options Levels Are Calculated
The levels displayed by this script are not computed within Pine Script itself—instead, they rely on pre-calculated values provided by the user (via a pasted data string). These values are derived from options chain data fetched from financial APIs (e.g., using libraries like yfinance in Python). Here's a step-by-step overview of how these levels are generally calculated externally before being input into the script:
Fetching Options Data:
Historical and current options chain data for a ticker (e.g., strikes, open interest, volume, implied volatility, expirations) is retrieved for near-term expirations (e.g., up to 90 days).
Current stock price is obtained from recent history.
Gamma Support (Put Wall) and Resistance (Call Wall):
Gamma Calculation: For each option, gamma (the rate of change of delta) is computed using the Black-Scholes formula:
gamma = N'(d1) / (S * sigma * sqrt(T))
where S is the stock price, K is the strike, T is time to expiration (in years), sigma is implied volatility, r is the risk-free rate (e.g., 0.0445), and N'(d1) is the normal probability density function.
Weighted gamma is multiplied by open interest and aggregated by strike.
The Put Wall is the strike below the current price with the highest weighted gamma from puts (acting as support).
The Call Wall is the strike above the current price with the highest weighted gamma from calls (acting as resistance).
Short-term versions focus on strikes closer to the money (e.g., within 10-15% of the price).
Gamma Flip Level:
Net dealer gamma exposure (GEX) is calculated across all strikes:
GEX = sum (gamma * OI * 100 * S^2 * sign * decay)
where sign is +1 for calls/-1 for puts, and decay is 1 / sqrt(T).
The flip point is the price where net GEX changes sign (from positive to negative or vice versa), interpolated between strikes.
Vanna Levels:
Vanna (sensitivity of delta to volatility) is calculated:
vanna = -N'(d1) * d2 / sigma
where d2 = d1 - sigma * sqrt(T).
Weighted by open interest, the highest positive and negative vanna strikes are identified.
Other Levels:
S1/R1: Significant strikes with high combined open interest and volume (80% OI + 20% volume), below/above price for support/resistance.
Implied Move: ATM implied volatility scaled by S * sigma * sqrt(d/365) (e.g., for 7 days).
Call/Put Ratio: Total call contracts divided by put contracts (OI + volume).
IV Percentage: Average ATM implied volatility.
Options Activity Level: Average contracts per unique strike, binned into levels (0-4).
Stop Loss: Dynamically set below the lowest support (e.g., Put Wall, Gamma Flip), adjusted by IV (tighter in low IV).
Fib Target: 1.618 extension from Put Wall to Call Wall range.
Previous day levels are stored for comparison (e.g., to detect Call Wall movement >2.5% for alerts).
Effect as Support and Resistance in Technical Trading
Options levels like gamma walls influence price action due to market maker hedging:
Put Wall (Gamma Support): High put gamma below price creates a "magnet" effect—market makers buy stock as price falls, providing support. Traders might look for bounces here as entry points for longs.
Call Wall (Gamma Resistance): High call gamma above price leads to selling pressure from hedging, acting as resistance. Rejections here could signal trims, sells or even shorts.
Gamma Flip: Where gamma exposure flips sign, often a volatility pivot—crossing it can accelerate moves (bullish above, bearish below).
Vanna Levels: Positive/negative vanna indicate volatility sensitivity; crosses may signal regime shifts.
Implied Move: Shows expected range; prices outside suggest overextension.
S1/R1 and Fib Target: Volume/OI clusters act as classic S/R; Fib extensions project upside targets post-breakout.
In trading, these are not guarantees—combine with TA (e.g., volume, trends). High activity levels imply stronger effects; low CP ratio suggests bearish sentiment. Alerts trigger on proximities/crosses for awareness, not advice.
Limitations of the TradingView Platform for Data Pulling
TradingView's Pine Script is sandboxed for security and performance:
No direct internet access or API calls (e.g., can't fetch yfinance data in-script).
Limited to chart data/symbol info; no real-time options chains.
Inputs are static per load; updates require manual pasting.
Caching isn't persistent across sessions.
This prevents dynamic data pulling, ensuring scripts remain lightweight but requiring external tools for fresh data.
Creative Solution for On-Demand Data Pulling
To overcome these limitations, users can use external tools or scripts (e.g., Python-based) to fetch and compute levels on demand. The tool processes tickers, generates a formatted string (e.g., "TICKER:level1,level2,...;TIMESTAMP:unix;"), and users paste it into the script's input. This keeps data fresh without violating platform rules, as computation happens off-platform. For example, run a local script to query APIs and output the string—adaptable for any ticker.
Script Functionality Breakdown
Inputs: Custom data string (parsed for levels/timestamp); toggles for short-term/previous/Vanna/stop loss; style options (colors, transparency).
Parsing: Extracts levels for the chart symbol; gets timestamp for "updated ago" display.
Drawing: Lines/labels for levels; boxes for gamma zones/implied move; clears old elements on updates.
Info Panel: Top-right summary with metrics (CP ratio, IV, distances, activity); emojis for quick status.
Alerts: Conditions for proximities, crosses, bounces (e.g., 0.5% bounce from Put Wall).
Performance: Uses vars for persistence; efficient for real-time.
This script is educational—test thoroughly. Not financial advice; past performance isn't indicative of future results. Feedback welcome via TradingView comments.
指標和策略
BoomBros LevelsCharts
-Key Support and Resistance levels.
-Short, intermediate and long term structures points
CP Double CrossCakeProfits Double Moving Average Signals
This indicator is a refined double Special Moving Average system with integrated trend confirmation, cooldown suppression, alerts, and visual feedback.
🔹 Core Features
Double Special Moving Averages (Fast & Slow) to identify precise crossovers.
Trend EMA filter (default 800 EMA) to align signals with higher-timeframe trend.
Signal Suppression / Cooldown to avoid back-to-back false signals (user-defined bars).
Long & Sort Labels plotted directly on the chart (Long = Go long, Short = Go Short).
Alerts ready for both bullish and bearish crossover confirmations.
Background Visuals (Toggle) – highlights active cooldown zones with soft green/red shades, easily switched ON/OFF.
🔹 How It Works
A Bullish Signal (Long) fires when the Fast MA crosses above the Slow MA, slope is confirmed, and price is above the trend EMA.
A Bearish Signal (Short) fires when the fast MA crosses below the slow MA, slope is confirmed, and price is below the trend EMA.
After a signal, the indicator enters a cooldown period (number of bars set by the user) where no new signals can appear, helping to reduce noise.
During cooldown, the chart background can be shaded (green for bullish, red for bearish) for quick visual confirmation.
🔹 Inputs
MA Lengths (Slow & Fast)
Trend EMA Length & Source
Bars to Suppress Signals (cooldown)
Background Toggle & Colors
✅ Best used as a confirmation tool for entries/exits alongside broader strategy and risk management.
⚠️ Disclaimer: This script is for educational purposes only and not financial advice.
VWAP TrendGuard [KedarArc Quant]Strategy Overview: A non-repainting intraday strategy that pairs VWAP entries with an EMA-based trend gate on the entry timeframe. Entries come from VWAP Cross or Cross+Retest, with an optional Momentum exception. Exits use either an ATR emergency stop or a structural TrendBreak. The Today Panel summarizes Net-R, Win%, and PF for the current session.
Non-repainting: all higher-timeframe requests use lookahead_off (no peeking).
Works across intraday frames; keep the HTF filter your chart timeframe.
Signals & Exits
Trend gate (entry timeframe): trendUp if EMA(fast) > EMA(slow); trendDown otherwise.
Volume gate: volume SMA(volume, volLen) × volMult.
Long (Base): trendUp & volOK AND (cross above VWAP OR (Cross+Retest AND recent low VWAP
within lookback)).
Short (Base): trendDown & volOK AND (cross below VWAP OR (Cross+Retest AND recent high VWAP within lookback)).
Momentum exception (optional): body momBodyPct AND volume SMA × momVolMult allows fast
entry.
TrendBreak exit: Long closes when price < VWAP AND EMA(fast) < EMA(slow); Short closes on the
opposite.
ATR emergency stop: strategy.exit at entry with stop = close ± ATR(atrLen) × atrMult.
Multi-Timeframe FVG-Deepak kakkarFVG Indicator created for different timeframes , following are settings:
1) Choose your own timeframe or as per chart
2) Customize FVG length and limit
3) remove FVG when touched or closed !
ADX Only (Custom, same as TradingView)This is ADX indicator , same as default indicator. But it will change colour when ADX is bullish and bearish.
Draw Trend LinesSometimes the simplest indicators help traders make better decisions. This indicator draws simple trend lines, the same lines you would draw manually.
To trade with an edge, traders need to interpret the recent price action, whether it's noisy or choppy, or it's trending. Trend Lines will help traders with that interpretation.
The lines drawn are:
1. lower tops
2. higher bottoms
Because trends are defined as higher lows, or lower highs.
When you see "Wedges", formed by prices chopping between top and bottom trend lines, that's noisy environment not to be traded. When you learn to "stop yourself", you already have an edge.
Often when you see a trend, it's still not too late. Trend will continue until it doesn't. But the caveat is a very steep trend is unlikely to continue, because buying volume is extremely unbalanced to cause the steep trend, and that volume will run out of energy. (Same on the sell side of course)
Trends can reverse, and when price action breaks the trend line, Breakout/Breakdown traders can take this as an entry signal.
Enjoy, and good trading!
Zonas de Demanda e Oferta - Mais Sinais em Topos e FundosFX:EURUSD This script is a test script. Let me know if you like it. It's a model that sets us apart from other scripts. It's best to use it on Forex. It's available for an indefinite period, and we're always looking to update it for improvement.
If you have any questions, please contact us.
Ultra-Precise Scalper with OB, W/M & Liquidity Sweepsupport and resistance with order block detection and M and W PATTERNS
[TRIX] HeaderCustom text box that is always on screen can be used for trader info or trading plan strategy / rules.
[TRIX] Vertical Timeframe LinesSelect which higher timeframes vertical lines to show with optional day of week labels at top of chart. User can adjust line types and colors. User can also show +1 future timeframe vertical line divider.
Smart Trading DashboardStudy Material for Smart Trading Dashboard (Educational Use)
________________________________________
1. Introduction
The Smart Trading Dashboard is a multi-parameter technical analysis tool built in TradingView.
It combines several important market factors—trend, volume, momentum, open interest (OI), risk/reward, and option ratios—into a single visual dashboard table.
⚠️ This script is not a buy/sell machine. It is for learning market observation and developing discipline in technical analysis.
________________________________________
2. Main Components & Logic
🔹 Supertrend (Trend + Signals)
• Uses ATR (Average True Range) and a multiplier to plot dynamic support/resistance lines.
• Buy signal: Price crosses above supertrend.
• Sell signal: Price crosses below supertrend.
• Dashboard shows "LONG", "SHORT", or "WAIT".
👉 Learning: Students can observe how supertrend filters trends and compare it with sideways markets.
________________________________________
🔹 Entry, Stop Loss & Targets
• Once a signal appears, the script marks levels automatically:
o Entry: Closing price when signal generated.
o Stoploss (SL): % below (for long) or above (for short).
o Targets: 3 stepwise profit levels (10%, 20%, 30% by default).
• Also calculates Risk-Reward Ratio (RR).
👉 Learning: Students practice comparing SL vs. TP. A high RR (≥2) is safer than low RR.
________________________________________
🔹 Volume Analysis
• Uses 20-bar moving average to compare current volume.
• Shows Volume Ratio (Current ÷ Average).
o 1.5 = High volume.
o Around 1 = Normal.
o <1 = Weak.
• Volume Progress % compares today’s traded volume vs. past average.
👉 Learning: Helps understand how strong or weak a move is.
E.g., Price breakout + High Volume Ratio → Valid.
Breakout + Low Volume → Risky.
________________________________________
🔹 PCR (Put-Call Ratio)
• Simulated from 60-minute put/call volumes.
• PCR > 1.2 = Bearish bias (puts dominant).
• PCR < 0.8 = Bullish bias (calls dominant).
• Between 0.8 – 1.2 = Neutral.
👉 Learning: Students see how option traders’ positioning affects market sentiment.
________________________________________
🔹 OI Trend (Open Interest)
• Compares current hour vs. previous hour OI and price.
• Interprets into market behavior:
o Long Buildup → OI ↑ + Price ↑
o Short Buildup → OI ↑ + Price ↓
o Long Unwinding → OI ↓ + Price ↓
o Short Covering → OI ↓ + Price ↑
• Extra cases: Long Accumulation, Bearish Weakness.
👉 Learning: Beginners can observe if positions are being added or exited.
________________________________________
🔹 RSI Momentum
• RSI < 30 → Market oversold (Bullish momentum).
• RSI > 70 → Market overbought (Bearish momentum).
• Else → Neutral.
👉 Learning: Track momentum alignment with signals.
________________________________________
🔹 PDC (Previous Day Close levels)
• If price > yesterday’s high → Bullish.
• If price < yesterday’s low → Bearish.
• Else Neutral.
👉 Learning: Simple method to check if the market is breaking out of yesterday’s range.
________________________________________
🔹 Dashboard Table (Dark Theme)
The script creates a professional black-themed dashboard on the chart with:
1. Signal & Momentum → LONG/SHORT/WAIT + RSI condition.
2. Trend → Bullish/Bearish/Neutral.
3. Volume % & Buy/Sell Bias.
4. Price, Entry, SL, Targets, RR.
5. Performance metrics: Profit %, OI status, Day Range, etc.
6. Volume details: Today’s Volume, Avg Volume, Put/Call Vol, PCR, ATM Strike.
👉 Learning: Students can read multiple factors in one glance instead of switching indicators.
________________________________________
🔹 Alerts
The script can trigger alerts for:
• Buy/Sell signals.
• High volume spikes.
• Profit target achievements (5%, 10%).
👉 Learning: Students practice monitoring without staring at charts all the time.
________________________________________
3. How Students Should Use It
1. Observation First, No Trading:
Track how signals behave across trends, ranges, and news events.
2. Journal Keeping:
Note signal type, SL, RR, volume strength, and actual market result.
3. Focus on Risk/Reward:
Avoid setups where RR < 1.
4. Combine With Candlestick Study:
Look for patterns (Doji, Engulfing) near signal levels.
5. Timeframe Adaptation:
Short timeframes = noisy signals. Higher = more reliable.
________________________________________
4. Common Beginner Mistakes
• Blindly following "LONG" or "SHORT" without checking volume & OI confirmation.
• Ignoring Stop Loss (most critical).
• Trading every signal (overtrading).
• Assuming 100% accuracy.
• Not adjusting parameters (ATR, RR) for different assets.
________________________________________
5. Educational Value
By practicing with this dashboard, a student learns:
• How trend, volume, OI, momentum interact.
• Why confirmation from multiple indicators is stronger than one.
• How to think in probabilities, not certainties.
________________________________________
6. Disclaimer
This script is developed for educational purposes only under TradingView study guidelines.
• It is not financial advice.
• Past performance ≠ future results.
• Misuse for blind speculation can lead to financial loss.
• Always apply risk management and consult a certified advisor for actual trading.
________________________________________
✅ With this dashboard, students can train their market eye:
• See when signals succeed/fail.
• Understand market psychology behind OI & PCR.
• Build patience and discipline instead of chasing trades.
Disclaimer from aiTrendview
This script and its trading signals are provided for training and educational purposes only. They do not constitute financial advice or a guaranteed trading system. Trading involves substantial risk, and there is the potential to lose all invested capital. Users should perform their own analysis and consult with qualified financial professionals before making any trading decisions. aiTrendview disclaims any liability for losses incurred from using this code or trading based on its signals. Use this tool responsibly, and trade only with risk capital.
[TRIX] Multi VWAPIndicator has 4 options on VWAP's to display. Daily VWAP (time can be adjusted) and each session with times adjustable: New York, Asia, and London. Each VWAP has the option to show up to 3 standard deviation bands. All line types and colors are user adjustable.
Scalping EMA9 + Breakout (5m - 24h)//@version=6
indicator("Scalping US100 - EMA9 Breakout", overlay=true)
ema9 = ta.ema(close, 9)
plot(ema9, color=color.orange, title="EMA9")
// Condições de rompimento
breakout_up = close > high and close > ema9
breakout_down = close < low and close < ema9
// Plotar sinais visuais
plotshape(breakout_up, title="Buy Signal", location=location.belowbar, color=color.green, style=shape.labelup, text="BUY")
plotshape(breakout_down, title="Sell Signal", location=location.abovebar, color=color.red, style=shape.labeldown, text="SELL")
// Alerta para Webhook
alertcondition(breakout_up, title="Buy Alert", message="BUY - US100 🚀")
alertcondition(breakout_down, title="Sell Alert", message="SELL - US100 🔻")
[TRIX] MacrosAutomatically labels out the economic macro events and timeframe they are happening above candles. Allows user to be trade inside high volatility timeframes or avoid them.
SFP + OTO ATR [Algoliq]📌 English Explanation
🔹 What does this indicator do?
The indicator identifies Swing Failure Patterns (SFPs), which occur when price pushes above a previous swing high or below a swing low, then quickly reverses back.
In simple terms: it detects fake breakouts (stop hunts) and potential reversals.
🔹 How does it work?
Pivot detection (L/R):
Uses left/right bar counts to detect swing highs and lows.
Can be set manually or dynamically adjusted based on ATR (volatility).
SFP conditions:
Price must grab liquidity by exceeding the previous swing level.
Candle close conditions (relative to open or previous swing) confirm validity.
If confirmed → a Bearish (red) or Bullish (green) SFP is triggered.
Visuals:
Blue line → liquidity level (previous swing).
Orange dashed line → confirmation level (pivot bar open).
Labels → 🔻 Bearish SFP (red), 🔺 Bullish SFP (green).
Alerts:
Custom alerts are included to notify traders when SFPs form.
🔹 Who is this suitable for?
Best for price action / liquidity-based traders.
Particularly useful for scalpers and day traders who look for false breakouts and liquidity grabs.
Effective for reversal trading strategies after stop hunts.
[TRIX] HTF Candles + TimeSelect which HTF candles to show on LTF charts. Change colors of candles and location of candles. Shows time below each candle, location can be adjusted. Shows countdown timer, location can be adjusted. Options to show last candle H/L, range H/L, and range mid.
CCI OSYA Pyramid Strategy v1CCI OSYA Pyramid Strategy v1
📈 Strategy Description
**CCI OSYA Pyramid Strategy v1** is an advanced trading strategy that uses the CCI (Commodity Channel Index) indicator combined with an innovative pyramiding system. The strategy is designed for trending markets and maximizes profit by gradually increasing position size as the market moves in the trader's favor.
🎯 Key Features
- CCI-based signals: Uses overbought/oversold levels for entry
- Pyramiding system: Gradual position adding at target prices
- Reverse mechanics: Ability to flip positions when trend changes
- Flexible settings: Fully customizable for different trading styles
- Risk management: Controls position size and adding levels
⚙️ Recommended Settings
CCI Indicator
-CCI Length: 20
- Source: HLC3 (average of High, Low, Close)
- Upper Zone: 150
- Lower Zone: -150
Pyramiding Parameters
- Pyramiding Step: 2.0%
- Orders per Level: 10
- Max Levels: 20
- Position Size: 10% of capital in contracts
Signals
- Default Mode: Classic
- Commission: 0.1%
💡 Strategy Advantages
- Risk management: Gradual position building reduces risk
- Trend efficiency: Excellent in strong trends
- Flexibility: Adaptable to various instruments and timeframes
- Transparency: Clear entry and exit rules
- Automation: Fully automated trading process
📋 Suitable Instruments
- Forex pairs (EUR/USD, GBP/USD, USD/JPY)
- Cryptocurrencies (BTC/USD, ETH/USD)
- Indices (S&P 500, NASDAQ)
- Commodities (Gold, Oil)
⏰ Recommended Timeframes
- 1m (1 minute) - optimal balance
⚠️ Risks and Limitations
- Effective in trending conditions
- May draw down in sideways movements
- Requires sufficient deposit for pyramiding
- Historical data testing recommended
🚀 Getting Started
1. Add strategy to chart
2. Set recommended settings
3. Test on historical data
4. Start with demo account
5. Gradually move to real account
Author: OSYA
Version: 1.0
Updated: 2025
*Always test the strategy before using real funds. Trading financial markets involves the risk of capital loss.*
Reversal Patterns + Support/ResistanceDetects common reversal candlestick patterns (e.g., Engulfing, Hammer, Shooting Star, Morning/Evening Star, Doji).
Automatically plots support and resistance lines so you can see where those reversals are happening.
Is runtime‑safe (no look‑ahead bias) and works on any timeframe.
Key Levels Inc ORB by JJThis indicator is designed specifically for Stock CFDs and Indices (e.g. US30, US500, NAS100, Tesla, AMD, Meta) to help traders quickly visualise and trade around key market levels with a focus on the Opening Range Breakout (ORB).
✨ Features:
• Previous Week High/Low (PWH/PWL) – plots institutional key levels for higher-timeframe confluence.
• Opening Range (ORB) – fully customisable start & end time (default: 14:30–14:45 UK time for US markets).
• Trading Range Filter – avoid false signals in choppy markets by requiring a minimum range size (Points or %).
• Signal System
• Buy/Sell signals triggered only on candle close beyond ORH/ORL (no wick traps).
• Optional Flip Trades mode (invert signals).
• Longs, Shorts, or both can be toggled.
• Multiple signal styles (Label, Circle, Triangle, Arrow) with custom size and colours.
• Retest Confirmation (optional) – signal only fires after a price retest of the breakout level, with flexible tolerance controls (Points, %, ATR).
• ATR% Filter – suppresses signals when volatility is too low (default: ATR(14) ≥ 0.3% of price).
• Session Filter – signals only during your defined trading session (default: 14:30–21:00 UK).
• Customisable Levels – change line widths, label text, and visibility to fit your charting style.
🎯 Why use it?
This tool combines classic key levels with a robust ORB strategy to remove noise and highlight only high-probability breakout conditions. It’s flexible enough for scalpers and day traders, but also powerful for swing traders seeking confluence with weekly highs/lows.
⚙️ Default Settings (v1.0 Benchmark):
• ORB: 14:30–14:45 UK
• Trading Range: 14:30–15:00 UK (≥ 1 point)
• ATR Filter: 14-length, 0.3%
• Session: 14:30–21:00 UK
• Retest Confirmation: ON, Wick touch, 0.1 pts tolerance, 20 bars max
• Signal Style: Arrow, Size: Normal
• Buy: Green, Sell: Red
RICHI ATR LONG+SHORT STOP LOSSATR (14) + 10%
Long+Short
Not financial advice and not a call to action
/////////////
Bullish Single Candle Patterns [Crypto Varthagam]Description
- This indicator highlights three well-known single bullish candlestick signals:
Hammer – A small body with a long lower wick, often signaling potential reversal at the bottom of a downtrend.
Inverted Hammer – A small body with a long upper wick, showing potential reversal if followed by bullish confirmation.
Bullish Marubozu – A strong green candle with little to no shadows, representing clear buyer dominance.
How it works:
- The script measures candle body size relative to total range and wick size.
- It identifies patterns based on common candlestick rules (wick-to-body ratios and body position).
- Labels are plotted on the chart for easy recognition of these signals.
Unique aspects of this script:
-Clean, educational implementation focused only on three key single-candle bullish patterns.
- Uses precise mathematical ratios for consistent detection.
- Lightweight design that can be applied on any timeframe or asset.
Disclaimer:
This script is for educational purposes only. It does not provide financial advice. Always confirm signals with broader analysis, risk management, and additional tools before making trading decisions.
20/200 SMA Trading- 200SMA
- Dynamic 20SMA for relation with 200SMA (Green if Above, Red if Below)
- Colour Change, Hammer, Shotting Star Labels
- ATR based candle colouring for identifying large orders