Indikatoren und Strategien
Momentum Permission + Pivot Entry + Exit (v1.4 FINAL SCAN)plot(permitOut, "PERMIT", display=display.none)
plot(entryOut, "ENTRY", display=display.none)
plot(exitOut, "EXIT", display=display.none)
ICT Asian & London Range + First Presented FVGIndicator: ICT Sessions + First Presented FVG
What it does: This tool automates the markup of key ICT (Inner Circle Trader) timeframes and entry signals. It allows you to trade on higher timeframes (like the 5m or 15m) while the script automatically "looks inside" the 1-minute chart to find specific setups for you.
Key Features:
Session Ranges (Asian & London)
Automatically highlights the Asian Session (8 PM - Midnight NY) and London Open (2 AM - 5 AM NY).
Draws a shaded box for the session's High and Low.
New: Extends the High and Low lines to 4:00 PM NY (end of the trading day) so you can use them as liquidity targets.
The "First Presented" FVG (Sniper Logic)
It detects the very first Fair Value Gap (FVG) that forms on the 1-minute chart immediately after a session starts.
It draws this 1-minute gap on your current chart, regardless of what timeframe you are viewing.
The FVG box automatically extends to the end of the trading day (4 PM NY), showing you where price might return to "mitigate" or react later in the day.
YM Ultimate SNIPER v8.1# YM Ultimate SNIPER v8.1 - SNIPER STRICT EDITION
## 🎯 CHANGELOG: What's New in v8.1
### The Problem We Fixed
**GOD MODE was handing out awards like participation trophies.** Too many wicky, indecisive candles were getting GOD MODE status just because they had enough confluence points. A GOD MODE candle should show **CLEAR DOMINANCE** - fat body, minimal adverse wick, consistent pressure throughout formation.
---
## 🔥 MAJOR CHANGES
### 1. CANDLE DOMINANCE INDEX (CDI) - NEW METRIC
The CDI quantifies "who won the candle" on a 0-10 scale:
```
CDI COMPONENTS:
├── Body Score (0-4 pts): How fat is the body?
├── Adverse Wick Score (0-3 pts): How small is the wick against direction?
├── Favorable Wick Score (0-2 pts): Clean entry side?
└── Closing Strength (0-1 pt): Did it close near the extreme?
CDI RATINGS:
├── 8.0+ = 🔥 DOMINANT (ideal for GOD MODE)
├── 6.0-7.9 = ✓✓ STRONG
├── 4.0-5.9 = ✓ ACCEPTABLE
└── <4.0 = WEAK (not GOD MODE worthy)
```
### 2. STRICT GOD MODE GATES (6 GATES)
**Score alone no longer qualifies for GOD MODE.** Now a candle must pass ALL 6 gates:
| Gate | Requirement | Default |
|------|-------------|---------|
| **1. Score** | Must meet GOD MODE threshold | ≥9.0 |
| **2. Body** | Body ratio must be "fat" | ≥70% |
| **3. Adverse Wick** | Wick against direction must be small | ≤20% |
| **4. Delta** | Buy/sell dominance must be strong | ≥70% |
| **5. Session** | Must be in active session (configurable) | LDN/NY/PWR |
| **6. Pressure** | Intrabar pressure must be consistent | Same side dominated early AND late |
**If ANY gate fails, GOD MODE is DENIED** - even with a 10/10 score!
### 3. 30-BAR SIGNAL DISPLAY LIMIT
**Past signals are now hidden.** Only the last 30 bars show tier markers, sweeps, and absorption signals. This keeps the chart clean and focused on recent action.
```
WHAT'S HIDDEN AFTER 30 BARS:
├── Tier signals (S/A/B/Z)
├── GOD MODE markers
├── Liquidity sweep diamonds
├── Absorption crosses
└── Stop/Target lines
WHAT ALWAYS SHOWS:
├── FVG/IFVG zones (structural)
├── Order Blocks (structural)
├── Session markers (context)
└── Session background colors
```
**Configurable:** Change "Show Signals: Last N Bars" in settings (10-100)
### 4. PRESSURE CONSISTENCY TRACKING
New intrabar analysis that tracks if the **same side dominated throughout the candle**:
```
CANDLE FORMATION ANALYSIS:
├── First Half: Who dominated? (earlyBuyVol vs earlySellVol)
├── Second Half: Who dominated? (lateBuyVol vs lateSellVol)
└── Consistent? = Same side won BOTH halves
PRESSURE CONSISTENT = Buyers dominated early AND late
OR Sellers dominated early AND late
PRESSURE MIXED = Buyers dominated early, sellers late
OR Sellers dominated early, buyers late
```
**GOD MODE requires consistent pressure** when intrabar analysis is enabled.
### 5. GOD MODE DENIAL REASON IN TABLE
When a candle scores 9.0+ but fails a gate, the table now shows **WHY**:
```
DENIAL REASONS:
├── "DENIED: WICK" = Adverse wick too large (>20%)
├── "DENIED: DELTA" = Delta dominance too weak (<70%)
├── "DENIED: SESSION" = Not in active session
├── "DENIED: VOLUME" = Volume below 1.5x
└── "DENIED: PRESSURE" = Mixed pressure during formation
```
---
## 📊 NEW TABLE SECTIONS
### CANDLE QUALITY Section (NEW)
```
══ CANDLE QUALITY ══
Body | 78% | FAT
Adv Wick | 12% | CLEAN
CDI | 8.2/10 | 🔥
```
### INTRABAR Section (UPDATED)
```
══ INTRABAR ══
IB Data | 12 bars | ✓
IB Delta | 74% BUY | 🔥
Pressure | CONSISTENT | ✓ ← NEW
```
---
## ⚙️ NEW SETTINGS
### CANDLE DOMINANCE (v8.1) Group
```
GOD MODE: Min Body Ratio = 0.70 (body must be 70%+ of range)
GOD MODE: Max Adverse Wick = 0.20 (wick against direction ≤20%)
GOD MODE: Min Delta Dominance = 0.70 (70%+ buy/sell dominance)
GOD MODE: Min Intrabar Delta = 0.68 (intrabar delta ≥68%)
GOD MODE: Require Active Session = ON
GOD MODE: Require 1.5x+ Volume = ON
```
### SIGNAL DISPLAY (v8.1) Group
```
Show Signals: Last N Bars = 30
Show Historical FVG/OB Zones = ON (zones always visible)
```
---
## 🎯 PRACTICAL IMPACT
### Before v8.1 (Too Many False GOD MODE)
```
Candle: 35 point move, score 9.2, BUT:
- Body only 55% of range (thin)
- Upper wick 35% (buyers got pushed back hard)
- Intrabar showed mixed pressure
RESULT: GOD MODE ⚡ (WRONG!)
```
### After v8.1 (Strict GOD MODE)
```
Same candle: Score 9.2, but:
- Gate 2 FAILED: Body 55% < 70% required
- Gate 3 FAILED: Wick 35% > 20% allowed
- Gate 6 FAILED: Pressure inconsistent
RESULT: DENIED: WICK (Correct - this was a fake-out candle)
```
---
## 🏆 THE NEW GOD MODE STANDARD
A TRUE GOD MODE candle must show:
1. **HIGH SCORE** (≥9.0) - Multiple confluence factors aligned
2. **FAT BODY** (≥70%) - Clear directional commitment
3. **CLEAN WICKS** (≤20% adverse) - Minimal pushback
4. **STRONG DELTA** (≥70%) - One side clearly dominated
5. **IN SESSION** - Institutional participation
6. **CONSISTENT PRESSURE** - Same side controlled throughout
**Translation:** *"Institutions stepped in with size, pushed hard in one direction, and never let up. No hesitation, no give-back. This is a candle that means business."*
---
## 📈 YM/MYM OPTIMIZATION NOTES
The default settings are tuned for YM's characteristics:
- Lower volatility than NQ/GC/BTC → Tighter gates work better
- 50 pts for S-Tier is already conservative
- 70% body ratio filters out the indecisive noise
- Session requirement is crucial - YM moves on institutional flow
### Low Volume Conditions
The strict gates actually **help** in low volume:
- Wicky candles (common in low vol) get filtered
- Pressure consistency catches fake moves
- CDI prevents thin-body noise from triggering
---
## 🚀 QUICK START
1. Apply v8.1 to your 5-minute YM chart
2. Set intrabar to "1" (1-minute) or "100T" (tick)
3. Watch the CANDLE QUALITY section in the table
4. GOD MODE will now be RARE - but TRUSTWORTHY
5. Check the DENIAL reason if score is 9+ but no ⚡
---
*v8.1 SNIPER STRICT EDITION - "Fat Candles Only"*
*© Alexandro Disla*
4H Supply & Demand – 50% Mitigation (MTF clean)4H Supply & Demand – 50% Mitigation (MTF clean)
This indicator shows strictly 4h supply & demand zones
automatically deletes any zone that got filled by 51%
Adaptive Alligator - Asymmetric MH (Entry Only)
Adaptive Alligator – Asymmetric Mexican Hat (Entry Only)
This strategy combines adaptive cycle detection (wavelet + autocorrelation), directional entropy, and a Mexican Hat filter to generate highly selective LONG entry signals. Exits are based solely on the Alligator structure. The system is designed to detect asymmetric, strong, and accelerating bullish phases while filtering out market noise.
1. Adaptive Cycle Detection: The strategy analyzes the median price using wavelet decomposition (Haar, Daubechies D4/D6, Symlet 4), wavelet detail energy, and autocorrelation. It also incorporates the ratio of short-term to long-term ATR volatility. Based on these components, it computes a dominant_cycle value, which dynamically controls the lengths of the Alligator lines (Jaw, Teeth, Lips). This adaptive behavior allows the Alligator to speed up during trending phases and slow down during noise or consolidation.
2. Directional Entropy: Entropy is measured separately for upward and downward movements within the selected lookback window. The entropy difference: e_diff = entropy_down - entropy_up represents the directional bias of the market. When e_diff > 0, the market shows an organized bullish pressure; when < 0, bearish dominance.
3. Mexican Hat Filter: The Mexican Hat (Ricker Wavelet) acts as a second-derivative filter, detecting local maxima in the acceleration of directional entropy. The filtered output (mh_out) is compared against an adaptive noise level computed as SMA(|mh_out|). A signal is considered strong only when: – mh_out exceeds the adaptive noise level, – mh_out is rising relative to the previous bar. This step is critical for eliminating false signals produced by random fluctuations.
4. Entry Logic: A LONG entry requires all three layers: (1) Alligator structure: Lips > Teeth > Jaw. (2) Directional entropy bias: e_diff > 0. (3) A strong, accelerating Mexican Hat signal confirmed by a user-defined number of bars. Once all conditions are satisfied, a buy_final entry is triggered.
5. Exit Logic: Exits are intentionally simple and rely solely on the Alligator: crossunder(lips, teeth) This clean separation ensures precise, adaptive entries and stable, consistent exits.
6. Visual Components: – Alligator lines: Jaw (blue), Teeth (red), Lips (green), plotted with their characteristic offsets. – Background coloring reflects signal strength: dark green (STRONG BUY), lime (acceleration), yellow (weak bias), transparent otherwise. – A dedicated panel displays e_diff (entropy difference), mh_out (Mexican Hat output), and the adaptive noise band.
7. Diagnostic Table: A compact diagnostic dashboard shows: – MH Value, – Noise Level, – MH Acceleration (YES/NO), – Signal Status (STRONG BUY / ACCELERATING / WEAK / BEARISH). It updates on the last bar, making it suitable for live monitoring.
8. Use Case: This strategy is highly selective and ideal as an entry module within trend-following systems. By combining wavelets, entropy, and adaptive noise modeling, it effectively filters out consolidation periods and focuses only on statistically significant bullish transitions. It can be integrated with various exit frameworks such as ATR stops, channel-based exits, range boxes, or trailing logic.
Copper_to_Gold_Ratio by Zeche Cu/Au Ratio – LINES + LABELS is a clean, macro-oriented indicator built around the Copper/Gold price ratio — a well-known gauge of economic strength, market sentiment, and shifts between risk-taking and risk-aversion.
The script calculates:
the 120-day SMA of the Copper/Gold ratio
the standard deviation over the same period
the ±1σ, ±1.5σ, and ±2σ deviation bands
automatic labels on the last bar for maximum clarity
The design is minimalistic and visually optimized so users can quickly understand where the current ratio sits relative to long-term norms. The deviation zones help highlight moments when the market transitions into RISK-ON or RISK-OFF behavior.
How to interpret the signals:
Above +2σ → RISK-OFF environment (defensive tone, macro stress)
Below −2σ → RISK-ON environment (increased risk appetite)
±1σ bands represent normal cyclical movements
The SMA acts as the long-term equilibrium level
Estrategia Trend Following: 52w/26w BreakoutThis is a classic long-term Trend Following strategy, heavily inspired by the Donchian Channel system and the legendary "Turtle Trading" rules. It is designed to capture major market moves (bull runs) while filtering out short-term market noise and volatility.
This script is ideal for investors and swing traders who prefer a "hands-off" approach, looking to catch large trends rather than day-trading small fluctuations.
How it Works:
1. Entry Condition (The Breakout):
52-Week High: The strategy enters a Long position when the price breaks above the highest high of the last 252 trading days (approx. 1 year).
SuperTrend Filter: An additional filter using the SuperTrend indicator ensures that the breakout is supported by positive momentum, helping to reduce false signals during choppy lateral markets.
2. Exit Condition (The Trailing Stop):
26-Week Low: The strategy ignores short-term corrections. It only closes the position if the price closes below the lowest low of the last 126 trading days (approx. 6 months).
This wide stop allows the trade to "breathe" and stay open during significant pullbacks, ensuring you stay in the trend for as long as possible.
Features & Settings:
Customizable Lookback Periods: You can adjust the Entry (default 252 days) and Exit (default 126 days) periods in the settings menu.
Visual Aids:
Blue Line: Represents the 1-Year High (Entry Threshold).
Red Line: Represents the 6-Month Low (Dynamic Stop Loss).
Channel Shading: Visualizes the trading range between the high and low.
Labels: Clearly marks "BUY" and "EXIT" points on the chart.
Recommended Usage:
Timeframe: Daily (1D). This logic is designed for daily candles.
Assets: Works best on assets with strong trending characteristics (e.g., Bitcoin/Crypto, Tech Stocks, Indices like SPX/NDX, and Commodities).
Patience Required: This strategy generates very few signals. It may stay quiet for months and then hold a position for over a year.
Linear Regression CVDHere is the complete user manual and introduction for the Linear Regression CVD indicator in English. You can save this as your documentation for your trading system.
📊 Linear Regression CVD – Trader’s Manual
1. Introduction
Core Concept:
Standard Cumulative Volume Delta (CVD) indicators are often noisy and jagged, making it difficult to decipher the true direction of capital flow. This indicator applies a Linear Regression algorithm to smooth out the CVD data and adds a Standard Deviation Channel. It is designed to answer two critical questions:
What is the "True Trend" of the money flow? (Filtering out noise)
Is the market sentiment currently overheated? (Using the channel to spot extremes)
Best Markets:
Crypto Perpetual Futures (e.g., BTCUSDT.P) — Highly Recommended.
Stocks & Forex (Must have volume data).
Timeframes:
Scalping: 1m, 5m, 15m (To catch rapid capital inflows/outflows).
Swing Trading: 1H, 4H (To identify the dominant direction of "Smart Money").
2. Visual Guide
When you load the indicator, you will see the following elements:
A. The Main Line (Linear Regression)
Appearance: A smooth, thick line.
Meaning: The average trend of capital flow.
Color Logic:
🟢 Green: Money flow is trending UP (Buyers are dominant).
🔴 Red: Money flow is trending DOWN (Sellers are dominant).
B. The Raw Line (Gray Hairline)
Appearance: A thin, jagged gray line fluctuating around the main line.
Meaning: The Raw, Real-time CVD. It calculates the volume delta (Close vs. Open) for every single candle without smoothing.
C. The Channel (Blue Background)
Appearance: A blue shaded area around the main line.
Meaning: The "Normal Volatility Range."
Calculated based on 2 Standard Deviations (2σ) from the Linear Regression.
If the Gray Line stays inside this channel, the market is stable/balanced.
D. The Signal Dots
🟢 Green Dot (Upside Extension): The Raw CVD has broken above the upper channel.
Meaning: Extreme Greed / Aggressive Buying / FOMO.
🔴 Red Dot (Downside Extension): The Raw CVD has broken below the lower channel.
Meaning: Extreme Fear / Panic Selling / Capitulation.
3. Trading Strategies
Strategy 1: Trend Confirmation
The basic "Follow the Money" approach.
Bullish Signal (Long):
Price is making Higher Highs.
CVD Main Line turns Green and slopes upward.
Action: Confirms that the price rise is backed by real volume. Hold or Add to Longs.
Bearish Signal (Short):
Price is making Lower Lows.
CVD Main Line turns Red and slopes downward.
Action: Confirms that sellers are in control. Hold Shorts.
Strategy 2: Divergence (High Win Rate)
Finding disagreements between "Price" and "Money Flow".
Bearish Divergence (Top Signal):
Price makes a Higher High.
CVD Main Line makes a Lower High (or fails to break out).
Meaning: Price is rising, but buying effort is fading (Exhaustion) or Limit Sellers are absorbing the buy orders (Absorption).
Action: Look for Short entries.
Bullish Divergence (Bottom Signal):
Price makes a Lower Low.
CVD Main Line makes a Higher Low.
Meaning: Price is dropping, but selling pressure is drying up, or Smart Money is absorbing sell orders via limit buy orders.
Action: Look for Long entries.
Strategy 3: Mean Reversion (Extreme Extensions)
Using the Red/Green dots to fade extremes.
Long Opportunity (Bounce):
Price crashes rapidly.
Cluster of Red Dots appears at the bottom.
Meaning: Panic selling has peaked (Capitulation). The market is oversold on a volume basis.
Action: Wait for a candle reversal pattern, then Long for a bounce.
Short Opportunity (Pullback):
Price pumps vertically.
Cluster of Green Dots appears at the bottom.
Meaning: Retail traders are chasing the pump (FOMO). Buying power is overextended.
Action: Wait for momentum to stall, then Short.
4. Important Limitations & Notes
Data Source Accuracy:
TradingView Standard Volume is an approximation (Close vs. Open logic).
It is not perfect "Tick Data" (like professional Orderflow software), but it is 90% accurate for trend analysis on 1H/4H charts.
Tip: Always use Perpetual Contract charts (e.g., BTCUSDT.P) for Crypto, not Spot charts, to get the correct volume data.
The "Extension" Trap:
Do not Short just because you see a Green Dot. In a strong parabolic bull run, you will see many Green Dots in a row while price keeps flying.
These dots indicate velocity, not necessarily a reversal. Always look for resistance levels or divergence before fading the move.
Settings:
Default Length: 20.
For faster signals: Try 10 or 14.
For smoother trends: Try 50.
5. Pre-Trade Checklist
Before entering a trade, check the Linear CVD:
Color: Is the CVD Line Green or Red? Does it match my trade direction?
Slope: Is the CVD accelerating or flattening out?
Divergence: Did price break a level, but CVD failed to follow? (Fakeout warning).
Extremes: Are there Red/Green dots appearing? If yes, am I chasing a trade too late?
这是一套完整的线性回归 CVD (Linear Regression CVD) 指标的使用说明书和简介。你可以把它保存下来,作为你的交易系统参考文档。
📊 线性回归 CVD (Linear Regression CVD) —— 交易员手册
1. 指标简介 (Introduction)
核心理念:
普通的 CVD(累积成交量差)往往噪音很大,线条锯齿状严重,导致交易者难以看清真正的资金流向趋势。本指标通过线性回归算法 (Linear Regression) 对 CVD 进行平滑处理,并结合标准差通道 (Standard Deviation Channel),试图解决两个核心问题:
资金流向的真实趋势是什么?(排除噪音)
当前的情绪是否过热?(通过通道判定)
适用市场:
加密货币合约 (BTC, ETH 等永续合约) —— 效果最佳
股票、外汇 (需有成交量数据)
适用周期:
日内短线:1分钟、5分钟、15分钟(捕捉快速的资金进出)。
趋势波段:1小时、4小时(判断主力资金的大方向)。
2. 视觉元素说明 (Visual Guide)
当你加载指标后,你会看到以下几个部分:
A. 彩色主线 (The LinReg Line)
形态:一条平滑的粗线。
含义:资金流向的**“平均趋势”**。
颜色:
🟢 绿色:资金流向趋势向上(买盘主导)。
🔴 红色:资金流向趋势向下(卖盘主导)。
B. 灰色背景细线 (Raw CVD)
形态:一条充满锯齿的灰色细线,在主线周围波动。
含义:原始的、实时的累积成交量。它反应了当下的每一根K线的实际买卖差额。
C. 蓝色背景通道 (The Channel)
形态:包裹在主线周围的深蓝色带状区域。
含义:“正常波动范围”。
基于线性回归的 2倍标准差计算。
如果灰色细线在通道内运行,说明市场情绪稳定,多空力量均衡。
D. 信号点 (The Dots)
🟢 绿点 (底部出现):原始 CVD 向上突破了通道上轨。代表极度贪婪 / 抢筹。
🔴 红点 (底部出现):原始 CVD 向下跌破了通道下轨。代表极度恐慌 / 抛售。
3. 实战交易策略 (Trading Strategies)
策略一:趋势确认 (Trend Following)
这是最基础的顺势用法。
做多信号:
价格处于上升趋势(如在均线之上)。
CVD 主线由红变绿,且持续向上倾斜。
操作:这确认了价格的上涨有真金白银的买盘支持,可以持有或加仓。
做空信号:
价格处于下降趋势。
CVD 主线由绿变红,且持续向下倾斜。
操作:确认卖盘主导,价格下跌是健康的。
策略二:背离交易 (Divergence) —— 胜率最高的用法
寻找“主力资金”与“价格”不一致的地方。
顶背离 (看跌):
价格创出了新高 (Higher High)。
CVD 主线却没有创新高,或者形成更低的高点 (Lower High)。
含义:价格在涨,但买入的资金在减少。这通常是主力在通过限价单悄悄出货,或者是买盘枯竭。
操作:准备做空,或多单止盈。
底背离 (看涨):
价格创出了新低 (Lower Low)。
CVD 主线却形成了更高的低点 (Higher Low)。
含义:价格在跌,但卖出的资金在减少,或者有大资金在底部通过挂单吸筹 (Absorption)。
操作:准备做多,或空单止盈。
策略三:极端情绪反转 (Mean Reversion)
利用红绿点判断短期的超买超卖。
做多机会 (反弹):
价格快速下跌,甚至暴跌。
指标底部出现密集的红点 (Downside Extension)。
含义:恐慌盘被杀出来了 (Capitulation),市场短期内无可再卖。
操作:等待K线出现反转形态(如长下影线)后尝试博反弹。
做空机会 (回调):
价格快速拉升(垂直上涨)。
指标底部出现密集的绿点 (Upside Extension)。
含义:大量的散户在追涨 (FOMO),透支了买盘动能。
操作:等待上涨停滞后尝试做空。
4. 关键注意事项 (Limitations)
数据源区别:
TradingView 的普通 Volume 是基于 K 线的近似计算(Close > Open 算买,Close < Open 算卖)。
这与专业的 Orderflow 软件(如 Exocharts)使用的逐笔 Tick 数据有一定误差,但在 1小时/4小时 级别上,趋势方向基本一致。
建议:如果你是做合约,请务必加载 合约图表(如 BTCUSDT.P),不要用现货图表看 CVD。
红绿点的陷阱:
不要一看到绿点就做空! 在超级大单边行情(比如牛市主升浪)中,绿点会连续出现,价格会一直涨。
红绿点必须配合 关键支撑/阻力位 使用。如果在“半空中”出现绿点,往往意味着趋势加速,而不是反转。
参数调整:
默认 LinReg Length = 20。
如果你觉得反应太慢,可以改为 10 或 14。
如果你觉得假信号太多,可以改为 50,但这会牺牲灵敏度。
5. 快速检查清单 (Checklist)
在开单前,看一眼 CVD:
颜色:CVD 是绿的还是红的?和我想做的方向一致吗?
斜率:CVD 是在加速上升/下降,还是开始变平了?
背离:价格破位了,CVD 跟着破位了吗?如果没跟,就是假突破。
极值:有没有出现红点/绿点?如果出现了,是不是应该等回调再进场?
Pharma vs Market Monthly Returns (XLV vs SPY)A Bloomberg-style pharma momentum indicator built for TradingView.
This script recreates the “Pharma Index Monthly Returns” chart highlighted by Jordi Visser in his Youtube video — offering a clean, accessible poor man’s Bloomberg version of sector-rotation analysis for users without institutional data feeds.
Features
• XLV monthly returns (absolute mode)
• XLV vs SPY relative monthly returns (market-neutral mode)
• Top 5 strongest months ★ (momentum spikes)
• Top 5 weakest months ★ (capitulation signals)
• Optional 6-month rolling momentum line (regime trend)
• Full history from 1998 (XLV inception)
Use Cases
Ideal for tracking pharma/healthcare sector regimes, macro rotations, biotech cycles, and timing asymmetric entries in innovation themes (AI-pharma, computational drug discovery, biotech moonshots, etc.).
Мой скриптinputs:
window(1),
type(0), // 0: close, 1: high low, 2: fractals up down, 3: new fractals
persistent(False),
exittype(1),
nbars(160),
adxthres(40),
nstop(3000);
vars:
currentSwingLow(0),
currentSwingHigh(0),
trailStructureValid(false),
downFractal(0),
upFractal(0),
breakStructureHigh(0),
breakStructureLow(0),
BoS_H(0),
BoS_L(0),
Regime(0),
Last_BoS_L(0),
Last_BoS_H(0),
PeakfilterX(false);
BoS(window,persistent,type,Bos_H,BoS_L,upFractal,downFractal,breakStructureHigh,breakStructureLow);
//BOS Regime
If BoS_H <> 0 then begin
Regime = 1; // Bullish
Last_BoS_H = BoS_H ;
end;
If BoS_L <> 0 Then begin
Regime = -1; // Bearish
Last_BoS_L = BoS_L ;
end;
//Entry Logic: if we are in BoS regime then wait for break swing to entry
if ADX(5) of data2 < adxthres then begin
if time>900 and Regime = 1 and EntriesToday(date)= 0 and Last_BoS_H upFractal then buy next bar at market;
end;
if time>900 and EntriesToday(date)= 0 and Regime = -1 and Last_BoS_L>downFractal then
begin
if close < downFractal then sellshort next bar at market;
end;
end;
// Exits: nbars or stoploss or at the end of the day
if marketposition <> 0 and barssinceentry >nbars then begin
sell next bar at market;
buytocover next bar at market;
end;
setstoploss(nstop);
setexitonclose;
RSI Profile [Kodexius]RSI Profile is an advanced technical indicator that turns the classic RSI into a distribution profile instead of a single oscillating line. Rather than only showing where the RSI is at the current bar, it displays where the RSI has spent most of its time or most of its volume over a user defined lookback period.
The script builds a histogram of RSI values between 0 and 100, splits that range into configurable bins, and then projects the result to the right side of the chart. This gives you a clear visual representation of the RSI structure, including the Point of Control (POC), the Value Area High (VAH), and the Value Area Low (VAL). The POC marks the RSI level with the highest activity, while VAH and VAL bracket the percentage based value area around it.
By combining standard RSI, a distribution profile, and value area logic, this tool lets you study RSI behavior statistically instead of only bar by bar. You can immediately see whether the current RSI reading is located inside the dominant zone, extended above it, or depressed below it, and whether the recent regime has been biased toward overbought, oversold, or neutral territory. This is particularly useful for swing traders, mean reversion systems, and anyone who wants to integrate RSI context into a more profile oriented workflow.
🔹 Features
1. RSI-Based Distribution Profile
-Builds a histogram of RSI values between 0 and 100.
-The RSI range is divided into a user-defined number of bins (e.g., 30 bins).
-Each bin represents a band of RSI values, such as 0–3.33, 3.33–6.66, ..., 96.66–100.
-For each bar in the lookback period, the script:
-Finds which bin the RSI value belongs to
Adds either:
-1.0 → if using time/frequency
-volume → if using volume-weighted RSI distribution
This creates a clear profile of where RSI has been concentrated over the chosen lookback window.
2. Time / Volume Weighting Mode
Under Profile Settings, you can choose:
-Weight by Volume = false
→ Profile is built using time spent at each RSI level (frequency).
-Weight by Volume = true
→ Profile is built using volume traded at each RSI level.
This flexibility allows you to decide whether you want:
-A pure momentum structure (time spent at each RSI)
-Or a participation-weighted structure (where higher-volume zones are emphasized)
3. Configurable Lookback & Resolution
-Profile Lookback: number of historical bars to analyze.
-Number of Bins: controls the resolution of the histogram:
Fewer bins → smoother, fewer gaps
More bins → more detail, but potentially more visual sparsity
-Profile Width (Bars): defines how wide the histogram extends into the future (visually), converted into time using average bar duration.
This provides a balance between performance, clarity, and visual density.
4. Value Area, POC, VAH, VAL
The script computes:
-POC (Point of Control)
→ The RSI bin with the highest total value (time or volume).
-Value Area (VA)
→ The range of RSI bins that contain a user-specified percentage of total activity (e.g., 70%).
-VAH & VAL
→ Upper and lower RSI boundaries of this Value Area.
These are then drawn as horizontal lines and labeled:
-POC line and label
-VAH line and label
-VAL line and label
This gives you a profile-style view similar to classical volume profile, but entirely on the RSI axis.
5. Color Coding & Visual Design
The histogram bars (boxes) are colored using a smart scheme:
-Below 30 RSI → Oversold zone, uses the Oversold Color (default: green).
-Above 70 RSI → Overbought zone, uses the Overbought Color (default: red).
-Between 30 and 70 RSI → Neutral zone, uses a gradient between:
A soft blue at lower mid levels
A soft orange at higher mid levels
Additional styling:
-POC bin is highlighted in bright yellow.
-Bins inside the Value Area → lower transparency (more solid).
-Bins outside the Value Area → higher transparency (faded).
This makes it easy to visually distinguish:
-Core RSI activity (VA)
-Extremes (oversold/overbought)
-The single dominant zone (POC)
🔹 Calculations
This section summarizes the core logic behind the script and highlights the main building blocks that power the profile.
1. Profile Structure and Bin Initialization
A custom Profile type groups together configuration, bins and drawing objects. During initialization, the script splits the 0 to 100 RSI range into evenly spaced bins, each represented by a Bin record:
method initBins(Profile p) =>
p.bins := array.new()
float step = 100.0 / p.binCount
for i = 0 to p.binCount - 1
float low = i * step
float high = (i + 1) * step
p.bins.push(Bin.new(low, high, 0.0, box(na)))
2. Filling the Profile Over the Lookback Window
On the last bar, the script clears previous drawings and walks backward through the selected lookback window. For each historical bar, it reads the RSI and volume series and feeds them into the profile:
if barstate.islast
myProfile.reset()
int start = math.max(0, bar_index - lookback)
int end = bar_index
for i = 0 to (end - start)
float r = rsi
float v = volume
if not na(r)
myProfile.add(r, v)
The add method converts each RSI value into a bin index and accumulates either a frequency count or the bar volume, depending on the chosen mode:
method add(Profile p, float rsiValue, float volumeValue) =>
int idx = int(rsiValue / (100.0 / p.binCount))
if idx >= p.binCount
idx := p.binCount - 1
if idx < 0
idx := 0
Bin targetBin = p.bins.get(idx)
float addedValue = p.useVolume ? volumeValue : 1.0
targetBin.value += addedValue
3. Finding POC and Building the Value Area
Inside the draw method, the script first scans all bins to determine the maximum value and the total sum. The bin with the highest value becomes the POC. The value area is then constructed by expanding from that center bin until the desired percentage of total activity is covered:
for in p.bins
totalVal += b.value
if b.value > maxVal
maxVal := b.value
pocIdx := i
float vaTarget = totalVal * (p.vaPercent / 100.0)
float currentVaVol = maxVal
int upIdx = pocIdx
int downIdx = pocIdx
while currentVaVol < vaTarget
float upVol = (upIdx < p.binCount - 1) ? p.bins.get(upIdx + 1).value : 0.0
float downVol = (downIdx > 0) ? p.bins.get(downIdx - 1).value : 0.0
if upVol == 0 and downVol == 0
break
if upVol >= downVol
upIdx += 1
currentVaVol += upVol
else
downIdx -= 1
currentVaVol += downVol
UM VIX30-rolling/VIX Ratio oscillatorSUMMARY
A forward-looking volatility tool that often signals VIX spikes and market reversals before they happen. MA direction flips spotlight the moment volatility pressure shifts.
DESCRIPTION
This indicator compares spot VIX to a synthetic 30-day constant-maturity volatility estimate (“VIX30”) built from VX1 and VX2 futures. The VIX30/VIX Ratio reveals short-term volatility pressure and regime shifts that traditional VX1/VX2 roll-yield alone often misses.
VIX30 is constructed using true calendar-day interpolation between VX1 and VX2, with VX1% and VX2% showing the real-time weights behind the 30-day volatility anchor. The table displays the volatility regime, the VX1/VX2 weights, spot-term roll yield (VIX30/VIX), and futures-term roll yield (VX2/VX1), giving a complete, front-of-the-curve perspective on volatility dynamics.
Use this to spot early vol expansions, collapsing contango, and regime transitions that influence VXX, UVXY, SVIX, VX options, and VIX futures.
⸻
HOW IT WORKS
The script calculates the exact calendar days to expiration for the front two VIX futures. It then applies linear interpolation to blend VX1 and VX2 into a 30-day constant-maturity synthetic volatility measure (“VIX30”). Comparing VIX30 to spot VIX produces the VIX30/VIX Ratio, which highlights short-term volatility pressure and regime direction. A full term-structure table summarizes regime, VX1%/VX2% weights, and both spot-term and futures-term roll yields.
⸻
DEFAULT SETTINGS
VX1! and VX2! are used by default for front-month and second-month futures. These may be manually overridden if TradingView rolls contracts early. The default timeframe is 30 minutes, and the VIX30/VIX Ratio uses a 21-period EMA for regime smoothing. The historical threshold is set to 1.08, reflecting the long-run average relationship between VIX30 and VIX. All settings are user-configurable.
⸻
SUGGESTED USES
• Identify early volatility expansions before they appear in VX1/VX2 roll yield.
• Confirm contango/backwardation shifts with front-of-curve context.
• Time long/short volatility trades in VXX, UVXY, SVIX, and VX options.
• Monitor regime transitions (Low → Cautionary → High) to anticipate trend inflections.
• Combine with price action, NW trends, or MA color-flip systems for higher-confidence entries.
• MA red → green flips may signal opportunities to short volatility or increase equity exposure.
• MA green → red flips may signal opportunities to go long volatility, reduce equity exposure, or even take short-equity positions.
⸻
ALERTS
Alerts trigger when the ratio crosses above or below the historical threshold or when the moving-average slope flips direction. A green flip signals rising volatility pressure; a red flip signals fading or collapsing volatility. These can be used to automate long/short volatility bias shifts or trade-entry notifications.
⸻
FURTHER HINTS
• Increasing orange/red in the table suggests an emerging higher-volatility environment.
• SVIX (inverse volatility ETF) can trend strongly when volatility decays; on a 6h chart, MA green flips often align with attractive short-volatility opportunities.
• For long-volatility trades, consider shrinking to a 30-minute chart and watching for MA green → red flips as early entry cues.
• Experiment with different timeframes and smoothing lengths to match your trading style.
• Higher VIX30/VIX and VX2/VX1 roll yields generally imply faster decay in VXX, UVXY, and UVIX — or stronger upside momentum in SVIX.
CHoCH and BOS - Market StructureIdentifies Break of Structure (BOS) and Change of Character (CHoCH) in real-time. Displays swing and internal market structure with configurable alerts.
Features:
Real-time BOS and CHoCH detection
Swing and internal structure
8 alert conditions
Full customization
Based on Smart Money Concepts (SMC) - Fork of LuxAlgo's original work
For price action and Smart Money Concepts traders.
UM OBV with Signal (EMA/SMA/WMA/NWE)SUMMARY
A visual OBV trend tool that highlights bullish and bearish volume pressure using smart smoothing and intuitive color-coding.
⸻
WHY THIS INDICATOR?
There are only three variables you can adjust on a chart: price, volume, and time. I wanted a good volume indicator.
⸻
DESCRIPTION
This tool extends classic On-Balance Volume with selectable trend smoothing (EMA, SMA, WMA, or NWE) and visual directional coloring on both OBV and the Signal line. Green shows bullish volume flow, red shows bearish volume flow. Optional crossover markers help confirm shifts in buying pressure.
Nadaraya-Watson Regression (NWE) provides a smooth, non-MA alternative for filtering volume trend noise, and optional dual-NWE coloring helps reduce false flips in choppy markets.
⸻
THE CHART
The indicator is added twice at the bottom; once with a 21 EMA and again with a 55 SMA. The chart has text and illustrations to show where the OBV flipped colors. More red equals more selling pressure. More green equals more buying volume or pressure.
⸻
DEFAULTS
• OBV smoothing length = 3
• Signal = 21 EMA
• Crossover bubbles are hidden/off by default
⸻
SUGGESTED USES
• Combine with price structure, momentum, or volatility tools to confirm trend strength.
• Try switching between EMA and NWE on faster intraday charts to see volume trend earlier.
• Use crossover signals as secondary confirmation rather than standalone entries.
• Use this indicator with your other favorite indicators for confirmation.
• Select timeframes suitable to your style of trading.
• I use the 30-minute, 6-hour, and Daily timeframes.
• I question myself if I am buying something with this indicator being red.
• Experiment with various timeframes and settings.
⸻
AUTHOR OBSERVATIONS
OBV often turns before price—especially when volume surges ahead of breakout levels.
NWE tends to smooth choppy OBV much better than traditional moving averages in noisy markets.
Look for Signal color flips at key support/resistance or volatility inflection points.
⸻
ALERTS
Right-click the indicator and choose Add alert… – two presets are available:
• Bullish OBV Turning Up
• Bearish OBV Turning Down
RSI + MACD Day Trading Toolkit//@version=6
indicator("RSI + MACD Day Trading Toolkit", overlay = true)
//──────────────────────────────────────────────────────────────────────────────
// 1. INPUTS
//──────────────────────────────────────────────────────────────────────────────
// RSI settings
rsiLength = input.int(14, "RSI Length")
rsiOverbought = input.float(70, "RSI Overbought Level", minval = 50, maxval = 100)
rsiOversold = input.float(30, "RSI Oversold Level", minval = 0, maxval = 50)
// MACD settings (classic 12 / 26 / 9)
macdFastLength = input.int(12, "MACD Fast Length")
macdSlowLength = input.int(26, "MACD Slow Length")
macdSignalLength = input.int(9, "MACD Signal Length")
// Risk model selection
riskModel = input.string("ATR", "Risk Model", options = )
// ATR-based SL/TP
atrLength = input.int(14, "ATR Length")
atrSLMult = input.float(1.5, "SL ATR Multiplier", minval = 0.1, step = 0.1)
atrTPMult = input.float(2.5, "TP ATR Multiplier", minval = 0.1, step = 0.1)
// Percent-based SL/TP (for scalping on very tight spreads)
slPercent = input.float(0.5, "SL % (when Risk Model = Percent)", minval = 0.05, step = 0.05)
tpPercent = input.float(1.0, "TP % (when Risk Model = Percent)", minval = 0.05, step = 0.05)
// Visual / styling
showSLTPLines = input.bool(true, "Plot Stop Loss / Take Profit Lines")
//──────────────────────────────────────────────────────────────────────────────
// 2. CORE INDICATORS: RSI & MACD
//──────────────────────────────────────────────────────────────────────────────
rsiValue = ta.rsi(close, rsiLength)
// Manual MACD calculation (avoids tuple unpacking issues)
macdFastEMA = ta.ema(close, macdFastLength)
macdSlowEMA = ta.ema(close, macdSlowLength)
macdValue = macdFastEMA - macdSlowEMA
macdSignal = ta.ema(macdValue, macdSignalLength)
macdHist = macdValue - macdSignal
atrValue = ta.atr(atrLength)
// Hide internal plots from price scale (still accessible if you change display)
plot(rsiValue, "RSI", display = display.none)
plot(macdValue, "MACD", display = display.none)
plot(macdSignal, "MACD Sig", display = display.none)
plot(macdHist, "MACD Hist", display = display.none)
//──────────────────────────────────────────────────────────────────────────────
// 3. SIGNAL LOGIC (ENTRY CONDITIONS)
//──────────────────────────────────────────────────────────────────────────────
//
// Idea:
// - LONG bias: RSI emerges from oversold AND MACD crosses above signal below zero
// - SHORT bias: RSI falls from overbought AND MACD crosses below signal above zero
//
// Combines momentum (RSI) with trend confirmation (MACD).
//──────────────────────────────────────────────────────────────────────────────
// RSI events
rsiBullCross = ta.crossover(rsiValue, rsiOversold) // RSI crosses UP out of oversold
rsiBearCross = ta.crossunder(rsiValue, rsiOverbought) // RSI crosses DOWN from overbought
// MACD crossover with trend filter
macdBullCross = ta.crossover(macdValue, macdSignal) and macdValue < 0 // Bullish cross below zero-line
macdBearCross = ta.crossunder(macdValue, macdSignal) and macdValue > 0 // Bearish cross above zero-line
// Raw (ungated) entry signals
rawLongSignal = rsiBullCross and macdBullCross
rawShortSignal = rsiBearCross and macdBearCross
//──────────────────────────────────────────────────────────────────────────────
// 4. STATE MANAGEMENT (SIMULATED POSITION TRACKING)
//──────────────────────────────────────────────────────────────────────────────
//
// position: 1 = long
// -1 = short
// 0 = flat
//
// We track entry price and SL/TP levels as if this were a strategy.
// This is still an indicator – it just computes and plots the logic.
//──────────────────────────────────────────────────────────────────────────────
var int position = 0
var float longEntryPrice = na
var float shortEntryPrice = na
var float longSL = na
var float longTP = na
var float shortSL = na
var float shortTP = na
// Per-bar flags (for plotting / alerts)
var bool longEntrySignal = false
var bool shortEntrySignal = false
var bool longExitSignal = false
var bool shortExitSignal = false
// Reset per-bar flags each bar
longEntrySignal := false
shortEntrySignal := false
longExitSignal := false
shortExitSignal := false
//──────────────────────────────────────────────────────────────────────────────
// 5. EXIT LOGIC (STOP LOSS / TAKE PROFIT / OPPOSITE SIGNAL)
//──────────────────────────────────────────────────────────────────────────────
//
// Exits are evaluated BEFORE new entries on each bar.
//──────────────────────────────────────────────────────────────────────────────
// Stop-loss / take-profit hits for existing positions
longStopHit = position == 1 and not na(longSL) and low <= longSL
longTakeHit = position == 1 and not na(longTP) and high >= longTP
shortStopHit = position == -1 and not na(shortSL) and high >= shortSL
shortTakeHit = position == -1 and not na(shortTP) and low <= shortTP
// Opposite signals can also close positions
reverseToShort = position == 1 and rawShortSignal
reverseToLong = position == -1 and rawLongSignal
// Combine exit conditions
longExitNow = longStopHit or longTakeHit or reverseToShort
shortExitNow = shortStopHit or shortTakeHit or reverseToLong
// Register exits and flatten position
if longExitNow and position == 1
longExitSignal := true
position := 0
longEntryPrice := na
longSL := na
longTP := na
if shortExitNow and position == -1
shortExitSignal := true
position := 0
shortEntryPrice := na
shortSL := na
shortTP := na
//──────────────────────────────────────────────────────────────────────────────
// 6. ENTRY LOGIC WITH RISK MODEL (SL/TP CALCULATION)
//──────────────────────────────────────────────────────────────────────────────
//
// Only take a new trade when flat.
// SL/TP are calculated relative to entry price using either ATR or Percent.
//──────────────────────────────────────────────────────────────────────────────
if position == 0
// Long entry
if rawLongSignal
position := 1
longEntryPrice := close
if riskModel == "ATR"
longSL := longEntryPrice - atrValue * atrSLMult
longTP := longEntryPrice + atrValue * atrTPMult
else // Percent model
longSL := longEntryPrice * (1.0 - slPercent / 100.0)
longTP := longEntryPrice * (1.0 + tpPercent / 100.0)
longEntrySignal := true
// Short entry
else if rawShortSignal
position := -1
shortEntryPrice := close
if riskModel == "ATR"
shortSL := shortEntryPrice + atrValue * atrSLMult
shortTP := shortEntryPrice - atrValue * atrTPMult
else // Percent model
shortSL := shortEntryPrice * (1.0 + slPercent / 100.0)
shortTP := shortEntryPrice * (1.0 - tpPercent / 100.0)
shortEntrySignal := true
//──────────────────────────────────────────────────────────────────────────────
// 7. PLOTTING: ENTRIES, EXITS, STOPS & TARGETS
//──────────────────────────────────────────────────────────────────────────────
// Entry markers
plotshape(longEntrySignal, title = "Long Entry", style = shape.triangleup, location = location.belowbar, color = color.new(color.lime, 0), size = size.small, text = "LONG")
plotshape(shortEntrySignal, title = "Short Entry", style = shape.triangledown, location = location.abovebar, color = color.new(color.red, 0), size = size.small, text = "SHORT")
// Exit markers (generic exits: SL, TP or reversal)
plotshape(longExitSignal, title = "Long Exit", style = shape.xcross, location = location.abovebar, color = color.new(color.orange, 0), size = size.tiny, text = "LX")
plotshape(shortExitSignal, title = "Short Exit", style = shape.xcross, location = location.belowbar, color = color.new(color.orange, 0), size = size.tiny, text = "SX")
// Optional: show SL/TP levels on chart while in position
plot(showSLTPLines and position == 1 ? longSL : na, title = "Long Stop Loss", style = plot.style_linebr, color = color.new(color.red, 0), linewidth = 1)
plot(showSLTPLines and position == 1 ? longTP : na, title = "Long Take Profit", style = plot.style_linebr, color = color.new(color.lime, 0), linewidth = 1)
plot(showSLTPLines and position == -1 ? shortSL : na, title = "Short Stop Loss", style = plot.style_linebr, color = color.new(color.red, 0), linewidth = 1)
plot(showSLTPLines and position == -1 ? shortTP : na, title = "Short Take Profit", style = plot.style_linebr, color = color.new(color.lime, 0), linewidth = 1)
//──────────────────────────────────────────────────────────────────────────────
// 8. ALERT CONDITIONS
//──────────────────────────────────────────────────────────────────────────────
//
// Configure TradingView alerts using these conditions.
//──────────────────────────────────────────────────────────────────────────────
// Entry alerts
alertcondition(longEntrySignal, title = "Long Entry (RSI+MACD)", message = "RSI+MACD: Long entry signal")
alertcondition(shortEntrySignal, title = "Short Entry (RSI+MACD)", message = "RSI+MACD: Short entry signal")
// Exit alerts (by type: SL vs TP vs reversal)
alertcondition(longStopHit, title = "Long Stop Loss Hit", message = "RSI+MACD: Long STOP LOSS hit")
alertcondition(longTakeHit, title = "Long Take Profit Hit", message = "RSI+MACD: Long TAKE PROFIT hit")
alertcondition(shortStopHit, title = "Short Stop Loss Hit", message = "RSI+MACD: Short STOP LOSS hit")
alertcondition(shortTakeHit, title = "Short Take Profit Hit", message = "RSI+MACD: Short TAKE PROFIT hit")
alertcondition(reverseToShort, title = "Long Exit by Reverse Signal", message = "RSI+MACD: Long exit by SHORT reverse signal")
alertcondition(reverseToLong, title = "Short Exit by Reverse Signal", message = "RSI+MACD: Short exit by LONG reverse signal")
//──────────────────────────────────────────────────────────────────────────────
// 9. QUICK USAGE NOTES
//──────────────────────────────────────────────────────────────────────────────
//
// - Indicador, não estratégia: ele simula posição, SL/TP e sinais de saída.
// - Para backtest/auto, basta portar a mesma lógica para um script `strategy()`
// usando `strategy.entry` e `strategy.exit`.
// - Em day trade, teste ATR vs Percent e ajuste os multiplicadores ao ativo.
//──────────────────────────────────────────────────────────────────────────────
Bayesian Liquidity Pain & Gain [Instit. Vol Weighted]Bayesian Liquidity Pain & Gain Indicator
Stop guessing where support and resistance are.
The Bayesian Liquidity Pain & Gain indicator moves beyond arbitrary lines and raw price action. It quantifies Institutional Intent by calculating the exact price levels where large volume has been accumulated and visualizes the "Pain" (stress) those participants feel when the market moves against them.
The Logic: Quantified Institutional Stress
Institutions don't trade single candles; they accumulate positions over time. This indicator tracks their Volume-Weighted Average Cost Basis to answer two critical questions:
Where did they enter? (The Cost Basis Lines)
Are they underwater? (The Pain Clouds)
By normalizing price distance using volatility (ATR) and statistical deviation (Z-Score), we filter out noise and only highlight zones where "Smart Money" is statistically forced to defend their positions or capitulate.
How to Read the Chart
1. The Cost Basis Lines (Anchors)
• 🟢 Green Line (Buyer Cost Basis): The average price where institutions accumulated long positions. This acts as dynamic Support.
• 🔴 Red Line (Seller Cost Basis): The average price where institutions accumulated short positions. This acts as dynamic Resistance.
2. The Pain Clouds (Signals)
When price moves significantly away from the cost basis (Z-Score > 2.0), "Clouds" appear to visualize the PnL status of the participants:
• 🔴 Red Cloud (Buyer Pain): Price is below the buyer's entry. Buyers are losing money (in the red). This creates a "Discount" zone where they may defend support.
• 🟢 Green Cloud (Seller Pain): Price is above the seller's entry. Sellers are losing money (shorts are squeezed). This indicates strong bullish momentum.
3. The Multi-Timeframe Dashboard
A real-time HUD showing the Z-Score status across 4 timeframes (1m, 5m, 15m, 1h):
• 🟢 Green: Profitable/Neutral (Trend Continuation)
• 🟠 Orange: Warning (Pressure Building)
• 🔴 Red: Critical Pain (High Probability Reversal)
Trading Strategies
Setup 1: The Defensive Bounce (Long)
• Context: Price drops into a 🔴 Red Cloud (Buyer Pain).
• Trigger: Price touches the 🟢 Green Line (Buyer Cost Basis) and shows a rejection wick.
• Logic: Institutional buyers defend their cost basis to avoid realizing losses.
Setup 2: The Short Squeeze (Momentum)
• Context: Price rallies into a 🟢 Green Cloud (Seller Pain).
• Trigger: Price holds above the 🔴 Red Line (Seller Cost Basis).
• Logic: Short sellers are trapped and forced to buy back (cover), fueling the rally.
Fractal Alignment:
For high-conviction trades, wait for the Dashboard to show "Pain" signals on both the 1h (Anchor) and 5m (Trigger) timeframes simultaneously.
Settings
• Memory Length (Default 144): The lookback period for the institutional cost basis. Increase for swing trading, decrease for scalping.
• Sigma Threshold (Default 2.0): The statistical confidence level for "Pain". Higher values = fewer, stronger signals.
• Volume Amp: When enabled, high volume amplifies the pain signal, giving more weight to institutional footprints.
Buyer-Seller Locomotive IndexBuyer-Seller Locomotive Index (BSLI)
An original indicator that measures buyer and seller pressure, momentum shifts, and structural control in the market.
Overview
The Buyer-Seller Locomotive Index evaluates candle-level positioning relative to an adaptive EMA-based reference price. It calculates bull vs bear strength percentages and Total Power momentum using fast and slow EMAs, providing insight into which side currently dominates market structure. By combining pressure analysis with momentum smoothing, BSLI highlights both the intensity and direction of market control.
Features
Bull/Bear Strength Percentages: Normalized 0–100 values showing current dominance and threshold-based high-strength alerts.
Total Power Momentum: Fast and slow EMA crossover signals with a histogram to visualize expansion or contraction of pressure.
Visual Markers: Optional fight diamonds highlight candles intersecting the reference price, while dynamic labels show the exact strength percentages.
Crossover Signals: Circles mark potential shifts in momentum, helping to identify early transitions in market control.
Customizable Display: Users can toggle labels, markers, and histogram visibility for a clean or detailed chart view.
How to Use
BSLI provides traders with a multi-layered view of market structure:
Observe shifts in buyer vs seller dominance.
Spot early momentum transitions before trends become obvious.
Confirm price structure with Total Power and strength percentages.
Highlight periods of compression, conflict, or indecision for additional context.
This indicator is intended as a supportive analysis tool. Traders should combine it with personal methodology, risk management, and other analysis techniques. It is not a standalone trade signal.
Important Notes
Measures relative pressure, not absolute volume.
Percentages reflect current structure, not predicted price direction.
Signals are contextual; do not rely solely on crossovers for trading decisions.
Uses no lookahead; all calculations are based on completed bars.
Results may vary by asset, timeframe, and market volatility.
Originality
BSLI uniquely combines adaptive pressure extraction, normalized strength percentages, dual-EMA power momentum, conflict detection, and integrated labeling. This multi-component approach provides a clear and actionable view of the evolving balance between buyers and sellers, supporting both short-term and structural analysis.
EMA/SMA Crossover Signals📊 EMA/SMA Crossover Signals
A professional trading indicator that identifies golden and death crosses between a customizable EMA and SMA with clear BUY/SELL labels displayed directly on your chart.
🎯 Key Features:
✅ Customizable Moving Averages - Adjust both EMA and SMA periods to match your trading strategy
✅ Clear Signal Labels - Large, color-coded "BUY" and "SELL" labels that are impossible to miss
✅ Adjustable Label Positioning - Control the vertical distance of signal labels from price action
✅ Professional Color Customization - Change colors for both moving averages and signals to match your theme
✅ Label Size Options - Choose from 4 different sizes (Tiny, Small, Normal, Large)
✅ Audio Alerts - Get notified instantly when crossovers occur
✅ Overlay Display - Signals appear directly on your price chart for better context
📈 How It Works:
🟢 BUY Signal: Triggered when the EMA crosses above the SMA (bullish crossover)
🔴 SELL Signal: Triggered when the EMA crosses below the SMA (bearish crossover)
⚙️ Customizable Settings:
Moving Averages:
- EMA Period (Default: 8)
- SMA Period (Default: 200)
Colors:
- EMA Color
- SMA Color
- Buy Signal Color
- Sell Signal Color
Signal Settings:
- Signal Vertical Offset
- Label Vertical Offset
- Label Size
💡 Best For:
- Day Trading (1-5 min timeframes)
- Swing Trading (4H-Daily)
- Trend Following Strategies
- Identifying momentum shifts
- Confirming market structure changes
🔔 Perfect for traders using ICT, Wyckoff, and institutional trading methodologies
Use this indicator as part of your complete trading system. Always combine with proper risk management and additional confluence factors.
Yesterday High LineYesterdays High Line Green Dotted Line. Just a line at the high point reached in yesterdays trading cycle
Annual Lump Sum: Yearly & CompoundedAnnual Lump Sum Investment Analyzer (Yearly vs. Compounded)
Overview
This Pine Script indicator simulates a disciplined "Lump Sum" investing strategy. It calculates the performance of buying a fixed dollar amount (e.g., $10,000) on the very first trading day of every year and holding it indefinitely.
Unlike standard backtesters that only show a total percentage, this tool breaks down performance by "Vintage" (the year of purchase), allowing you to see which specific years contributed most to your wealth.
Key Features
Automated Execution: Automatically detects the first trading bar of every new year to simulate a buy.
Dual-Yield Analysis: The table provides two distinct ways to view returns:
Yearly %: How the market performed specifically during that calendar year (Jan 1 to Dec 31).
Compounded %: The total return of that specific year's investment from the moment it was bought until today.
Live Updates: For the current year, the "End Price" and "Yields" update in real-time with market movements.
Portfolio Summary: Displays your Total Invested Capital vs. Total Current Value at the top of the table.
Table Column Breakdown
The dashboard in the bottom-right corner displays the following:
Year: The vintage year of the investment.
Buy Price: The price of the asset on the first trading day of that year.
End Price: The price on the last trading day of that year (or the current price if the year is still active).
Yearly %: The isolated performance of that specific calendar year. (Green = The market ended the year higher than it started).
Compounded %: The "Diamond Hands" return. This shows how much that specific $10,000 tranche is up (or down) right now relative to the current price.
How to Use
Add the script to your chart.
Crucial: Set your chart timeframe to Daily (D). This ensures the script correctly identifies the first trading day of the year.
Open the Settings (Inputs) to adjust:
Annual Investment Amount: Default is $10,000.
Table Size: Adjust text size (Tiny, Small, Normal, Large).
Max Rows: Limit how many historical years are shown to keep the chart clean.
Use Case
This tool is perfect for investors who want to visualize the power of long-term holding. It allows you to see that even if a specific year had a bad "Yearly Yield" (e.g., buying in 2008), the "Compounded Yield" might still be massive today due to time in the market.
Liquidity Sweep Indicator (Signal-based SL + BE/TP)I created a more advanced version of my Liquidity Sweep Indicator. Open source, but I dont recommend to create a TV-strategy from the code because you should combine it with price action an chart analysis! Have fun :)
ART Customizable Overbought Oversold indicatorThis toolkit will help you identify RSI levels on either extremes, you can customize them.






















