Beta Coefficient & RSI Table (Midcaps vs Majors)Beta Coefficient & RSI Table (Midcaps vs Majors)
This script builds a comprehensive beta comparison framework between midcap assets and majors for benchmarks, enhanced with a simple RSI midline strategy for clean entry and exit signaling.
In addition to beta-based relative analysis, the script:
Computes raw RSI values on midcap assets for standalone trend qualification
Evaluates every midcap/major ratio combination using the same RSI-based regime logic
Produces binary (0 / 1) signals suitable for systematic filtering and automation
Designed with automation in mind, this script is perfect for daily alerts that can send webhooks externally, and is fully compatible to reliably daily close updates for:
Ratio beta comparisons (midcaps vs majors)
Binary RSI crossover signals on each ratio
Base midcap trend state (RSI > 45 indicating an active uptrend) - 45 made for a slightly faster entry signal if used as a preliminary filter
This makes the table ideal for automated system building, signal aggregates, and hands-off portfolio logic.
Full credits to @MarktQuant and @NianiaFrania🐸 for the original script source.
Análise de Tendência
Buyers & sellers Candle Control Dominance Zone @MaxMaserati 3.0Description
The Buyers & Sellers Candle Control Dominance Zone is a surgical price-action tool designed to identify and project key supply and demand zones derived from candle anatomy across multiple timeframes.
By splitting candles into "Sellers Control" (upper wick/shadow) and "Buyers Control" (lower wick/shadow) regions, this script visualizes exactly where price rejection and absorption are occurring. With the new HTF Engine, you can now view these institutional rejection zones from a Higher Timeframe (e.g., 4H) while trading on a Lower Timeframe (e.g., 15m).
How it Works
The indicator identifies specific "Control Zones" based on the battle between buyers and sellers:
Live Control (Current & HTF): Real-time monitoring of the developing candle. See a 4H wick forming live while watching the 1m chart.
Last Closed Control (Current & HTF): Projects the zones from the most recently completed candle.
Dominance Zones (BuBC & BeBC):
BuBC (Bullish Body Close): A "Dominance Zone" triggered when a candle closes above the previous candle's high. Signifies strong bullish momentum.
BeBC (Bearish Body Close): A "Dominance Zone" triggered when a candle closes below the previous candle's low. Signifies aggressive selling pressure.
Key Features
Multi-Timeframe (MTF) Overlay: Plot 4H, Daily, or Weekly control zones directly on your lower timeframe scalping charts.
Smart Labeling: HTF labels automatically update to show the zone type (e.g., "Sellers Control (Live) ") and whether the last candle was a Dominance candle (BuBC/BeBC).
Dynamic Extension: Zones are projected forward to help you catch retests of rejection levels.
Alerts Included: Built-in alerts trigger when price crosses into a Dominance Zone (BuBC/BeBC), allowing you to set it and forget it.
Can be use as:
Support & Resistance: Use Buyers Control zones (lower wicks) as demand zones for longs and Sellers Control zones (upper wicks) as supply zones for shorts.
Trend Confirmation: A BuBC zone often acts as a launchpad for continued upside. If price falls back into a BuBC zone and rejects, it is a high-probability continuation signal.
Fractal Entry: Use the HTF zones to find the "Big Picture" levels, then use the Current TF zones to refine your entry with precision.
Settings
Display Filter: Toggle Current TF zones (Live, Closed, BuBC, BeBC) independently.
Higher Timeframe Settings: Enable/Disable HTF overlay and select your preferred timeframe (e.g., 240 for 4H).
Visuals: Fully adjustable transparency, colors, and extension lengths to keep your chart clean.
Relative Strength Leadership Engine v2.0Relative Strength Leadership Engine v2.0OverviewThe Relative Strength Leadership Engine v2.0 is a context-first diagnostic tool designed to identify true market leadership. Instead of simple ratio lines, this script employs a multi-layered scoring model to determine if a symbol is truly outperforming its benchmark (e.g., SPY) or simply riding market beta.The Problem It SolvesMany relative strength indicators fail to distinguish between idiosyncratic leadership and market correlation. A stock might look strong simply because it is a high-beta names moving in lockstep with a rising index. This engine uses Pearson Correlation Filtering and Volatility Normalization to decouple these factors.How It Works (The Math)To ensure full transparency for the TradingView community, the "Leadership Score" (0–100) is calculated based on four proprietary technical pillars:Baseline Alignment (30 pts): Measures if the $Price / Benchmark$ ratio is above its 21-period EMA.Volatility-Normalized Momentum (25 pts): We calculate a Z-score of the RS slope and divide it by the asset's ATR % of price. This ensures momentum is measured by "clean" price action rather than high-beta volatility spikes.Beta-Decoupling (20 pts): Using ta.correlation, the script penalizes "Market Huggers." Points are awarded when a stock shows strength independent of the benchmark's immediate fluctuations.Freshness & Highs (25 pts): Points are awarded for proximity to 252-day relative strength highs, identifying stocks entering a "Power Zone" of leadership.Interpreting the StatesThe dashboard in the bottom-right identifies three distinct permission states:ENGAGE (Score 80+): Full leadership permission. The asset is outperforming with idiosyncratic strength and clean momentum (See FDX example in the gallery).OBSERVE (Score 50–79): Leadership is present but aging or overly correlated to the market (See MU example in the gallery).STAND DOWN (Score <50): Leadership is broken; the asset is a relative laggard (See CBLL example in the gallery).Technical FeaturesMulti-Timeframe Validation: Optional Weekly/Monthly RS confirmation to filter out "noise."Benchmark Timing Filter: A built-in gate that checks if the broader market (Benchmark) is in a "Risk-Off" regime.Non-Repainting: All security calls use lookahead=barmerge.lookahead_off to ensure historical accuracy.Customizable UI: Toggle the dashboard on/off via the "Style" menu for a cleaner workspace.DisclaimerThis script is an informational diagnostic tool and does not generate trade signals, entries, or exits. Educational use only.
JOWY LA VERDADERA ESTRUCTURABasically it is an indicator that perfectly represents the typical BoS Market structure in the fastest way. It is advisable to study several temporalities at the same time and not focus on just one.
VWAP Confluence Pro█ OVERVIEW
VWAP Confluence Pro is a high-precision trading indicator that combines VWAP with multiple confirmation filters to generate reliable buy and sell signals. Unlike basic VWAP crossover strategies that produce excessive noise, this indicator requires alignment across six independent conditions before triggering a signal, dramatically reducing false entries while capturing high-probability setups.
█ FEATURES
Multi-Layer Confirmation System
The indicator employs a strict confluence approach requiring all of the following conditions to align:
- VWAP Cross: Price must cross above (buy) or below (sell) the VWAP line
- VWAP Trend: The VWAP itself must be rising for buys or falling for sells, confirming directional bias
- Price Trend: A 20-period moving average filter ensures trades align with the prevailing trend
- Volume Confirmation: Signals only trigger when volume exceeds 1.5x the 20-bar average, indicating institutional participation
- RSI Filter: Buys require RSI between 50-60 (bullish momentum without overbought conditions), sells require 40-50 (bearish momentum without oversold conditions)
- MACD Momentum: MACD must confirm directional bias with the MACD line above the signal line for buys, below for sells
Signal Cooldown Period
A configurable cooldown mechanism (default 10 bars) prevents signal clustering and overtrading by ensuring adequate spacing between alerts. This feature is critical for maintaining discipline and avoiding choppy market conditions.
Visual Elements
- Purple VWAP Line: The cornerstone of the strategy, plotted with high visibility
- Green Up Arrows: Buy signals appear below price candles when all conditions align
- Red Down Arrows: Sell signals appear above price candles when all conditions align
- Blue Trend MA: A semi-transparent moving average provides visual trend context
- Background Shading: Subtle green/red backgrounds indicate when multiple confluence factors are aligned, even without a cross
█ HOW TO USE
Timeframe Selection
This indicator is optimized for intraday trading on 1-minute to 15-minute charts, where VWAP is most effective. It can also be used on hourly charts for swing trade entries or daily charts with appropriate parameter adjustments.
Parameter Optimization
All key parameters are customizable through the indicator settings:
- VWAP Deviation %: Controls sensitivity (default 0.8%). Lower values = stricter signals
- Volume Multiplier: Defines volume threshold (default 1.5x). Higher values = stronger volume confirmation required
- Trend Filter Length: Moving average period (default 20). Adjust based on your timeframe
- Cooldown Period: Minimum bars between signals (default 10). Increase for slower markets
- RSI/MACD Settings: Standard values provided, adjust for specific instruments if needed
Trading Strategy
1 — Wait for a signal arrow to appear (green for buy, red for sell)
2 — Confirm the background shading supports the signal direction
3 — Enter on the close of the signal candle or the open of the next candle
4 — Set stop loss below/above the recent swing low/high or the VWAP line
5 — Take profit at logical resistance/support levels or when opposing confluence develops
Best Practices
- Only take long trades when price is above a rising VWAP
- Only take short trades when price is below a falling VWAP
- Avoid trading during low volume periods (first/last 15 minutes of sessions)
- Use the background shading to gauge overall market bias between signals
- Consider increasing the cooldown period in choppy or range-bound conditions
█ LIMITATIONS
- This indicator is designed for trending markets and will produce fewer signals during consolidation periods
- The strict confluence requirements mean you may miss some valid moves in exchange for higher signal quality
- VWAP resets at the start of each session, making it less reliable on 24-hour markets without session breaks (use anchored VWAP for crypto/forex)
- Requires real-time volume data to function properly, less effective on thinly traded instruments
- Not suitable for scalping strategies requiring rapid entries, as the cooldown mechanism intentionally limits signal frequency
█ NOTES
Signal Quality Over Quantity
This indicator prioritizes accuracy over frequency. You may only see 1-3 signals per session on lower timeframes, but each signal represents a setup where trend, momentum, and volume are all aligned. This approach is designed to keep you out of low-probability trades and focused on the best opportunities.
Customization Encouraged
The default parameters provide a solid foundation, but different instruments and timeframes may benefit from optimization. Test the indicator across various settings to find what works best for your specific trading style and markets.
═════════════════════════════════════════════════════════════════════════
This indicator synthesizes best practices from institutional VWAP trading with momentum confirmation from RSI and MACD. By requiring multiple independent factors to align, it filters out the noise common in single-indicator systems and focuses on setups where probability favors directional moves.
Rishii's EMA Trend EngineThis indicator is a dual-EMA trend framework designed to improve intraday decision-making by filtering out sideways market noise and highlighting only meaningful trend participation.
It uses a fast and slow EMA to define trend direction, while applying an HLC3-based color logic to show whether price is respecting each EMA. Candles turn green or red only when both the trend alignment and price participation conditions are satisfied. Neutral candles can be shown in white to visually remove noise and make valid candles stand out.
Additional filters such as EMA slope detection and optional higher-timeframe bias help avoid false signals during ranging conditions. A background trend zone and first-candle markers after EMA crossover further improve clarity without cluttering the chart.
How it helps
Clearly shows when the market is trending vs sideways
Highlights only those candles where price is truly participating in the trend
Filters out most whipsaws caused by flat EMAs BITSTAMP:BTCUSD
Combines trend bias, momentum, and participation in one clean view
Caution
This is a trend-following tool, not a reversal indicator.
When EMAs are flat and candles turn white, avoid trading
Do not treat every green/red candle as an entry; wait for proper structure.
Always use proper stop-loss and position sizing.
Volume Weighted LR Z ScoreThis indicator calculates the Volume Weighted Linear Regression
Z-Score (VWLRZS). Unlike a standard Z-Score which measures
deviation from a static mean, this oscillator measures the
statistical distance of price from a dynamic Volume-Weighted
Linear Regression Line (Analysis of Residuals).
Key Features:
1. **Volatility Decomposition:** The indicator separates volatility
based on the 'Estimate Bar Statistics' option.
- **Standard Mode (`Estimate Bar Statistics` = OFF):** Calculates
standard Regression Residuals using the selected `Source`
for both the regression line (baseline) and the signal.
- **Decomposition Mode (`Estimate Bar Statistics` = ON):**
Uses a hybrid statistical approach:
a) **The Model (Baseline):** Uses an estimator to calculate
the 'within-bar' mean and fits the Linear Regression
through these statistical centers. This creates a
stable, trend-following expectation model.
b) **The Signal (Observation):** Compares the actual `Source`
(e.g., Close) against this regression line.
(Result: A Z-Score that measures deviations from the current
trend slope rather than a flat average).
2. **Visual Decomposition Logic:** Total Standard Deviation (of
Residuals) is the primary metric displayed. Since Standard
Deviations are not linearly additive (sqrt(a+b) != sqrt(a)+sqrt(b)),
this indicator calculates the *exact* Total Z-Score and partitions
the area underneath based on the Variance Ratio. This ensures the
displayed total volatility remains mathematically accurate while
showing relative composition.
3. **Normalization (Exponential Regression):** Includes an optional
'Normalize' mode. When enabled, the indicator calculates the
Linear Regression on logarithmic data. Mathematically, this
transforms the baseline into an **Exponential Regression Curve**,
making it ideal for analyzing assets with compounding growth
characteristics (constant percentage trend).
4. **Full Divergence Suite (Class A, B, C):** The indicator's
primary feature is its integrated divergence engine. It
automatically detects and plots all three major divergence
classes between price and the Z-Score:
- Regular (A): Signals potential trend exhaustion and reversals.
- Hidden (B): Signals potential trend continuations during pullbacks.
- Exaggerated (C): Signals weakness at double tops/bottoms.
5. **Divergence Filtering and Visualization:**
- **Price Tolerance Filter:** Divergence detection is enhanced
with a percentage-based price tolerance (`pivPrcTol`) to
filter out insignificant market noise, leading to more
robust signals.
- **Persistent Visualization:** Divergence markers are plotted
for the entire duration of the signal and are visually
anchored to the oscillator level of the confirming pivot.
- **Flexible Pivot Algorithms:** Supports various underlying
mathematical models for pivot detection provided by the
core library
6. **Note on Confirmation (Lag):** Divergence signals rely on a
pivot confirmation method to ensure they do not repaint.
- The **Start** of a divergence is only detected *after* the
confirming pivot is fully formed (a delay based on
`Pivot Right Bars`).
- The **End** of a divergence is detected either instantly
(if the signal is invalidated by price action) or with
a delay (when a new, non-divergent pivot is confirmed).
7. **Multi-Timeframe (MTF) Capability:**
- **MTF Calculation:** The Z-Score line *itself* can be calculated on a
higher timeframe, with standard options to handle gaps
(`Fill Gaps`) and prevent repainting (`Wait for...`).
- **Limitation:** The Divergence detection engine (`pivDiv`)
is designed for the active timeframe. Using it in MTF mode
is not recommended as step-data can lead to inaccurate
pivot detection.
8. **Integrated Alerts:** Includes a comprehensive set of built-in
alerts for the Z-Score crossing the neutral line, the configured
Threshold levels, and the start/end of all divergence types.
---
**DISCLAIMER**
1. **For Informational/Educational Use Only:** This indicator is
provided for informational and educational purposes only. It does
not constitute financial, investment, or trading advice, nor is
it a recommendation to buy or sell any asset.
2. **Use at Your Own Risk:** All trading decisions you make based on
the information or signals generated by this indicator are made
solely at your own risk.
3. **No Guarantee of Performance:** Past performance is not an
indicator of future results. The author makes no guarantee
regarding the accuracy of the signals or future profitability.
4. **No Liability:** The author shall not be held liable for any
financial losses or damages incurred directly or indirectly from
the use of this indicator.
5. **Signals Are Not Recommendations:** The alerts and visual signals
(e.g., crossovers) generated by this tool are not direct
recommendations to buy or sell. They are technical observations
for your own analysis and consideration.
SMA Multi-Sync Granville & MTF CounterSMA Multi-Sync Granville & MTF Counter
Overview
This indicator is an environmental awareness tool that identifies when and to what level moving averages (SMAs) across multiple time frames align in the same direction, visualizing the timing and freshness of the trend.
Its greatest feature is that it does not simply determine synchronization; rather, it precisely distinguishes the time frame upon which synchronization is completed using the number of stars (★).
Key Features
1. Calculation of "Stars" Based on Confirmed Time Frame Trigger
The number of stars displayed upon synchronization completion indicates the signal's "temporal weight."
★ (1): Synchronization is completed upon confirmation of the displayed time frame.
★★ (2): Synchronization is completed upon confirmation of the next higher time frame (e.g., 15 minutes).
★★★ (3): Synchronization is completed upon confirmation of the next higher time frame (e.g., 1 hour). The more higher the time frame is confirmed, the more powerful the trend reversal or regression it acts as.
2. MTF Sync Panel
The table on the right side of the screen displays the price position (background) and MA direction (text) for each level (displayed to daily) in real time.
By watching the background and text colors match, you can understand the accumulation of energy before a star appears.
3. Cross Counter
The number of bars elapsed from the synchronization starting point (MA crossover, etc.) to the current bar is displayed numerically in the lower right corner.
The closer to "0" the number, the more likely it is the beginning of a trend, while the higher the number, the more likely it is the end of the trend (expiration date).
Usability of Input Settings
Min Stars (1-5) This sets the signal cutoff. Setting it to "2" eliminates noise caused by the displayed bar being confirmed and narrows down to only the moment when the higher bar is confirmed (★2 or higher).
Cancel Alert if MA Slope Same If the MA of the displayed time frame is already leaning in the same direction (leading), the confirmation (★1) on that time frame will be considered "not an initial move" and excluded.
5m TF: Use 30m SMA When using 5-minute time frames, this physically changes the ★2 trigger from the confirmation on the 15-minute chart to the confirmation on the 30-minute chart. This is effective when targeting milestones on larger time frames.
*If you have any questions about how to use this, please ask in the comments.
SMA Multi-Sync Granville & MTF Counter
概要
本インジケーターは、複数の時間足の移動平均線(SMA)が「いつ、どの階層まで同じ方向に揃ったか」を特定し、そのトレンドの**「確定タイミング」と「鮮度」**を可視化する環境認識ツールです。
最大の特徴は、単なる同調判定ではなく、**「どの時間足の確定(Close)によって同期が完成したか」**を星(★)の数で厳密に区別する点にあります。
主な機能
1. 確定足トリガーによる「星」の算出
同期が完成した瞬間に表示される星の数は、そのシグナルの「時間的な重み」を示します。
★(1つ):表示足の確定により同期が完成。
★★(2つ):1つ上の上位足(15分等)の確定により同期が完成。
★★★(3つ):2つ上の上位足(1時間等)の確定により同期が完成。 上位の足が確定する節目ほど、より強力なトレンドの転換・回帰として機能します。
2. MTF同期パネル
画面右側のテーブルで、各階層(表示足〜日足)の「価格の位置(背景)」と「MAの向き(文字)」をリアルタイムに表示します。
背景色と文字色が一致していく過程を見ることで、星が出る前の**「エネルギーの蓄積」**を把握できます。
3. クロスカウンター
同期の起点(MAクロス等)から、現在の足まで何本経過したかを右下に数値で表示します。
「0」に近いほど初動であり、数値が大きくなるほどトレンドの終盤(賞味期限切れ)である可能性を論理的に示唆します。
インプット設定の使い勝手
Min Stars (1-5) シグナルの足切り設定です。「2」に設定すれば、表示足の確定によるノイズを排除し、**上位足の確定が伴った瞬間(★2以上)**のみに絞り込めます。
Cancel Alert if MA Slope Same 表示足のMAがすでに同方向へ傾いている(先行している)場合、その足での確定(★1)を「初動ではない」とみなして除外します。
5m TF: Use 30m SMA 5分足運用時、★2のトリガーを「15分足」から「30分足」の確定に物理的に変更します。より大きな時間軸の節目を狙う場合に有効です。
※使い方が不明なところはコメントで聞いてください。
Cyberpunk Hyper-Linear ChannelCyberpunk Hyper-Linear Channel is a next-generation linear regression channel designed to visualize trend direction, volatility, and price positioning with high clarity and minimal noise.
Unlike traditional regression channels, this indicator applies EMA smoothing to both slope and intercept, significantly reducing sudden angle shifts and visual jitter.
The result is a stable, latency-controlled trend channel that adapts smoothly to market structure.
🔹 Core Concept
・Linear regression defines the trend axis
・Standard deviation determines dynamic channel width
・Slope & intercept smoothing improves structural stability
・Neon zones highlight bullish / bearish pressure in real time
🔹 Key Features
・Smoothed Linear Regression Channel (trend-focused, low noise)
・Volatility-based adaptive upper & lower boundaries
・Dynamic neon fill that reacts to price position
・Clear trend bias visualization without repainting clutter
・Cyberpunk-inspired, clean and modern aesthetic
🔹 How to Use
・Price near center line → Mean reversion / equilibrium zone
・Price approaching channel edges → Volatility expansion
・Upper zone dominance → Bullish trend pressure
・Lower zone dominance → Bearish trend pressure
・Breakouts beyond the channel may signal trend acceleration or exhaustion
🔹 Best Use Cases
・Trend-following confirmation
・Dynamic support & resistance mapping
・Market structure visualization across all assets
Cyberpunk Hyper-Linear Channel は、
トレンド方向・ボラティリティ・価格の位置関係を
ノイズを極力排除して可視化する次世代線形回帰チャネルです。
従来の線形回帰チャネルと異なり、
傾き(Slope)と切片(Intercept)の両方にEMAスムージングを適用。
これにより、角度の急変や視覚的ブレを抑えた
安定性の高いトレンド構造を描画します。
🔹 コンセプト
・線形回帰によるトレンド軸の定義
・標準偏差による動的チャネル幅
・スムージングで構造ノイズを低減
・価格位置に応じたネオンゾーンの動的強調表示
🔹 特徴
・低ノイズ・高安定な線形回帰チャネル
・ボラティリティ連動型の上下バンド
・価格位置に反応するダイナミックな発色
・リペイント感のないクリーンな描画
・サイバーパンク調の洗練されたデザイン
🔹 使い方
・中央線付近 → 平衡・持ち合いゾーン
・チャネル上限 / 下限付近 → ボラ拡大・圧力増加
・上部ゾーン優勢 → 上昇トレンド圧力
・下部ゾーン優勢 → 下降トレンド圧力
・チャネル外へのブレイクは加速 or 行き過ぎの兆候として注視
🔹 想定用途
・トレンドフォローの補助
・動的サポート / レジスタンスの把握
・相場構造の視覚的理解
Divergence Detector [KTY] Divergence Detector
Hi, I'm Kim Thank You 👋
KTY = Kim Thank You (김땡큐)
Detects divergences in real-time across 6 indicators: MACD, RSI, Stochastic, CCI, Momentum, MFI.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📊 FEATURES
- Multi-Indicator Detection
- Scans 6 indicators simultaneously
- MACD, RSI, Stochastic, CCI, Momentum, MFI
- Divergence Types
- Bullish Divergence (Green): Price lower low, indicator higher low → ↑
- Bearish Divergence (Red): Price higher high, indicator lower high → ↓
- Visual Display
- Arrow lines connecting pivot points
- Labels showing indicator names with direction (↑/↓)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
✅ HOW TO USE
- Bullish divergence → Check for potential upward move
- Bearish divergence → Check for potential downward move
- Multiple indicators diverging → Higher reliability
- Combine with S/R levels for confirmation
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
💡 TIPS
- Divergence indicates "possibility" not certainty
- Strong trends may ignore divergences
- Higher timeframe divergences are more reliable
- Use with other indicators for confirmation
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⚠️ DISCLAIMER
This indicator is for educational purposes only.
Not financial advice. Always do your own research.
Market Structure BOS - Session Based (5m, NY Time) This indicator visualizes market structure using a strict, rule-based
Break of Structure (BOS) logic, calculated on the 5-minute timeframe
and evaluated in New York time.
The script detects swing Highs and Lows based on candle direction
(bullish → bearish for Highs, bearish → bullish for Lows). From each
validated structure point, a horizontal level is drawn at the true
price extreme (wick included). Once created, structure levels never
repaint or move.
A Break of Structure is confirmed only when a candle CLOSES beyond
the most recent valid structure level:
- Bullish BOS: close above the latest High
- Bearish BOS: close below the latest Low
The indicator is trend-aware: once a bullish or bearish BOS is confirmed,
only BOS signals in the same direction are shown until the trend changes.
This prevents duplicate or redundant structure breaks during trends.
Session logic is fully integrated and based on New York time:
- Asia
- London (with pre-open range)
- New York (with pre-open range)
Structure levels and BOS logic can optionally reset at the end of each
New York trading day, keeping the chart clean and session-relevant.
The indicator is designed for traders who focus on intraday price action,
market structure, and session-based behavior without visual clutter.
No labels, alerts, or signals are plotted — only clean structure levels.
TradeAxis Trendlines - Full RangeOverview
TradeAxis Trendlines is an overlay indicator that automatically builds and maintains diagonal support/resistance trendlines from confirmed swing pivots, ranks candidates to reduce clutter, and provides optional breakout-based risk framing (TP/SL boxes) using structural stops.
This script is built as a single workflow:
Identify structurally valid trendlines
Reduce clutter by ranking/filters
Monitor/visualize breakouts with clear risk framing (disabled in Analysis Mode and on non-standard chart types)
How the trendlines are detected and filtered
1) Confirmed pivot engine (non-instant pivots)
Trendline anchors come from confirmed pivot highs/lows using user-defined Left/Right pivot strength. Because pivots require Right bars to confirm, lines are not drawn at the turning candle and will appear only after confirmation.
2) Candidate generation + structural validation
The script tests pivot-to-pivot vectors and rejects candidates that fail structural criteria, including:
Minimum line length (bars between anchors)
Slope filtering with two modes:
Absolute slope bounds (price-per-bar)
ATR-relative slope bounds (thresholds scaled by ATR)
Body-intersection rejection: candidates are filtered out if candle bodies repeatedly cut through the line beyond a tolerance
Opposite-side invalidation gate: candidates can be rejected/disabled when price closes (or evaluates by Mid-body/Body mode) beyond the “wrong side” of the line, to avoid keeping lines that are already invalidated by structure
3) Touch counting + scoring (clutter control)
Valid candidates are ranked using a weighted score that prioritizes:
Number of valid touches
Recency of the last touch
Line span
By default, the script plots both the primary and secondary (“2nd best”) support and resistance lines; you can disable the secondary set if you prefer a cleaner chart.
4) Dynamic cleanup behavior
Trendlines are continuously refreshed as new pivots confirm. Lines that are decisively broken and then reclaimed can be removed to prevent stale structure from lingering on the chart.
Optional modules
A) Safety lines (structural stop references)
When enabled, the script calculates additional diagonal “safety” lines from a separate pivot stream and selects the best safety reference near the active structure. These safety lines are used as structural candidates for Stop Loss placement in the breakout framing module.
B) Higher-timeframe (HTF) overlays
When enabled, the script runs its trendline detection logic on a user-selected higher timeframe using `request.security()` with lookahead disabled, and overlays the HTF support/resistance onto the current chart. HTF lines are plotted using time-based coordinates and can update as HTF bars confirm.
C) Breakout + Risk/Reward visualization (optional)
When enabled (and on standard charts), the script can flag breakouts and draw a risk/reward box:
Breakout trigger: candle-body confirmation through the trendline plus a user-selected ATR-based buffer.
Buffer Mode can be set to ATR (buffer = ATR × multiplier) or None (no buffer).
Optional filters:
Wick filter (rejects candles with excessive upper/lower wick percentage)
Time windows (inputs are labeled in UTC+4) with optional overnight restrictions and specific block windows
Minimum breakout body size (ticks)
Stop Loss / Take Profit framing
Stop selection is structural-first. The script prioritizes the active safety line (when available), otherwise it falls back to recent swing structure (recent swing high/low candidates) and the best available structural reference.
Entries can be skipped if risk constraints are violated, including:
Min SL Size (ticks)
Max Allowed SL (×ATR)
Take Profit is projected from the actual stop distance using the selected Risk/Reward Target.
Important notes about the position tools
This is a visualization/alerting aid. It does not place trades.
TP/SL hit detection is bar-based (OHLC). If both TP and SL are within the same candle range, the script cannot know which occurred first.
On non-standard chart types, position tools and entry/exit alerts are disabled.
D) Analysis Mode
When Analysis Mode is enabled, the script disables the breakout/risk framing logic and focuses on technical trendlines (plus structural alerts).
Alerts
Alert conditions are available for:
Touch Support/Resistance (Primary, Secondary, or HTF)
New Support/Resistance line detected
Long/Short position tool placed (when enabled on standard charts)
A combined “Any Event” condition
Weekly MAs + 1d 21 SMAThis indicator watches for weekly bullish and bearish alignment on your daily chart. It also triggers a long or short when price touches the 1 Day 21 SMA. It helps ensures a high quality trade setup by trading in a lower timeframe (the 1 Day) while working off stronger signals on the 1 Week timeframe, which are the 3 key moving averages (1W 8 EMA, 1W 21SMA, 1W 50SMA).
The trading rule is as followed:
Short Position:
1. Wait for the 1 week moving averages to align bearish (8 EMA < 21 SMA < 50 SMA). All daily candles will then turn bright red.
2. Wait for a pullback to the 1 Day 21 SMA. Once the wick or body touches this SMA, that candle will turn white. This is the signal that will alert you to be ready to enter into a short position.
3.a. If the candle that changed to white is below the 1 Day 21 SMA, you can enter a short position on the opening of the next daily candle.
3.b. If the candle that changed to white is above the 1Day 21 SMA, wait for the close of the next daily candle. If that candle is below the 21 SMA, enter into your short position at the opening of the next daily candle.
For long positions, you do the same as above but in opposite order.
Cumulative Volume Delta[MIT]Cumulative Volume Delta Depth
This indicator provides a simplified approximation of Cumulative Volume Delta based on candlestick structure, helping to estimate short-term aggressive buying vs. selling pressure.
Core Calculation Logic:
Delta ≈ Volume × (Close - Open) / (High - Low)
- Positive Delta when the candle has a strong bullish body (more aggressive buying)
- Negative Delta when the candle has a strong bearish body (more aggressive selling)
- Near zero when the body is very small (indecision / balanced pressure)
Key Features:
- Column chart shows cumulative Delta (resets on new day by default)
- Orange line = smoothed Delta (default 5-period SMA)
- Teal tint for positive values, maroon tint for negative values
- Zero line for easy visual reference of net buying/selling shifts
Use Cases:
- Identify short-term buying/selling dominance
- Spot divergences (e.g. price makes new high but Delta fails to confirm → potential exhaustion)
- Works best on high-volume instruments (futures, crypto, liquid stocks)
Limitations:
- This is an approximation based on OHLC structure, NOT real tick-by-tick order flow
- Long shadows, small bodies, gaps, or low-volume bars may distort the result
- Best used in combination with other volume/price tools (VWAP, OBV, volume spikes, etc.)
Parameters:
- Cumulative Period: Controls lookback/reset logic (default 200 bars)
- Smoothing Period: Length of Delta moving average (default 5)
- Show MA: Toggle orange smoothed line on/off
这是一个基于K线形态粗估的累计成交量Delta指标,用于近似判断短期内主动买方与主动卖方的力量对比。
核心计算逻辑:
Delta ≈ Volume × (Close - Open) / (High - Low)
- 当阳线实体较长时,Delta为正值(偏向买方主动)
- 当阴线实体较长时,Delta为负值(偏向卖方主动)
- 小实体或十字星时Delta接近0
指标特点:
- 柱状图显示累计Delta(可每日重置)
- 橙色线为Delta的平滑均线(默认5周期,可调)
- 正值区域用青色系着色,负值区域用酒红色系着色
- 零轴辅助线,便于观察多空转折
适用场景:
- 辅助判断日内/短线多空力量变化
- 结合价格走势观察是否有背离(价格创新高但Delta不创新高,可能见顶)
- 适合期货、加密货币、活跃股票等成交量较大的品种
局限性:
- 这只是基于K线结构的近似估算,并非真实逐笔方向分类
- 对长影线、小实体K线或跳空行情可能失真
- 建议结合其他量价指标(如VWAP、OBV、成交量放大)一起使用
参数说明:
- 累计周期:控制Delta是否每日/每周重置(默认200根,建议设大值保持连续性)
- 平滑周期:Delta平滑均线的长度(默认5)
- 显示均线:是否显示橙色平滑线
Contango/Backwardation Futures Box Desk - TT ToolsContango / Backwardation Futures Box – TT Tools
This indicator provides a clear, compact, and intuitive view of the Contango / Backwardation structure of a futures curve, displayed directly on the chart through an advanced informational box.
It is designed for discretionary traders, spread traders, and curve analysis, with an optimized visualization for both desktop and mobile use.
The box displays the real-time Contango or Backwardation structure of the futures curve, including:
curve status (Contango / Backwardation / Flat)
percentage spread between the front contracts
prices of the three expiries (Near, Mid, Far) with directional indicators
confirmation or non-confirmation of the curve structure
contract expiration date with remaining days countdown
rollover warning when expiration is approaching
The box is fully optimized for Desktop, Compact, and Mobile layouts, ensuring a clean, adaptive design and always-readable information.
Quick Start Guide
Select the futures contracts
Insert the nearest futures contracts into Front (1), Next (2) and Third (3), starting from the front-month contract.
You can easily find the correct contract using “Change Symbol”, filtering by Futures and selecting the appropriate expiry.
Check the contract expiry
Identify the rollover date directly on the chart using Events → Contract Switch.
This helps you confirm that you are analyzing the correct futures expiration.
Set the NEXT EXPIRY date
Enter the next futures expiration date in the NEXT EXPIRY (exact date) field.
Simply match it with the contract switch shown on the chart to stay perfectly aligned.
Monitor the curve
The box displays in real time:
curve structure (Contango / Backwardation / Flat)
percentage spread between expiries
prices of the three contracts with directional indicators
structure confirmation status
days-to-expiry countdown
visual rollover warning when expiration approaches
👉 Always keep contracts and expiry dates updated to ensure an accurate reading of the futures curve and to anticipate rollover phases correctly.
__________________________________________________________
Backwardation Futures Box – TT Tools
Questo indicatore mostra in modo chiaro, compatto e immediato la struttura Contango / Backwardation di una curva futures, direttamente sul grafico tramite un box informativo avanzato. È pensato per trader discrezionali, spread traders e analisi di curva, con una visualizzazione ottimizzata sia per desktop che per mobile.
Il riquadro box mostra in tempo reale la struttura di Contango o Backwardation della curva futures, includendo:
• stato della curva (Contango / Backwardation / Flat)
• spread percentuale tra le prime scadenze
• prezzi delle tre scadenze (Near, Mid, Far) con indicatori direzionali
• conferma o meno della struttura della curva
• data di scadenza del contratto e countdown ai giorni residui
• avviso di rollover imminente
Il box è ottimizzato per Desktop, Compact e Mobile, con layout adattivo e informazioni sempre leggibili.
Mini guida operativa
Selezione dei contratti
Inserisci nel box Front (1), Next (2) e Third (3) i future più prossimi a scadenza, partendo dal contratto front-month.
Puoi cercare rapidamente il contratto corretto tramite “Cambia simbolo”, filtrando per Futures e selezionando la scadenza desiderata.
Controllo della scadenza
Individua la data di rollover direttamente sul grafico tramite la sezione Eventi → Switch di contratto.
Utilizza questa informazione per verificare di stare analizzando la scadenza corretta.
Impostazione della NEXT EXPIRY
Inserisci nel campo NEXT EXPIRY (data precisa) la data di scadenza del prossimo future.
È sufficiente confrontarla con lo switch di contratto visibile sul grafico per essere allineati correttamente.
Monitoraggio della curva
Il box mostra in tempo reale:
struttura della curva (Contango / Backwardation / Flat)
spread percentuale tra le scadenze
prezzi dei tre contratti con direzione relativa
conferma o meno della struttura
countdown ai giorni residui
alert visivo di rollover imminente
👉 Mantieni sempre aggiornati contratti e data di scadenza per avere una lettura affidabile della curva futures e anticipare correttamente le fasi di rollover.
Peaks and Troughs📄 Script Description – EN (English)
Peaks and Troughs (P&T) is a price action indicator that identifies confirmed swing highs (peaks) and swing lows (troughs) based on structural trend changes.
Key features:
Trend-break based peak and trough confirmation
Optional engulfing signal at confirmed swing points
Body-break based Mother Bar (Outside Bar) range marking
Clean chart output with only the latest active levels
Unified alert system using Any alert() function call
Designed for discretionary trading, market structure analysis and automation-ready alerting.
----------------------------------------------------
📄 Script Description – HU (Magyar)
A Peaks and Troughs (P&T) egy price action alapú indikátor, amely megerősített csúcs- (peak) és völgypontokat (trough) azonosít trendváltás alapján.
Főbb jellemzők:
Trendtörés alapú peak és trough meghatározás
Opcionális engulfing jelzés megerősített swing pontokon
Body-break alapú Mother Bar (Outside Bar) tartomány jelölés
Letisztult chart, mindig csak az aktuális szintekkel
Egységes riasztási rendszer (Any alert() function call)
Diszkrecionális kereskedéshez, market structure elemzéshez és automatizált riasztásokhoz optimalizálva.
CTR Weekly MA + 1D MA (improved)This does what the previous version does but more. I've added color candles to match the three weekly MAs. It helps show the stronger pullback as it goes deeper into each of the 3 weekly MAs and once the pullback is over and price goes back above or below the lowest or highest MA (depending on whether you are trading in a bear market or bull market) the candle colors will turn bright green or bright red.
CTR Weekly MA + 1D MA (v1)I built this simple pine script to help me trade on the lower timeframe (1d) while still showing my key weekly moving averages to help me trade with the macro trend.
Rules for trading...
Steps for taking a Short position:
1. Wait for all 3 weekly moving averages to be in alignment (8EMA<21SMA<50SMA). When these aligned the candles will change to bright red, meaning bearish.
2. Wait for a pullback to the 1 Day 21SMA. When a candle touches the 21SMA, that candle will change color to white. This will be your alert to get ready to enter into a short.
3. On the next candle you can then take a short position as long as that candle is below the 21SMA, if not, wait for the net daily candle to close. If that is below the 21SMA you can then enter into a short on the opening of the next daily candle.
I built this to trade the Bear Market but this same method can also work in a Bull Market but just do the opposite.
CTR Weekly MA TradingI built this simple pine script to help me trade on the lower timeframe (1d) while still showing my key weekly moving averages to help me trade with the macro trend.
Rules for trading...
Steps for taking a Short position:
1. Wait for all 3 weekly moving averages to be in alignment (8EMA<21SMA<50SMA). When these aligned the candles will change to bright red, meaning bearish.
2. Wait for a pullback to the 1 Day 21SMA. When a candle touches the 21SMA, that candle will change color to white. This will be your alert to get ready to enter into a short.
3. On the next candle you can then take a short position as long as that candle is below the 21SMA, if not, wait for the net daily candle to close. If that is below the 21SMA you can then enter into a short on the opening of the next daily candle.
I built this to trade the Bear Market but this same method can also work in a Bull Market but just do the opposite.






















