Reversal Point Dynamics⇋ Reversal Point Dynamics (RPD)
This is not an indicator; it is a complete system for deconstructing the mechanics of a market reversal. Reversal Point Dynamics (RPD) moves far beyond simplistic pattern recognition, venturing into a deep analysis of the underlying forces that cause trends to exhaust, pause, and turn. It is engineered from the ground up to identify high-probability reversal points by quantifying the confluence of market dynamics in real-time.
Where other tools provide a static signal, RPD delivers a dynamic probability. It understands that a true market turning point is not a single event, but a cascade of failing momentum, structural breakdown, and a shift in market order. RPD's core engine meticulously analyzes each of these dynamic components—the market's underlying state, its velocity and acceleration, its degree of chaos (entropy), and its structural framework. These forces are synthesized into a single, unified Probability Score, offering you an unprecedented, transparent view into the conviction behind every potential reversal.
This is not a "black box" system. It is an open-architecture engine designed to empower the discerning trader. Featuring real-time signal projection, an integrated Fibonacci R2R Target Engine, and a comprehensive dashboard that acts as your Dynamics Control Center , RPD gives you a complete, holistic view of the market's state.
The Theoretical Core: Deconstructing Market Dynamics
RPD's analytical power is born from the intelligent synthesis of multiple, distinct theoretical models. Each pillar of the engine analyzes a different facet of market behavior. The convergence of these analyses—the "Singularity" event referenced in the dashboard—is what generates the final, high-conviction probability score.
1. Pillar One: Quantum State Analysis (QSA)
This is the foundational analysis of the market's current state within its recent context. Instead of treating price as a random walk, QSA quantizes it into a finite number of discrete "states."
Formulaic Concept: The engine establishes a price range using the highest high and lowest low over the Adaptive Analysis Period. This range is then divided into a user-defined number of Analysis Levels. The current price is mapped to one of these states (e.g., in a 9-level system, State 0 is the absolute low, and State 8 is the absolute high).
Analytical Edge: This acts as a powerful foundational filter. The engine will only begin searching for reversal signals when the market has reached a statistically stretched, extreme state (e.g., State 0 or 8). The Edge Sensitivity input allows you to control exactly how close to this extreme edge the price must be, ensuring you are trading from points of maximum potential exhaustion.
2. Pillar Two: Price State Roc (PSR) - The Dynamics of Momentum
This pillar analyzes the kinetic forces of the market: its velocity and acceleration. It understands that it’s not just where the price is, but how it got there that matters.
Formulaic Concept: The psr function calculates two derivatives of price.
Velocity: (price - price ). This measures the speed and direction of the current move.
Acceleration: (velocity - velocity ). This measures the rate of change in that speed. A negative acceleration (deceleration) during a strong rally is a critical pre-reversal warning, indicating momentum is fading even as price may be pushing higher.
Analytical Edge: The engine specifically hunts for exhaustion patterns where momentum is clearly decelerating as price reaches an extreme state. This is the mechanical signature of a weakening trend.
3. Pillar Three: Market Entropy Analysis - The Dynamics of Order & Chaos
This is RPD's chaos filter, a concept borrowed from information theory. Entropy measures the degree of randomness or disorder in the market's price action.
Formulaic Concept: The calculateEntropy function analyzes recent price changes. A market moving directionally and smoothly has low entropy (high order). A market chopping back and forth without direction has high entropy (high chaos). The value is normalized between 0 and 1.
Analytical Edge: The most reliable trades occur in low-entropy, ordered environments. RPD uses the Entropy Threshold to disqualify signals that attempt to form in chaotic, unpredictable conditions, providing a powerful shield against whipsaw markets.
4. Pillar Four: The Synthesis Engine & Probability Calculation
This is where all the dynamic forces converge. The final probability score is a weighted calculation that heavily rewards confluence.
Formulaic Concept: The calculateProbability function intelligently assembles the final score:
A Base Score is established from trend strength and entropy.
An Entropy Score adds points for low entropy (order) and subtracts for high entropy (chaos).
A significant Divergence Bonus is awarded for a classic momentum divergence.
RSI & Volume Bonuses are added if momentum oscillators are in extreme territory or a volume spike confirms institutional interest.
MTF & Adaptive Bonuses add further weight for alignment with higher timeframe structure.
Analytical Edge: A signal backed by multiple dynamic forces (e.g., extreme state + decelerating momentum + low entropy + volume spike) will receive an exponentially higher probability score. This is the very essence of analyzing reversal point dynamics.
The Command Center: Mastering the Inputs
Every input is a precise lever of control, allowing you to fine-tune the RPD engine to your exact trading style, market, and timeframe.
🧠 Core Algorithm
Predictive Mode (Early Detection):
What It Is: Enables the engine to search for potential reversals on the current, unclosed bar.
How It Works: Analyzes intra-bar acceleration and state to identify developing exhaustion. These signals are marked with a ' ? ' and are tentative.
How To Use It: Enable for scalping or very aggressive day trading to get the earliest possible indication. Disable for swing trading or a more conservative approach that waits for full bar confirmation.
Live Signal Mode (Current Bar):
What It Is: A highly aggressive mode that plots tentative signals with a ' ! ' on the live bar based on projected price and momentum. These signals repaint intra-bar.
How It Works: Uses a linear regression projection of the close to anticipate a reversal.
How To Use It: For advanced users who use intra-bar dynamics for execution and understand the nature of repainting signals.
Adaptive Analysis Period:
What It Is: The main lookback period for the QSA, PSR, and Entropy calculations. This is the engine's "memory."
How It Works: A shorter period makes the engine highly sensitive to local price swings. A longer period makes it focus only on major, significant market structure.
How To Use It: Scalping (1-5m): 15-25. Day Trading (15m-1H): 25-40. Swing Trading (4H+): 40-60.
Fractal Strength (Bars):
What It Is: Defines the strength of the pivot detection used for confirming reversal events.
How It Works: A value of '2' requires a candle's high/low to be more extreme than the two bars to its left and right.
How To Use It: '2' is a robust standard. Increase to '3' for an even stricter definition of a structural pivot, which will result in fewer signals.
MTF Multiplier:
What It Is: Integrates pivot data from a higher timeframe for confluence.
How It Works: A multiplier of '4' on a 15-minute chart will pull pivot data from the 1-hour chart (15 * 4 = 60m).
How To Use It: Set to a multiple that corresponds to your preferred higher timeframe for contextual analysis.
🎯 Signal Settings
Min Probability %:
What It Is: Your master quality filter. A signal is only plotted if its score exceeds this threshold.
How It Works: Directly filters the output of the final probability calculation.
How To Use It: High-Quality (80-95): For A+ setups only. Balanced (65-75): For day trading. Aggressive (50-60): For scalping.
Min Signal Distance (Bars):
What It Is: A noise filter that prevents signals from clustering in choppy conditions.
How It Works: Enforces a "cooldown" period of N bars after a signal.
How To Use It: Increase in ranging markets to focus on major swings. Decrease on lower timeframes.
Entropy Threshold:
What It Is: Your "chaos shield." Sets the maximum allowable market randomness for a signal.
How It Works: If calculated entropy is above this value, the signal is invalidated.
How To Use It: Lower values (0.1-0.5): Extremely strict. Higher values (0.7-1.0): More lenient. 0.85 is a good balance.
Adaptive Entropy & Aggressive Mode:
What It Is: Toggles for dynamically adjusting the engine's core parameters.
How It Works: Adaptive Entropy can slightly lower the required probability in strong trends. Aggressive Mode uses more lenient settings across the board.
How To Use It: Keep Adaptive on. Use Aggressive Mode sparingly, primarily for scalping highly volatile assets.
📊 State Analysis
Analysis Levels:
What It Is: The number of discrete "states" for the QSA.
How It Works: More levels create a finer-grained analysis of price location.
How To Use It: 6-7 levels are ideal. Increasing to 9 can provide more precision on very volatile assets.
Edge Sensitivity:
What It Is: Defines how close to the absolute top/bottom of the range price must be.
How It Works: '0' means price must be in the absolute highest/lowest state. '3' allows a signal within the top/bottom 3 states.
How To Use It: '3' provides a good balance. Lower it to '1' or '0' if you only want to trade extreme exhaustion.
The Dashboard: Your Dynamics Control Center
The dashboard provides a transparent, real-time view into the engine's brain. Use it to understand the context behind every signal and to gauge the current market environment at a glance.
🎯 UNIFIED PROB SCORE
TOTAL SCORE: The highest probability score (either Peak or Valley) the engine is currently calculating. This is your main at-a-glance conviction metric. The "Singularity" header refers to the event where market dynamics align—the event RPD is built to detect.
Quality: A human-readable interpretation of the Total Score. "EXCEPTIONAL" (🌟) is a rare, A+ confluence event. "STRONG" (💪) is a high-quality, tradable setup.
📊 ORDER FLOW & COMPONENT ANALYSIS
Volume Spike: Shows if the current volume is significantly higher than average (YES/NO). A 'YES' adds major confirmation.
Peak/Valley Conf: This breaks down the probability score into its directional components, showing you the separate confidence levels for a potential top (Peak) versus a bottom (Valley).
🌌 MARKET STRUCTURE
HTF Trend: Shows the direction of the underlying trend based on a Supertrend calculation.
Entropy: The current market chaos reading. "🔥 LOW" is an ideal, ordered state for trading. "😴 HIGH" is a warning of choppy, unpredictable conditions.
🔮 FIB & R2R ZONE (Large Dashboard)
This section gives you the status of the Fibonacci Target Engine. It shows if an Active Channel (entry zone) or Stop Zone (invalidation zone) is active and displays the precise price levels for the static entry, target, and stop calculated at the time of the signal.
🛡️ FILTERS & PREDICTIVES (Large Dashboard)
This panel provides a status check on all the bonus filters. It shows the current RSI Status, whether a Divergence is present, and if a Live Pending signal is forming.
The Visual Interface: A Symphony of Data
Every visual element is designed for instant, intuitive interpretation of market dynamics.
Signal Markers: These are the primary outputs of the engine.
▼/▲ b: A fully confirmed signal that has passed all filters.
? b: A tentative signal generated in Predictive Mode, indicating developing dynamics.
◈ b: This diamond icon replaces the standard triangle when the signal is confirmed by a strong momentum divergence, highlighting it as a superior setup where dynamics are misaligned with price.
Harmonic Wave: The flowing, colored wave around the price.
What It Represents: The market's "flow dynamic" and volatility.
How to Interpret It: Expanding waves show increasing volatility. The color is tied to the "Quantum Color" in your theme, representing the underlying energy field of the market.
Entropy Particles: The small dots appearing above/below price.
What They Represent: A direct visualization of the "order dynamic."
How to Interpret Them: Their presence signifies a low-entropy, ordered state ideal for trading. Their color indicates the direction of momentum (PSR velocity). Their absence means the market is too chaotic (high entropy).
The Fibonacci Target Engine: The dynamic R2R system appearing post-signal.
Static Fib Levels: Colored horizontal lines representing the market's "structural dynamic."
The Green "Active Channel" Box: Your zone of consideration. An area to manage a potential entry.
Development Philosophy
Reversal Point Dynamics was engineered to answer a fundamental question: can we objectively measure the forces behind a market turn? It is a synthesis of concepts from market microstructure, statistics, and information theory. The objective was never to create a "perfect" system, but to build a robust decision-support tool that provides a measurable, statistical edge by focusing on the principle of confluence.
By demanding that multiple, independent market dynamics align simultaneously, RPD filters out the vast majority of market noise. It is designed for the trader who thinks in terms of probability and risk management, not in terms of certainties. It is a tool to help you discount the obvious and bet on the unexpected alignment of market forces.
"Markets are constantly in a state of uncertainty and flux and money is made by discounting the obvious and betting on the unexpected."
— George Soros
Trade with insight. Trade with anticipation.
— Dskyz, for DAFE Trading Systems
Indicatori e strategie
cd_sweep&cisd_CxOverview:
When the price is at a significant zone/level on a higher time frame (HTF), and it sweeps (breaks through and then closes back below/above) the high or low of the previous HTF candle, it is common to look for a Change in State of Delivery (CISD) on a lower time frame (LTF) to enter a trade.
This model can be summarized as:
HTF Sweep → LTF CISD (Optional: SMT / Divergences)
________________________________________
Working Principle & Details:
1. The indicator monitors price action on the selected HTF and tracks any sweep (violation) of the previous HTF candle's high or low. Simultaneously, it identifies CISD levels on the LTF. If SMT is enabled, it will appear as a label on the chart.
When both HTF sweep and LTF CISD conditions are met, the indicator marks the chart at the open of the next candle and triggers an alert if set.
CISD levels are tracked and updated whenever a new HTF high/low is formed.
2. The indicator monitors the formation of entry models on up to six selected pairs, displaying results in two separate tables:
o HTF Sweep Query Table: Monitors live HTF candles and reports pairs that meet the sweep condition.
o CISD Table: Displays the pairs where a valid entry model has formed. A "🔥" symbol indicates the condition has occurred.
3. Bias Visualization:
Based on the selected HTF, a visual band is shown at the bottom of the chart using the chosen bullish/bearish colors.
Bias is determined by:
o Candle closing above/below the previous one suggesting continuation.
o A failed close after a sweep implying potential reversal.
4. HTF Candles:
Displays HTF candles based on the user-defined time frame.
5. Optional SMT (Smart Money Technique):
Must be enabled in the menu and requires the correlated pair to be entered correctly for accurate results.
Displayed only as a visual confirmation, not a requirement for model formation.
If the currently open symbol sweeps the previous candle while the correlated symbol does not (or vice versa), an "SMT" label appears on the chart.
6. Color & Table Positioning:
Controlled via the settings menu.
________________________________________
Warnings:
• The indicator only marks CISDs that form at HTF high/low zones.
• Entering every time the model forms does not guarantee profitability.
• Waiting for the model to appear at significant HTF levels/zones increases the likelihood of success.
• HTF and LTF selections should follow commonly accepted combinations or user-tested time frames.
• If you want to trigger alerts only for symbols entered in the indicator, ensure the "Use indicator alerts" option is enabled.
• To set alerts for the TradingView watchlist instead, disable the "Use indicator alerts" option.
________________________________________
Feel free to share your thoughts and suggestions.
Happy trading! 💫
Trend Range Detector (Zeiierman)█ Overview
Trend Range Detector (Zeiierman) is a market structure tool that identifies and tracks periods of price compression by forming adaptive range boxes based on volatility and price movement. When prices remain stable within a defined band, the script dynamically draws a range box; when prices break out of that structure, the box highlights the breakout in real-time.
By combining a volatility-based envelope with a custom weighted centerline, this tool filters out noise and isolates truly stable zones — providing a clean framework for traders who focus on accumulation, distribution, breakout anticipation, and reversion opportunities.
Whether you're range trading, spotting trend consolidations, or looking for volatility contractions before major moves, the Trend Range Detector gives you a mathematically adaptive, visually intuitive structure that maps the heartbeat of the market.
█ How It Works
⚪ Range Formation Engine
The core of this indicator revolves around two conditions:
Distance Filter: The maximum distance between all recent closes and a dynamic centerline must remain within a volatility envelope.
Volatility Envelope: Based on an ATR(2000) multiplied by a user-defined factor to account for broader market volatility trends.
If both conditions are satisfied over the most recent length bars, a range box is drawn to visually anchor the zone.
⚪ Dynamic Breakout Coloring
When price breaks out of the top or bottom of the active range box, the box color shifts in real-time:
Blue Boxes represent areas where price has remained within a defined volatility envelope over a sustained number of bars. These zones reflect stable, low-volatility periods, often associated with consolidation, equilibrium, or market indecision.
Green Boxes for bullish breakouts.
Red Boxes for bearish breakdowns.
This allows traders to visually spot transitions from consolidation to expansion phases without relying on lagging signals.
█ Why Use a Weighted Close Instead of SMA?
A standard Simple Moving Average (SMA) treats all past closes equally, which works well in theory, but not in dynamic, fast-shifting markets. In this script, we replace the traditional SMA with a speed-weighted average that reflects how aggressively the market has moved bar-to-bar.
⚪ Here's why it matters:
Bars with higher momentum (larger price differences between closes) are given more weight.
Slow, sideways candles (typical in noise or low volume) contribute less to the calculated centerline.
This method creates a more accurate snapshot of market behavior, especially during volatile phases. As a result, the indicator adapts to market conditions more effectively, helping traders identify real consolidation zones, not just average lines distorted by flat bars or noise.
█ How to Use
⚪ Range Detection
Boxes form only when price remains consistently close to the speed-weighted mean.
Helps identify sideways zones, consolidations, and low-volatility structures where price is “charging up.”
⚪ Breakout Confirmation
Once price exits the top or bottom boundary, the box immediately highlights the direction of the break.
Use this signal in conjunction with your own momentum, volume, or trend filters for higher-confidence trades.
█ Settings
Minimum Range Length: Number of candles required for a valid range to form.
Range Width Multiplier: Adjusts the envelope around the weighted average using ATR(2000).
Highlight Box Breaks: Enables real-time coloring of breakouts and breakdowns for immediate visual feedback.
-----------------
Disclaimer
The content provided in my scripts, indicators, ideas, algorithms, and systems is for educational and informational purposes only. It does not constitute financial advice, investment recommendations, or a solicitation to buy or sell any financial instruments. I will not accept liability for any loss or damage, including without limitation any loss of profit, which may arise directly or indirectly from the use of or reliance on such information.
All investments involve risk, and the past performance of a security, industry, sector, market, financial product, trading strategy, backtest, or individual's trading does not guarantee future results or returns. Investors are fully responsible for any investment decisions they make. Such decisions should be based solely on an evaluation of their financial circumstances, investment objectives, risk tolerance, and liquidity needs.
Smart MTF S/R Levels[BullByte]
Smart MTF S/R Levels
Introduction & Motivation
Support and Resistance (S/R) levels are the backbone of technical analysis. However, most traders face two major challenges:
Manual S/R Marking: Drawing S/R levels by hand is time-consuming, subjective, and often inconsistent.
Multi-Timeframe Blind Spots: Key S/R levels from higher or lower timeframes are often missed, leading to surprise reversals or missed opportunities.
Smart MTF S/R Levels was created to solve these problems. It is a fully automated, multi-timeframe, multi-method S/R detection and visualization tool, designed to give traders a complete, objective, and actionable view of the market’s most important price zones.
What Makes This Indicator Unique?
Multi-Timeframe Analysis: Simultaneously analyzes up to three user-selected timeframes, ensuring you never miss a critical S/R level from any timeframe.
Multi-Method Confluence: Integrates several respected S/R detection methods—Swings, Pivots, Fibonacci, Order Blocks, and Volume Profile—into a single, unified system.
Zone Clustering: Automatically merges nearby levels into “zones” to reduce clutter and highlight areas of true market consensus.
Confluence Scoring: Each zone is scored by the number of methods and timeframes in agreement, helping you instantly spot the most significant S/R areas.
Reaction Counting: Tracks how many times price has recently interacted with each zone, providing a real-world measure of its importance.
Customizable Dashboard: A real-time, on-chart table summarizes all key S/R zones, their origins, confluence, and proximity to price.
Smart Alerts: Get notified when price approaches high-confluence zones, so you never miss a critical trading opportunity.
Why Should a Trader Use This?
Objectivity: Removes subjectivity from S/R analysis by using algorithmic detection and clustering.
Efficiency: Saves hours of manual charting and reduces analysis fatigue.
Comprehensiveness: Ensures you are always aware of the most relevant S/R zones, regardless of your trading timeframe.
Actionability: The dashboard and alerts make it easy to act on the most important levels, improving trade timing and risk management.
Adaptability: Works for all asset classes (stocks, forex, crypto, futures) and all trading styles (scalping, swing, position).
The Gap This Indicator Fills
Most S/R indicators focus on a single method or timeframe, leading to incomplete analysis. Manual S/R marking is error-prone and inconsistent. This indicator fills the gap by:
Automating S/R detection across multiple timeframes and methods
Objectively scoring and ranking zones by confluence and reaction
Presenting all this information in a clear, actionable dashboard
How Does It Work? (Technical Logic)
1. Level Detection
For each selected timeframe, the script detects S/R levels using:
SW (Swing High/Low): Recent price pivots where reversals occurred.
Pivot: Classic floor trader pivots (P, S1, R1).
Fib (Fibonacci): Key retracement levels (0.236, 0.382, 0.5, 0.618, 0.786) over the last 50 bars.
Bull OB / Bear OB: Institutional price zones based on bullish/bearish engulfing patterns.
VWAP / POC: Volume Weighted Average Price and Point of Control over the last 50 bars.
2. Level Clustering
Levels within a user-defined % distance are merged into a single “zone.”
Each zone records which methods and timeframes contributed to it.
3. Confluence & Reaction Scoring
Confluence: The number of unique methods/timeframes in agreement for a zone.
Reactions: The number of times price has touched or reversed at the zone in the recent past (user-defined lookback).
4. Filtering & Sorting
Only zones within a user-defined % of the current price are shown (to focus on actionable areas).
Zones can be sorted by confluence, reaction count, or proximity to price.
5. Visualization
Zones: Shaded boxes on the chart (green for support, red for resistance, blue for mixed).
Lines: Mark the exact level of each zone.
Labels: Show level, methods by timeframe (e.g., 15m (3 SW), 30m (1 VWAP)), and (if applicable) Fibonacci ratios.
Dashboard Table: Lists all nearby zones with full details.
6. Alerts
Optional alerts trigger when price approaches a zone with confluence above a user-set threshold.
Inputs & Customization (Explained for All Users)
Show Timeframe 1/2/3: Enable/disable analysis for each timeframe (e.g., 15m, 30m, 1h).
Show Swings/Pivots/Fibonacci/Order Blocks/Volume Profile: Select which S/R methods to include.
Show levels within X% of price: Only display zones near the current price (default: 3%).
How many swing highs/lows to show: Number of recent swings to include (default: 3).
Cluster levels within X%: Merge levels close together into a single zone (default: 0.25%).
Show Top N Zones: Limit the number of zones displayed (default: 8).
Bars to check for reactions: How far back to count price reactions (default: 100).
Sort Zones By: Choose how to rank zones in the dashboard (Confluence, Reactions, Distance).
Alert if Confluence >=: Set the minimum confluence score for alerts (default: 3).
Zone Box Width/Line Length/Label Offset: Control the appearance of zones and labels.
Dashboard Size/Location: Customize the dashboard table.
How to Read the Output
Shaded Boxes: Represent S/R zones. The color indicates type (green = support, red = resistance, blue = mixed).
Lines: Mark the precise level of each zone.
Labels: Show the level, methods by timeframe (e.g., 15m (3 SW), 30m (1 VWAP)), and (if applicable) Fibonacci ratios.
Dashboard Table: Columns include:
Level: Price of the zone
Methods (by TF): Which S/R methods and how many, per timeframe (see abbreviation key below)
Type: Support, Resistance, or Mixed
Confl.: Confluence score (higher = more significant)
React.: Number of recent price reactions
Dist %: Distance from current price (in %)
Abbreviations Used
SW = Swing High/Low (recent price pivots where reversals occurred)
Fib = Fibonacci Level (key retracement levels such as 0.236, 0.382, 0.5, 0.618, 0.786)
VWAP = Volume Weighted Average Price (price level weighted by volume)
POC = Point of Control (price level with the highest traded volume)
Bull OB = Bullish Order Block (institutional support zone from bullish price action)
Bear OB = Bearish Order Block (institutional resistance zone from bearish price action)
Pivot = Pivot Point (classic floor trader pivots: P, S1, R1)
These abbreviations appear in the dashboard and chart labels for clarity.
Example: How to Read the Dashboard and Labels (from the chart above)
Suppose you are trading BTCUSDT on a 15-minute chart. The dashboard at the top right shows several S/R zones, each with a breakdown of which timeframes and methods contributed to their detection:
Resistance zone at 119257.11:
The dashboard shows:
5m (1 SW), 15m (2 SW), 1h (3 SW)
This means the level 119257.11 was identified as a resistance zone by one swing high (SW) on the 5-minute timeframe, two swing highs on the 15-minute timeframe, and three swing highs on the 1-hour timeframe. The confluence score is 6 (total number of method/timeframe hits), and there has been 1 recent price reaction at this level. This suggests 119257.11 is a strong resistance zone, confirmed by multiple swing highs across all selected timeframes.
Mixed zone at 118767.97:
The dashboard shows:
5m (2 SW), 15m (2 SW)
This means the level 118767.97 was identified by two swing points on both the 5-minute and 15-minute timeframes. The confluence score is 4, and there have been 19 recent price reactions at this level, indicating it is a highly reactive zone.
Support zone at 117411.35:
The dashboard shows:
5m (2 SW), 1h (2 SW)
This means the level 117411.35 was identified as a support zone by two swing lows on the 5-minute timeframe and two swing lows on the 1-hour timeframe. The confluence score is 4, and there have been 2 recent price reactions at this level.
Mixed zone at 118291.45:
The dashboard shows:
15m (1 SW, 1 VWAP), 5m (1 VWAP), 1h (1 VWAP)
This means the level 118291.45 was identified by a swing and VWAP on the 15-minute timeframe, and by VWAP on both the 5-minute and 1-hour timeframes. The confluence score is 4, and there have been 12 recent price reactions at this level.
Support zone at 117103.10:
The dashboard shows:
15m (1 SW), 1h (1 SW)
This means the level 117103.10 was identified by a single swing low on both the 15-minute and 1-hour timeframes. The confluence score is 2, and there have been no recent price reactions at this level.
Resistance zone at 117899.33:
The dashboard shows:
5m (1 SW)
This means the level 117899.33 was identified by a single swing high on the 5-minute timeframe. The confluence score is 1, and there have been no recent price reactions at this level.
How to use this:
Zones with higher confluence (more methods and timeframes in agreement) and more recent reactions are generally more significant. For example, the resistance at 119257.11 is much stronger than the resistance at 117899.33, and the mixed zone at 118767.97 has shown the most recent price reactions, making it a key area to watch for potential reversals or breakouts.
Tip:
“SW” stands for Swing High/Low, and “VWAP” stands for Volume Weighted Average Price.
The format 15m (2 SW) means two swing points were detected on the 15-minute timeframe.
Best Practices & Recommendations
Use with Other Tools: This indicator is most powerful when combined with your own price action analysis and risk management.
Adjust Settings: Experiment with timeframes, clustering, and methods to suit your trading style and the asset’s volatility.
Watch for High Confluence: Zones with higher confluence and more reactions are generally more significant.
Limitations
No Future Prediction: The indicator does not predict future price movement; it highlights areas where price is statistically more likely to react.
Not a Standalone System: Should be used as part of a broader trading plan.
Historical Data: Reaction counts are based on historical price action and may not always repeat.
Disclaimer
This indicator is a technical analysis tool and does not constitute financial advice or a recommendation to buy or sell any asset. Trading involves risk, and past performance is not indicative of future results. Always use proper risk management and consult a financial advisor if needed.
SPY, QQQ, VIX Status TableBased on Ripster EMA and 1 hour MTF Clouds, this custom TradingView indicator displays a visual trend status table for SPY, QQQ, and VIX using multiple timeframes and EMA-based logic to be used on any stock ticker.
🔍 Key Features:
✅ Tracks 3 symbols: SPY, QQQ, and VIX
✅ Multiple trend conditions:
10-min (5/12 EMA) Ripster cloud trend
10-min (34/50 EMA) Ripster cloud trend
1-Hour Multi-Timeframe Ripster EMA trend
Daily open/close trend
✅ Color-coded trend strength:
🟩 Green = Bullish
🟥 Red = Bearish
🟨 Yellow = Sideways
✅ TO save screen space, customizations available:
Show/hide individual rows (SPY, QQQ, VIX)
Show/hide any trend column (10m, 1H MTF, Daily)
Change header/background colors and font color
Bold white top row for readability
✅ Auto-updating table appears on your chart, top-right
This tool is great for active traders looking to quickly scan short-term and longer-term momentum in key market instruments without having to go back and forth market charts.
Bollingr+supertrend Hybrid ProIntroducing the Bollinger & Supertrend Hybrid Pro — a powerful all-in-one trend-following and volatility mapping tool designed for modern traders in Forex, Indices, Commodities, Crypto, and Stocks.
How it works:
The indicator overlays classic Bollinger Bands to capture market volatility, squeeze breakouts, and dynamic support/resistance zones.
Integrated Supertrend logic highlights trend direction using ATR (Average True Range), making trend reversals clear and visually clean.
Automatic Buy & Sell signals appear when trend direction flips — helping you stay on the right side of momentum.
Dynamic background fill colors show uptrend and downtrend zones for quick chart scanning.
Customizable Inputs:
Adjust Bollinger Band length, deviation, and MA type (SMA, EMA, WMA, SMMA, VWMA).
Fine-tune Supertrend ATR period and factor to match your strategy style.
Labels and signals for clear on-chart alerts.
Ideal For:
Intraday, swing, and positional traders.
Beginners and advanced users looking for a clean hybrid trend system.
trade bằng mông xu hướng//@description=This TradingView indicator is designed to detect key price structure levels by identifying swing highs and lows on the chart. It automatically labels these points and draws trend zones (ranges) based on confirmed breakouts. The indicator helps traders visualize market structure shifts, determine trend direction (uptrend, downtrend, or neutral), and make more informed trading decisions. It includes customizable settings such as lookback period, label visibility, and zone colors, and supports multi-timeframe analysis for greater flexibility.
BE-Indicator Aggregator toolkit█ Overview:
BE-Indicator Aggregator toolkit is a toolkit which is built for those we rely on taking multi-confirmation from different indicators available with the traders. This Toolkit aid's traders in understanding their custom logic for their trade setups and provides the summarized results on how it performed over the past.
█ How It Works:
Load the external indicator plots in the indicator input setting
Provide your custom logic for the trade setup
Set your expected SL & TP values
█ Legends, Definitions & Logic Building Rules:
Building the logic for your trade setup plays a pivotal role in the toolkit, it shall be broken into parts and toolkit aims to understand each of the logical parts of your setup and interpret the outcome as trade accuracy.
Toolkit broadly aims to understand 4 types of inputs in "Condition Builder"
Comments : Line which starts with single quotation ( ' ) shall be ignored by toolkit while understanding the logic.
Note: Blank line space or less than 3 characters are treated equally to comments.
Long Condition: Line which starts with " L- " shall be considered for identifying Long setups.
Short Condition: Line which starts with " S- " shall be considered for identifying Short setups.
Variables: Line which starts with " VAR- " shall be considered as variables. Variables can be one such criteria for Long or short condition.
Building Rules: Define all variables first then specify the condition. The usual declare and assign concept of programming. :p)
Criteria Rules: Criteria are individual logic for your one parent condition. multiple criteria can be present in one condition. Each parameter should be delimited with ' | ' key and each criteria should be delimited with ' , ' (Comma with a space - IMPORTANT!!!)
█ Sample Codes for Conditional Builder:
For Trading Long when Open = Low
For Trading Short when Open = High with a Red candle
'Long Setup <---- Comment
L-O|E|L
' E <- in the above line refers to Equals ' = '
'Short Setup
S-AND:O|E|H, O|G|C
' 2 Criteria for used building one condition. Since, both have to satisfied used "AND:" logic.
Understanding of Operator Legends:
"E" => Refers to Equals
"NE" => Refers to Not Equals
"NEOR" => Logical value is Either Comparing value 1 or Comparing value 2
"NEAND" => Logical value is Comparing value 1 And Comparing value 2
"G" => Logical value Greater than Comparing value 1
"GE" => Logical value Greater than and equal to Comparing value 1
"L" => Logical value Lesser than Comparing value 1
"LE" => Logical value Lesser than and equal to Comparing value 1
"B" => Logical value is Between Comparing value 1 & Comparing value 2
"BE" => Logical value is Between or Equal to Comparing value 1 & Comparing value 2
"OSE" => Logical value is Outside of Comparing value 1 & Comparing value 2
"OSI" => Logical value is Outside or Equal to Comparing value 1 & Comparing value 2
"ERR" => Logical value is 'na'
"NERR" => Logical value is not 'na'
"CO" => Logical value Crossed Over Comparing value 1
"CU" => Logical value Crossed Under Comparing value 1
Understanding of Condition Legends:
AND: -> All criteria's to be satisfied for the condition to be True.
NAND: -> Output of AND condition shall be Inversed for the condition to be True.
OR: -> One of criteria to be satisfied for the condition to be True.
NOR: -> Output of OR condition shall be Inversed for the condition to be True.
ATLEAST:X: -> At-least X no of criteria to be satisfied for the condition to be True.
Note: "X" can be any number
NATLEAST:X: -> Output of ATLEAST condition shall be Inversed for the condition to be True
WASTRUE:X: -> Single criteria WAS TRUE within X bar in past for the condition to be True.
Note: "X" can be any number.
ISTRUE:X: -> Single criteria is TRUE since X bar in past for the condition to be True.
Note: "X" can be any number.
Understanding of Variable Legends:
While Condition Supports 8 Types, Variable supports only 6 Types listed below
AND: -> All criteria's to be satisfied for the Variable to be True.
NAND: -> Output of AND condition shall be Inversed for the Variable to be True.
OR: -> One of criteria to be satisfied for the Variable to be True.
NOR: -> Output of OR condition shall be Inversed for the Variable to be True.
ATLEAST:X: -> At-least X no of criteria to be satisfied for the Variable to be True.
Note: "X" can be any number
NATLEAST:X: -> Output of ATLEAST condition shall be Inversed for the Variable to be True
█ Sample Outputs with Logics:
1. RSI Indicator + Technical Indicator: StopLoss: 2.25 against Reward ratio of 1.75 (3.94 value)
Plots Used in Indicator Settings:
Source 1:- RSI
Source 2:- RSI Based MA
Source 3:- Strong Buy
Source 4:- Strong Sell
Logic Used:
For Long Setup : RSI Should be above RSI Based MA, RSI has been Rising when compared to 3 candles ago, Technical Indicator signaled for a Strong Buy on the current candle, however in last 6 candles Technical indicator signaled for Strong Sell.
Similarly Inverse for Short Setup.
L-AND:ES1|GE|ES2, ES1|G|ES1
L-ES3|E|1
L-OR:ES4 |E|1, ES4 |E|1, ES4 |E|1, ES4 |E|1, ES4 |E|1, ES4 |E|1
S-AND:ES1|LE|ES2, ES1|L|ES1
S-ES4|E|1
S-OR:ES3 |E|1, ES3 |E|1, ES3 |E|1, ES3 |E|1, ES3 |E|1, ES3 |E|1
'Note: Last OR condition can also be written by using WASTRUE definition like below
'L-WASTRUE:6:ES4|E|1
'S-WASTRUE:6:ES3|E|1
Output:
2. Volumatic Support / Resistance Levels :
Plots Used in Indicator Settings:
Source 1:- Resistance
Source 2:- Support
Logic Used:
For Long Setup : Long Trade on Liquidity Support.
For Short Setup : Short Trade on Liquidity Resistance.
'Variable Named "ChkLowTradingAbvSupport" is declared to check if last 3 candles is trading above support line of liquidity.
VAR-ChkLowTradingAbvSupport:AND:L|G|ES2, L |G|ES2, L |G|ES2
'Variable Named "ChkCurBarClsdAbv4thBarHigh" is declared to check if current bar closed above the high of previous candle where the Liquidity support is taken (4th Bar).
VAR-ChkCurBarClsdAbv4thBarHigh:OR:C|GE|H , L|G|H
'Combining Condition and Variable to Initiate Long Trade Logic
L-L |LE|ES2
L-AND:ChkLowTradingAbvSupport, ChkCurBarClsdAbv4thBarHigh
VAR-ChkHghTradingBlwRes:AND:H|L|ES1, H |L|ES1, H |L|ES1
VAR-ChkCurBarClsdBlw4thBarLow:OR:C|LE|L , H|L|L
S-H |GE|ES1
S-AND:ChkHghTradingBlwRes, ChkCurBarClsdBlw4thBarLow
Output 1: Day Trading Version
Output 2: Scalper Version
Output 3: Position Version
🟡🔵🟢🔴Beginner's Assistant by carljchapman🟡🔵🟢🔴
Overview
This indicator dynamically marks highs and lows of the premarket (4:00am-9:30amEST) and opening range. It displays Fair Value Gaps, 9 and 21 period Exponential Moving Averages (EMA) and the Volume Weighted Average Price (VWAP). To really help beginners, it marks suggested entry points on the chart with green or red triangles, when a reasonable trend appears.
Features
Automatically draws blue lines for Premarket High and Low values
Dynamically marks the opening Range region
Visual entry signals for long and short opportunities
Primarily used for stocks/funds , but works with forex and crypto
Quick configuration settings to tailor details for your experience level
Mobile friendly mode
Supports alerts
How To Use
Open your chart, and select a 1 or 2 minute timeframe.
Watch for green triangles and red triangles, hinting at entries for long or short positions. Pay particular attention to the price action as it approaches the bounds of the opening range and the premarket levels. I suggest also using a MACD indicator for confirmation of the trend.
For scalping 0dte Options, switch frequently between the 1 ,2 and 5 minute or higher timeframes. Do this so you will not miss an entry opportunity or be unaware of the overall trend.
As a beginner, until you have refined your strategy and develop risk management, take profits as low as 10%. A small profit can quickly become a much larger loss. With 0dte options, time will devour your profits even when the price doesn’t budge.
What makes this indicator so beginner friendly?
Charts with too many lines and colors are are a nightmare for beginners! And empty charts do not tell the whole story. Simple checkboxes in the configuration settings let you turn on and off features to match your comfort level. As you become more familiar you might try turning off the suggested entries to see if you would have selected the same or better ones yourself. Just one example of how you will learn and verify your knowledge. You will quickly spot Opening Range Breakouts and more.
Why are the triangle pointers not simply above or below the bars?
As a beginner, I like to review charts to see how much the price changed, then estimate how much a contract would move based on its delta. A mouthful, I know. But what price does an arrow pointing up below a bar reflect? Would I have entered at the open or close, low or high? This indicator helps by putting the marker close to the price when indicated. It can even display the actual price on the bar. This is helpful for you to make fast calculations without a measuring tool.
I am an experienced trader. Can this help me make winning trades?
Sure. It can also help you make losing ones! Profit is not guaranteed with any indicator or strategy. This indicator is designed to assist you as you learn and while you trade. You won't see the words BUY or SELL. This is not a signal bot! It is merely a tool to assist you. You can learn a lot by spending time observing price movement using this indicator without ever making a single trade.
🟡🔵🟢🔴
Magnet Zones: Trap Detection & Flow Map [@darshakssc]This script detects potential bull and bear trap candles—price actions that may appear strong but are likely to reverse—based on:
🔺 Wick structure
📊 Volume spike behavior
💡 RSI confirmation logic
⏳ Signal cooldown filter to reduce false positives
The indicator then plots:
🟥 Red “🚨 Trap” labels above candles showing possible bull traps
🟩 Green “🧲 Trap” labels below candles showing possible bear traps
➖ Horizontal zone lines to mark these trap levels as “magnet zones,” which may act as future support or resistance
🧠 How It Works:
1. Volume Spike Detection
2. The script first checks for unusually high volume (1.5× the average volume over the last 20 candles).
3. Trap Candle Structure
4. A trap is suspected when there is a long wick opposite the direction of the candle body, signaling a failed breakout or price manipulation.
5. RSI Confirmation
6. Bull Traps: RSI must be above 60
7. Bear Traps: RSI must be below 40
✅ This helps validate whether the price was overbought or oversold.
✅ Cooldown Mechanism
✅ After a trap is detected, it waits for 10 bars before allowing another signal—this reduces noise and overfitting.
✅ How to Use It:
1. Apply on any timeframe, especially effective for intraday trading (e.g. 5m, 15m, 1h).
2. Use the trap signals as early warnings to avoid fake breakouts.
3. Combine with your own strategy or trend-following system for confirmation.
4. The trap lines (magnet zones) can be used as dynamic support/resistance levels for future pullbacks or reversals.
⚠️ Important Note:
This script is for educational purposes only and is not financial advice.
Always use traps in combination with your personal discretion, risk management, and other confluence tools.
Logarithmic Moving Average (LMA) [QuantAlgo Original Author: QuantAlgo
License: Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International
Source: creativecommons.org
This script is originally developed by QuantAlgo and is shared under the CC BY-NC-SA 4.0 license.
I have reused and slightly modified it for personal learning and for the benefit of the TradingView community.
All core credits belong to QuantAlgo.
This version remains fully open-source and non-commercial, respecting the original license terms.
Anyone reusing or modifying this script must keep the same license and attribution.
— Modified & shared publicly by Mark804
[Pandora] Laguerre Ultimate Explorations MulticatorIt's time to begin demonstrations differentiating the difference between known and actual feasibility beyond imagination... Welcome to my algorithmic twilight zone .
INTRODUCTION:
Hot off my press, I present this Laguerre multicator employing PSv6.0, originally formulated by John Ehlers for TASC - July 2025 Traders Tips. Basically I transcended Ehlers' notions of transversal filtration with an overhaul of his Laguerre design with my "what if" Pandora notions included. Striving beyond John Ehlers' original intended design. This action packed indicator is a radically revamped version of his original filter using novel techniques. My aim was to explore whether providing even more enhanced responsiveness and lesser lag is possible and how. Presented here is my mind warping results to witness.
EHLERS' LAGUERRE EXPLAINED:
First and foremost, the concept of Ehlers' Laguerre-izing method deserves a comprehensive deep dive. Ehlers' Laguerre filter design, as it functions originally, begins with his Ultimate Smoother (US) followed by a gang of four LERP (jargon for Linear intERPolation) filters. Following a myriad of cascading LERPs is a window-like FIR filter tapped into the LERP delay values to provide extra smoothness via the output.
On a side note, damping factor controlled LERP filters resemble EMAs indeed, but aren't exactly "periodic" filters that would have a period/length parameter and their subsequent calculations. I won't go into fine-grained relationship details, but EMA and LERP are indeed related in approach, being cousins of similar pedigree.
EXAMINING LAGUERRE:
I focused firstly on US initialization obstacles at Pine's bar_index==0 with nz() in abundance. The next primary notion of intrigue I mostly wondered about was, why are there four LERP elements instead of fewer or more. Why not three or why not two LERPs, etc... 1-4-6-4-1, I remember seeing those coefficients before in high pass filters.
Gathering my thoughts from that highpass knowledge base, I devised other tapped configuration modes to inspect their behavior out of curiosity. Eureka! There is actually more to Laguerre than Ehlers' mind provided, now that I had formulated additional modes. Each mode exhibits it's own lag/smoothness characteristics better than the quad LERPed version. I narrowed it down to a total of 5 modes for exploration. Mode 0 is just the raw US by itself.
ANALYZING FILTER BEHAVIORS:
Which option might be possibly superior, and how may I determine that? Fortunately, I have a custom-built analyzer allowing me to thoroughly examine transient responses across multiple periodicities simultaneously, providing remarkable visual insights.
While Ehlers has meagerly touched upon presenting general frequency responses in his books, I have excelled far beyond that. This robust filter analysis capability enables me to observe finer aspects hidden to others, ultimately leading to the deprecation of numerous existing filters. Not only this, but inventing entirely new species of filtration whether lowpass, highpass, or bandpass is already possible with a thorough comprehensive evaluation.
Revealing what's quirky with each filter and having the ability to discover what filters may be lacking in performance, is one of it's implications. I'm just going to explain this: For example US has a little too much overshoot to my liking, along with nonconformant cutoff frequency compliance with the period parameter. Perhaps Ehlers should inspect US coefficients a bit closer... I hope stating this is not received in an ill manner, as it's not my intention here.
What this technically eludes to is that UltimateSmoother can be further improved, analogous to my Laguerre alterations described above. I will also state Laguerre can indeed be reformulated to an even greater extent concerning group delay, from what I have already discussed. Another exciting time though... More investigative research is warranted.
LAGUERRE CONCLUSIONS:
After analyzing Laguerre's frequency compliance, transient responses, amplitudes, lag, symmetry across periodicities, noise rejection, and smoothness... I favor mode 3 for a multitude of reasons over the mode 4 configuration, but mostly superb smoothing with less lag, AND I also appreciated mode 1 & 2 for it's lower lag performance options.
Each mode and lag (phase shift) damping value has it's own unique characteristics at extremes, yet they demonstrate additional finesse in it's new hybrid form without adding too much more complexity. This multicator has a bunch of Laguerre filters in the overlay chart over many periodicities so you can easily witness it's differing periodic symmetries on an input signal while adjusting lag and mode.
LAGUERRE OSCILLATOR:
The oscillator is integrated into the laguerreMulti() function for the intention of posterity only. I performed no evaluation on it, only providing the code in Pine. That wasn't part of my intended exploration adventure, as I'm more TREND oriented for the time being, focusing my efforts there.
Market analysis has two primary aspects in my observations, one cyclic while the other is trending dynamics... There's endless oscillators, but my expectations for trend analysis seems a little lesser explored in my opinion, hence my laborious trend endeavors. Ehlers provided both indicator facets this time around, and I hope you find the filtration aspect more intriguing after absorption of this reading.
FUNCTION MODULES EXPLAINED:
The Ultimate Smoother is an advanced IIR lowpass smoothing filter intended to minimize noise in time series data with minimal group delay, similar to a traditional biquad filter. This calculation helps to create a smoother version of the original signal without the distortions of short-term fluctuations and with minimal lag, adjustable by period.
The Modified Laguerre Lowpass Filter (MLLF) enhances the functionality of US by introducing a Laguerre mode parameter along side the lag parameter to refine control over the amount of additional smoothing/lag applied to the signal. By tethering US with this LERPed lag mechanism, MLLF achieves an effective balance between responsiveness and smoothness, allowing for customizable lag adjustments via multiple inputs. This filter ends with selecting from a choice of weighted averages derived from a gang of up to four cascading LERP calculations, resulting with smoother representations of the data.
The Laguerre Oscillator is a momentum-like indicator derived from the output of US and a singular LERPed lowpass filter. It calculates the difference between the US data and Laguerre filter data, normalizing it by the root mean square (RMS). This quasi-normalization technique helps to assess the intensity of the momentum on any timeframe within an expected bound range centered around 0.0. When the Laguerre Oscillator is positive, it suggests that the smoothed data is trending upward, while a negative value indicates a downward trend. Adjustability is controlled with period, lag, Laguerre mode, and RMS period.
Dual ORB (5 & 15 Min) Retest SignalsThe Dual Orb Indicator allows you to see the orb effortlessly! it also gives you buy/sell signals on both the 5 minute timeframe and the 15 minute timeframe! if you have any questions or suggestions please comment below and let me know what you think!
Extreme Zone Volume ProfileExtreme Zone Volume Profile (EZVP) is a high-resolution, percentile-based volume profile tool designed for intuitive market structure analysis. Unlike standard profiles, EZVP emphasizes extreme zones — highlighting potential value rejection or accumulation areas using user-defined percentile thresholds.
Key Features:
Custom Lookback: Profiles volume over a defined number of bars (no rolling memory creep).
Zoned Percentiles: Segment volume by zones:
Zone B = extreme tails (e.g. 2.5% for one wing of ~2 Standard Deviations)
Zone A = outer wings (e.g. 14% for one wing of ~1 Standard Deviations)
Center = remaining bulk of traded volume
Rightward-Growing Bars: Clean, forward-facing display — avoids clutter in historical areas.
Colored Volume Bars: Each zone gets a distinct tone, helping spot high-interest levels fast.
Optional Lines: Toggle POC, Median, Mean, and zone boundary lines for cleaner setups.
This is built for clarity and control — a great fit for traders who want a visually expressive profile without overcomplication. Tweak the zoning percentages to match your strategy or instrument volatility.
Call and Put signals[vivekm8955]🔍 Strategy Overview
This adaptive strategy generates clear CALL (Buy) and PUT (Sell) signals by combining:
✅ Dual EMA structure
✅ Heikin Ashi trend confirmation
✅ Smoothed Stochastic Momentum Index (SMI)
✅ Take Profit (TP) signals via momentum reversal
✅ Dynamic support from average price action
The goal: Give retail traders institutional-grade signals with clarity, without lag.
📊 Trade Entry Logic
🔼 CALL Signal (Buy):
Fast EMA < Avg Price
Slow EMA < Avg Price
Slow EMA < Fast EMA
Confirmed by crossover
➡️ This implies price has dipped below value zones and is showing strength.
🔽 PUT Signal (Sell):
Fast EMA > Avg Price
Slow EMA > Avg Price
Slow EMA > Fast EMA
Confirmed by crossover
➡️ Indicates price is elevated and showing weakness.
🏁 Exit Logic (Take Profit)
✅ TP Buy Signal: SMI crosses below 0 → Weakening upside
✅ TP Sell Signal: SMI crosses above 0 → Weakening downside
These act as exit cues or partial booking areas.
📌 Visualization & Alerts
🔼 CALL Signal → Green label below candle
🔽 PUT Signal → Red label above candle
✅ TP Signal → Small label (TP) showing ideal exit points
🔔 Real-time alerts enabled (CALL, PUT, TP alerts)
Background color changes based on EMA crossovers for added confirmation.
🕯️ Additional Filters Used
Heikin Ashi Candles: For smoothing out noise and validating trends.
SMI (Double EMA): A momentum indicator better suited for trending markets.
📈 Dashboard Included
Displays current signal, SMI value, and TP status in real-time
Color-coded for easy interpretation
Auto-adaptive table (fixes out-of-bound issues)
📎 Ideal Timeframes
Timeframe Use Case
5m – 15m Intraday Scalping
1h – 4h Swing Trading
1D Positional Plays
🚦 Suggested Usage
Step Action
1️⃣ Confirm signal (CALL or PUT) on 1TF and 1 higher TF
2️⃣ Enter near signal candle close
3️⃣ Exit on TP label OR SMI reversal
4️⃣ Avoid entry during high volatility news events
⚠️ Disclaimer – Use with Caution!
⚠️ This script is for educational & analytical purposes only.
It does NOT guarantee profits, nor is it a financial advisory tool.
Always use risk management: Stop-losses, position sizing, capital preservation.
Do not trade blindly. Backtest it across market conditions.
Past performance is not indicative of future results.
Consult a SEBI-registered advisor for real trading decisions.
Basic ORB [MOT]🟢 Basic ORB – Opening Range Breakout Indicator by MOT
The Basic ORB is a high-performance Opening Range Breakout (ORB) tool built for serious intraday traders. This indicator is being provided to the public for free.
It automatically draws the high, low, and midline of the 9:30–9:45 AM ET session, giving you a visual framework for high-probability breakout and reversal opportunities. You can customize line colors and enable historical ORBs — all from a clean, intuitive interface.
📌 1. ORB High, Low & Midline Levels
Function: Automatically draws the high, low, and midpoint of the 9:30–9:45 session.
ORB High (green line by default)
ORB Low (red line by default)
Midline (white line) helps gauge control or range equilibrium
📸 Live ORB range drawing: high, low, and midline levels.
🔁 2. Show Previous ORBs
Function: Displays up to N previous days' ORBs for pattern recognition or confluence stacking.
Previous ORB count up to chart data maximum
Great for seeing whether price respects prior opening ranges
📸 Historical ORB ranges for confluence and support/resistance.
🏷️ 3. Dynamic Price Labels
Function: Price labels are placed next to each ORB for quick visibility.
Labels can be toggled on/off
Customizable text color, background color, and size
Offset control available
⚙️ 4. Fully Customizable Settings Panel
Function: Every visual element is adjustable, including:
✅ Line color and width
✅ Number of historical ORBs
✅ Label size, position, background/text color
📈 Use Case
Works best on 1m, 5m, or 15m charts
Ideal for breakout traders, reversal scalpers, or gap/ORB retest strategies
Applies to futures, stocks, ETFs, indexes, and crypto
⚠️ Disclaimer
This indicator is intended for educational and informational purposes only. It is not financial advice. Trading involves substantial risk. Always use proper risk management and test in a simulated environment before applying live. The author is not liable for any fi
ICT Concepts Toolkit [TWS]
ICT Concepts Toolkit – by Trade With Stevie
Unlock the full power of Inner Circle Trader (ICT) concepts with this all-in-one indicator built for serious traders.
The ICT Concepts Toolkit combines the most powerful price action tools into one clean, efficient, and highly customizable interface — perfect for mastering market structure and timing precision entries.
✅ Features Included:
🟩 Order Blocks – Automatically detect key institutional levels for potential reversals and entries.
📉 Fair Value Gaps (FVGs) – Visualize imbalances in price action to spot high-probability targets and mitigation zones.
📊 Support & Resistance – Dynamically plotted levels to track market structure and trend shifts in real-time.
📅 Previous Daily Highs/Lows – Key liquidity zones marked for precision scalping and swing setups.
🕒 Session Zones – Clearly defined Asian, London, and New York sessions with customizable times and colors.
📌 Extension Lines – Extends each session’s high and low to the current candle for ongoing bias and liquidity mapping.
🚦ICT Morning Signal – Your personal directional bias assistant: smart signals showing when to Buy or Sell based on ICT’s powerful Morning Model logic.
Whether you're trading Forex, Futures, or Crypto — this toolkit gives you a cleaner chart, clearer bias, and more confidence in your setups.
💡 Created by Trade With Stevie — follow for more smart tools and signal insights.
TrendShift [MOT]📈 TrendShift – Multi-Factor Momentum & Trend Signal Suite
TrendShift is a precision-built momentum and confluence tool designed to highlight directional shifts in price action. It combines EMA slope structure, oscillator confirmation, volume behavior, and dynamic SL/TP logic into one cohesive system. Whether you're trading with the trend or catching reversals, TrendShift provides data-backed clarity and visual confidence — and it’s available free to the public.
🔍 Core Signal Logic
Buy (🟢 Long) and Sell (🔴 Short) signals are triggered when multiple conditions align within a set bar window (default: 5 bars):
Stochastic RSI K/D cross
RSI crosses above 20 (long) or below 80 (short)
Stochastic RSI breaks 20 (long) or 80 (short)
Volume exceeds 20-bar average
🧭 Visual Trend Dashboard – Signal Table
A real-time on-chart dashboard displays:
EMA Trend: Bullish / Bearish / Mixed (based on 4 EMA slopes)
Stoch RSI: Oversold / Overbought / Neutral
RSI: Exact value with zone label
Volume: Above or Below average
Dashboard theme and position are fully customizable.
📐 Trend Structure with EMA Slope Logic
Plots four EMAs (21, 50, 100, 200) color-coded by slope:
Green = Rising
Red = Falling
These feed into the dashboard's EMA Trend display.
🎯 Optional Take Profit / Stop Loss Zones
When enabled, SL/TP lines plot automatically on valid signals:
Fixed-distance targets (e.g., 10pt TP, 5pt SL)
Auto-remove on TP or SL hit
Separate lines for long vs. short trades
Fully customizable styling
🔁 Trailing Stop Filter (Internal Logic)
A custom ATR-based trailing stop helps validate directional strength:
ATR period
HHV window
ATR multiplier
Used internally — not plotted — to confirm trend progression before entry.
⚙️ Customizable Parameters
Every core component is user-configurable:
EMA periods: 21 / 50 / 100 / 200
ATR trailing logic: period, HHV, multiplier
Oscillator settings: Stoch RSI & RSI
Volume length
SL/TP toggles and point values
Bar clustering window
Dashboard theme and location
🔔 Alerts Included
BUY Signal Triggered
SELL Signal Triggered
Compatible with webhook automation or mobile push notifications.
⚠️ Disclaimer
This tool is for educational purposes only and is not financial advice. Trading involves risk — always do your own research and consult a licensed professional before making trading decisions.
ICT TOOLS//@version=5
indicator("ICT TOOLS", overlay=true, max_lines_count=500, max_labels_count=5, max_boxes_count=500)
// General Settings Inputs
TZI = input.string (defval="UTC -4", title="Timezone Selection", options= , tooltip="Select the Timezone. ( Shifts Chart Elements )", group="Global Settings")
Timezone = TZI == "UTC -10" ? "GMT-10:00" : TZI == "UTC -7" ? "GMT-07:00" : TZI == "UTC -6" ? "GMT-06:00" : TZI == "UTC -5" ? "GMT-05:00" : TZI == "UTC -4" ? "GMT-04:00" : TZI == "UTC -3" ? "GMT-03:00" : TZI == "UTC +0" ? "GMT+00:00" : TZI == "UTC +1" ? "GMT+01:00" : TZI == "UTC +2" ? "GMT+02:00" : TZI == "UTC +3" ? "GMT+03:00" : TZI == "UTC +3:30" ? "GMT+03:30" : TZI == "UTC +4" ? "GMT+04:00" : TZI == "UTC +5" ? "GMT+05:00" : TZI == "UTC +5:30" ? "GMT+05:30" : TZI == "UTC +6" ? "GMT+06:00" : TZI == "UTC +7" ? "GMT+07:00" : TZI == "UTC +8" ? "GMT+08:00" : TZI == "UTC +9" ? "GMT+09:00" : TZI == "UTC +9:30" ? "GMT+09:30" : TZI == "UTC +10" ? "GMT+10:00" : TZI == "UTC +10:30" ? "GMT+10:30" : TZI == "UTC +11" ? "GMT+11:00" : TZI == "UTC +13" ? "GMT+13:00" : "GMT+13:45"
inputMaxInterval = input.int (31, title="Hide Indicator Above Specified Minutes", tooltip="Above 30Min, Chart Will Become Messy & Unreadable", group="Global Settings")
// Session options
ShowTSO = input.bool (true, title="Show Today's Session Only", group="Session Options", tooltip="Hide Historical Sessions")
ShowTWO = input.bool (true, title="Show Current Week's Sessions Only", group="Session Options", tooltip="Show All Sessions from the current week")
SL4W = input.bool (true, title="Show Last 4 Week Sessions", group="Session Options", tooltip="Show All Sessions from Last Four Weeks Should Disable Current Week Session to Work")
ShowSFill = input.bool (false, title="Show Session Highlighting", group="Session Options", tooltip="Highlights Session from Top of the Chart to Bottom")
//----------------------------------------------
// Historical Lines
ShowMOPL = input.bool (title="Midnight Historical Price Lines", defval=false, group="Historical Lines", tooltip="Shows Historical Midnight Price Lines")
MOLHist = input.bool (title="Midnight Historical Vertical Lines", defval=true, group="Historical Lines", tooltip="Shows Historical Midnight Vertical Lines")
ShowPrev = input.bool (false, title="Misc. Historical Price Lines", group="Historical Lines", tooltip="Makes Chart Cluttered, Use For Backtesting Only")
//----------------------------------------------
// Session Bool
ShowLondon = input.bool (false, "", inline="LONDON", group="Sessions", tooltip="01:00 to 05:00")
ShowNY = input.bool (false, "", inline="NY", group="Sessions", tooltip="07:00 to 10:00")
ShowLC = input.bool (false, "", inline="LC", group="Sessions", tooltip="10:00 to 12:00")
ShowPM = input.bool (false, "",inline="PM", group="Sessions", tooltip="13:00 to 16:00")
ShowAsian = input.bool (false, "",inline="ASIA2", group="Sessions", tooltip="20:00 to 00:00")
ShowFreeSesh = input.bool (false, "",inline="FREE", group="Sessions", tooltip="Custom Session")
// Session Strings
txt2 = input.string ("LONDON", title="", inline="LONDON", group="Sessions")
txt3 = input.string ("NEW YORK", title="", inline="NY", group="Sessions")
txt4 = input.string ("LDN CLOSE", title="", inline="LC", group="Sessions")
txt5 = input.string ("AFTERNOON", title="", inline="PM", group="Sessions")
txt6 = input.string ("ASIA", title="", inline="ASIA2", group="Sessions")
txt9 = input.string ("FREE SESH", title="", inline="FREE", group="Sessions")
// CBDR = input.session ('1400-2000:1234567', "", inline="CBDR", group="Sessions")
// ASIA = input.session ('2000-0000:1234567', "", inline="ASIA", group="Sessions")
// Session Times
LDNsesh = input.session ('0200-0500:1234567', "", inline="LONDON", group="Sessions")
NYsesh = input.session ('0700-1000:1234567', "", inline="NY", group="Sessions")
LCsesh = input.session ('1000-1200:1234567', "", inline="LC", group="Sessions")
PMsesh = input.session ('1300-1600:1234567', "", inline="PM", group="Sessions")
ASIA2sesh = input.session ('2000-2359:1234567', "", inline="ASIA2", group="Sessions")
FreeSesh = input.session ('0000-0000:1234567', "", inline="FREE", group="Sessions")
// Session Color
LSFC = input.color (color.new(#787b86, 90), "", inline="LONDON", group="Sessions")
NYSFC = input.color (color.new(#787b86, 90), "",inline="NY", group="Sessions")
LCSFC = input.color (color.new(#787b86, 90), "",inline="LC", group="Sessions")
PMSFC = input.color (color.new(#787b86, 90), "",inline="PM", group="Sessions")
ASFC = input.color (color.new(#787b86, 90), "",inline="ASIA2", group="Sessions")
FSFC = input.color (color.new(#787b86, 90), "",inline="FREE", group="Sessions")
//----------------------------------------------
// Vertical Line Bool
ShowMOP = input.bool (title="", defval=true, inline="MOP", group="Vertical Lines", tooltip="00:00 AM")
txt12 = input.string ("MIDNIGHT", title="", inline="MOP", group="Vertical Lines")
ShowLOP = input.bool (title="", defval=false, inline="LOP", group="Vertical Lines", tooltip="03:00 AM")
txt14 = input.string ("LONDON", title="", inline="LOP", group="Vertical Lines")
ShowNYOP = input.bool (title="", defval=true, inline="NYOP", group="Vertical Lines", tooltip="08:30 AM")
txt15 = input.string ("NEW YORK", title="", inline="NYOP", group="Vertical Lines")
ShowEOP = input.bool (title="", defval=false, inline="EOP", group="Vertical Lines", tooltip="09:30 AM")
txt16 = input.string ("EQUITIES", title="", inline="EOP", group="Vertical Lines")
// Vertical Line Color
MOPColor = input.color (color.new(#787b86, 0), "", inline="MOP", group="Vertical Lines")
LOPColor = input.color (color.rgb(0,128,128,60), "", inline="LOP", group="Vertical Lines")
NYOPColor = input.color (color.rgb(0,128,128,60), "", inline="NYOP", group="Vertical Lines")
EOPColor = input.color (color.rgb(0,128,128,60), "", inline="EOP", group="Vertical Lines")
// Vertical LineStyle
Midnight_Open_LS = input.string ("Dotted", "", options= , inline="MOP", group="Vertical Lines")
london_Open_LS = input.string ("Solid", "", options= , inline="LOP", group="Vertical Lines")
NY_Open_LS = input.string ("Solid", "", options= , inline="NYOP", group="Vertical Lines")
Equities_Open_LS = input.string ("Solid", "", options= , inline="EOP", group="Vertical Lines")
// Vertical LineWidth
Midnight_Open_LW = input.string ("1px", "", options= , inline="MOP", group="Vertical Lines")
London_Open_LW = input.string ("1px", "", options= , inline="LOP", group="Vertical Lines")
NY_Open_LW = input.string ("1px", "", options= , inline="NYOP", group="Vertical Lines")
Equities_Open_LW = input.string ("1px", "", options= , inline="EOP", group="Vertical Lines")
//----------------------------------------------
// Opening Price Bool
ShowMOPP = input.bool (title="", defval=true, inline="MOPP", group="Opening Price Lines", tooltip="00:00 AM")
txt13 = input.string ("MIDNIGHT", title="", inline="MOPP", group="Opening Price Lines")
ShowNYOPP = input.bool (title="", defval=false, inline="NYOPP", group="Opening Price Lines", tooltip="08:30 AM")
txt17 = input.string ("NEW YORK", title="", inline="NYOPP", group="Opening Price Lines")
ShowEOPP = input.bool (title="", defval=false, inline="EOPP", group="Opening Price Lines", tooltip="09:30 AM")
txt18 = input.string ("EQUITIES", title="", inline="EOPP", group="Opening Price Lines")
ShowAFTPP = input.bool (title="", defval=false, inline="AFTOPP", group="Opening Price Lines", tooltip="01:30 PM")
txt1330 = input.string ("AFTERNOON", title="", inline="AFTOPP", group="Opening Price Lines")
// Opening Price Color
MOPColP = input.color (color.new(#787b86, 0), "", inline="MOPP", group="Opening Price Lines")
NYOPColP = input.color (color.new(#787b86, 0), "", inline="NYOPP", group="Opening Price Lines")
EOPColP = input.color (color.new(#787b86, 0), "", inline="EOPP", group="Opening Price Lines")
AFTOPColP = input.color (color.new(#787b86, 0), "", inline="AFTOPP", group="Opening Price Lines")
// Opening Price LineStyle
MOPLS = input.string ("Dotted", "", options= , inline="MOPP", group="Opening Price Lines")
NYOPLS = input.string ("Dotted", "", options= , inline="NYOPP", group="Opening Price Lines")
EOPLS = input.string ("Dotted", "", options= , inline="EOPP", group="Opening Price Lines")
AFTOPLS = input.string ("Dotted", "", options= , inline="AFTOPP", group="Opening Price Lines")
// Opening Price LineWidth
i_MOPLW = input.string ("1px", "", options= , inline="MOPP", group="Opening Price Lines")
i_NYOPLW = input.string ("1px", "", options= , inline="NYOPP", group="Opening Price Lines")
i_EOPLW = input.string ("1px", "", options= , inline="EOPP", group="Opening Price Lines")
i_AFTOPLW = input.string ("1px", "", options= , inline="AFTOPP", group="Opening Price Lines")
//----------------------------------------------
// W&M Bool
ShowWeekOpen = input.bool (defval=false, title="", tooltip="Draw Weekly Open Price Line", group="HTF Opening Price Lines", inline="WO")
showMonthOpen = input.bool (defval=false, title="", tooltip="Draw Monthly Open Price Line", group="HTF Opening Price Lines", inline="MO")
// W&M String
txt19 = input.string ("WEEKLY", title="", inline="WO", group="HTF Opening Price Lines")
txt20 = input.string ("MONTHLY", title="", inline="MO", group="HTF Opening Price Lines")
// W&M Color
i_WeekOpenCol = input.color (title="", defval=color.new(#787b86, 0), group="HTF Opening Price Lines", inline="WO")
i_MonthOpenCol = input.color (title="", tooltip="", defval=color.new(#787b86, 0), group="HTF Opening Price Lines", inline="MO")
// W&M LineStyle
WOLS = input.string ("Dotted", "", options= , inline="WO", group="HTF Opening Price Lines")
MOLS = input.string ("Dotted", "", options= , inline="MO", group="HTF Opening Price Lines")
// W&M LineWidth
i_WOPLW = input.string ("1px", "", options= , inline="WO", group="HTF Opening Price Lines")
i_MONPLW = input.string ("1px", "", options= , inline="MO", group="HTF Opening Price Lines")
//----------------------------------------------
// CBDR, ASIA & FLOUT
ShowCBDR = input.bool (true, "", inline='CBDR', group="CBDR, ASIA & FLOUT")
ShowASIA = input.bool (true, "", inline='ASIA', group="CBDR, ASIA & FLOUT")
ShowFLOUT = input.bool (false, "", inline='FLOUT', group="CBDR, ASIA & FLOUT")
// Strings
txt0 = input.string ("CBDR", title="", inline="CBDR", group="CBDR, ASIA & FLOUT", tooltip="16:00 to 20:00 SD Increments of 1")
txt1 = input.string ("ASIA", title="", inline="ASIA", group="CBDR, ASIA & FLOUT", tooltip="20:00 to 00:00 SD Increments of 1")
txt7 = input.string ("FLOUT", title="", inline="FLOUT", group="CBDR, ASIA & FLOUT", tooltip="16:00 to 00:00 SD Increments of 0.5")
// Color
CBDRBoxCol = input.color (color.new(#787b86, 0),"", inline='CBDR', group="CBDR, ASIA & FLOUT")
ASIABoxCol = input.color (color.new(#787b86, 0), "", inline='ASIA', group="CBDR, ASIA & FLOUT")
FLOUTBoxCol = input.color (color.new(#787b86, 0),"", inline='FLOUT', group="CBDR, ASIA & FLOUT")
// Extras
box_text_cbdr = input.bool (true, "Show Text", inline="CBDR", group="CBDR, ASIA & FLOUT")
box_text_cbdr_col = input.color (color.new(color.gray, 80), "", inline="CBDR", group="CBDR, ASIA & FLOUT")
bool_cbdr_dev = input.bool (true, "SD", inline="CBDR", group="CBDR, ASIA & FLOUT")
box_text_asia = input.bool (true, "Show Text", inline="ASIA", group="CBDR, ASIA & FLOUT")
box_text_asia_col = input.color (color.new(color.gray, 80), "", inline="ASIA", group="CBDR, ASIA & FLOUT")
bool_asia_dev = input.bool (true, "SD", inline="ASIA", group="CBDR, ASIA & FLOUT")
box_text_flout = input.bool (true, "Show Text", inline="FLOUT", group="CBDR, ASIA & FLOUT")
box_text_flout_col = input.color (color.new(color.gray, 80), "", inline="FLOUT", group="CBDR, ASIA & FLOUT")
bool_flout_dev = input.bool (true, "SD", inline="FLOUT", group="CBDR, ASIA & FLOUT")
// Table
// SD Lines
ShowDevLN = input.bool (title="", defval=true, inline="DEVLN", group="Standard Deviation", tooltip="Deviation Lines")
DEVLNTXT = input.string ("SD LINES", title="", inline="DEVLN", group="Standard Deviation")
DevLNCol = input.color (color.new(#787b86, 0), "", inline="DEVLN", group="Standard Deviation")
DEVLS = input.string ("Solid", "", options= , inline="DEVLN", group="Standard Deviation")
i_DEVLW = input.string ("1px", "", options= , inline="DEVLN", group="Standard Deviation")
DEVLSS = DEVLS=="Solid" ? line.style_solid : DEVLS == "Dotted" ? line.style_dotted : line.style_dashed
DEVLW = i_DEVLW=="1px" ? 1 : i_DEVLW == "2px" ? 2 : i_DEVLW == "3px" ? 3 : i_DEVLW == "4px" ? 4 : 5
ShowDev = input.bool (false, '', inline="DEV", group="Standard Deviation")
txt8 = input.string ("SD COUNT", title="", inline="DEV", group="Standard Deviation")
SDCountCol = input.color (color.new(#787b86, 0), "", inline="DEV", group="Standard Deviation")
DevInput = input.string ("2 SD", "", options= , inline="DEV", group="Standard Deviation")
DevDirection = input.string ("Both", "", options= , inline="DEV", group="Standard Deviation", tooltip="SD Count, NULL, SD Count, SD Direction")
DevCount = DevInput == "1 SD" ? 1 : DevInput == "2 SD" ? 2 : DevInput == "3 SD" ? 3 : 4
Auto_Select = input.bool (false, "", group="Standard Deviation", inline="AUTOSD", tooltip="Auto SD Selection | Charter Content, Range Table Might Bug Out On Mondays" )
txtSD = input.string ("AUTO SD", "", group="Standard Deviation", inline="AUTOSD")
Tab1txtCol = input.color (color.new(#808080, 0), "", inline='AUTOSD', group="Standard Deviation")
TabOptionShow = input.string ("Show Table", "", options= , inline="AUTOSD", group="Standard Deviation")
Stats = TabOptionShow == "Show Table" ? true : false
TabOption1 = input.string ("Top Right", "", options= , inline="AUTOSD", group="Standard Deviation")
tabinp1 = TabOption1 == "Top Left" ? position.top_left : TabOption1 == "Top Center" ? position.top_center : TabOption1 == "Top Right" ? position.top_right : TabOption1 == "Middle Left" ? position.middle_left : TabOption1 == "Middle Right" ? position.middle_right : TabOption1 == "Bottom Left" ? position.bottom_left : TabOption1 == "Bottom Center" ? position.bottom_center : position.bottom_right
L_Prof = true
CellBG = color.new(#131722, 100)
//----------------------------------------------
// Day Of Week & Labels
// Label Settings Inputs
ShowLabel = input.bool (true, title="", inline="Glabel", group="Day Of Week & Labels")
txt21 = input.string ("LABEL", title="", inline="Glabel", group="Day Of Week & Labels")
LabelColor = input.color (color.rgb(0,0,0,100), "", inline="Glabel", group="Day Of Week & Labels")
LabelSizeInput = input.string ("Normal", "", options= , inline="Glabel", group="Day Of Week & Labels")
Terminusinp = input.string ("Terminus @ Current Time +1hr", "", options = , inline="Glabel", group="Day Of Week & Labels", tooltip="Select Label Size & Color & Terminus Historical Price Lines needs to be toggled off for using Terminus")
ShowLabelText = input.bool (true, title="", inline="label", group="Day Of Week & Labels")
txt22 = input.string ("LABEL TEXT", title="", inline="label", group="Day Of Week & Labels")
LabelTextColor = input.color (color.new(#787b86, 0), title="", inline="label", group="Day Of Week & Labels")
LabelTextOptioninput = input.string ("Time", "", options= , inline="label", group="Day Of Week & Labels", tooltip="Choose Between Descriptive Text as Label or Time Show/Hide Prices on Labels")
ShowPricesBool = input.string ("Hide Prices", title="", options= , group="Day Of Week & Labels", inline="label")
ShowPrices = ShowPricesBool == "Show Prices" ? true : false
showDOW = input.bool (true, title="", inline="DOW", group="Day Of Week & Labels")
txt24 = input.string ("DAY OF WEEK", title="", inline="DOW", group="Day Of Week & Labels")
i_DOWCol = input.color (color.new(#787b86, 0), title="", inline="DOW", group="Day Of Week & Labels")
DOWTime = input.int (defval = 12, title="", inline="DOW", group="Day Of Week & Labels")
DOWLoc_inpt = input.string ("Bottom", "", options = , inline="DOW", group="Day Of Week & Labels", tooltip="DOW Color, Time Alignment, Vertical Location")
DOWLoc = DOWLoc_inpt == "Bottom" ? location.bottom : location.top
//----------------------------------------------
BIAS_M_Bool = input.bool (false, "", group="BIAS & NOTES PRECONFIG", inline="stats")
txt100 = input.string ("BIAS", title="", inline="stats", group="BIAS & NOTES PRECONFIG")
TableBG2 = color.new(#131722, 100)
Tab2txtCol = input.color (color.new(#787b86, 0), "", inline='stats', group="BIAS & NOTES PRECONFIG")
TabOption2 = input.string ("Bottom Right", "", options= , inline="stats", group="BIAS & NOTES PRECONFIG")
tabinp2 = TabOption2 == "Top Left" ? position.top_left : TabOption2 == "Top Center" ? position.top_center : TabOption2 == "Top Right" ? position.top_right : TabOption2 == "Middle Left" ? position.middle_left : TabOption2 == "Middle Right" ? position.middle_right : TabOption2 == "Bottom Left" ? position.bottom_left : TabOption2 == "Bottom Center" ? position.bottom_center : position.bottom_right
notesbool = false
NOTES_M_Bool = input.bool (true, "", group="BIAS & NOTES PRECONFIG", inline="stats2")
txt101 = input.string ("NOTES", title="", inline="stats2", group="BIAS & NOTES PRECONFIG")
Tab3txtCol = input.color (color.new(#787b86, 0), "", inline='stats2', group="BIAS & NOTES PRECONFIG")
TabOption3 = input.string ("Top Center", "", options= , inline="stats2", group="BIAS & NOTES PRECONFIG")
tabinp3 = TabOption3 == "Top Left" ? position.top_left : TabOption3 == "Top Center" ? position.top_center : TabOption3 == "Top Right" ? position.top_right : TabOption3 == "Middle Left" ? position.middle_left : TabOption3 == "Middle Right" ? position.middle_right : TabOption3 == "Bottom Left" ? position.bottom_left : TabOption3 == "Bottom Center" ? position.bottom_center : position.bottom_right
BIASbool1 = input.bool (true, '', inline="BIAS1", group="BIAS & NOTES")
txt52 = input.string ("DXY ", title="", inline="BIAS1", group="BIAS & NOTES")
BIASOption1 = input.string ("Unclear", options= , title="", inline="BIAS1", group="BIAS & NOTES")
BIASbool2 = input.bool (true, '', inline="BIAS2", group="BIAS & NOTES")
txt53 = input.string ("SPX ", title="", inline="BIAS2", group="BIAS & NOTES")
BIASOption2 = input.string ("Unclear", options= , title="", inline="BIAS2", group="BIAS & NOTES")
BIASbool3 = input.bool (true, '', inline="BIAS3", group="BIAS & NOTES")
txt54 = input.string ("DOW ", title="", inline="BIAS3", group="BIAS & NOTES")
BIASOption3 = input.string ("Unclear", options= , title="", inline="BIAS3", group="BIAS & NOTES")
BIASbool4 = input.bool (true, '', inline="BIAS4", group="BIAS & NOTES")
txt55 = input.string ("NAS ", title="", inline="BIAS4", group="BIAS & NOTES")
BIASOption4 = input.string ("Unclear", options= , title="", inline="BIAS4", group="BIAS & NOTES")
notes = input.text_area ("@smc_trading_br", "Notes", group = "BIAS & NOTES")
//--------------------END OF INPUTS--------------------//
// Pre-Def
DOM = (timeframe.multiplier <= inputMaxInterval) and (timeframe.isintraday)
newDay = ta.change(dayofweek)
newWeek = ta.change(weekofyear)
newMonth = ta.change(time("M"))
transparentcol = color.rgb(255,255,255,100)
LSVLC = color.rgb(255,255,255,100)
NYSVLC = color.rgb(255,255,255,100)
PMSVLC = color.rgb(255,255,255,100)
ASVLC = color.rgb(255,255,255,100)
LSVLS = "dotted"
NYSVLS = "dotted"
PMSVLS = "dotted"
ASVLS = "dotted"
// Functions
isToday = false
if year(timenow) == year(time) and month(timenow) == month(time) and dayofmonth(timenow) == dayofmonth(time)
isToday := true
// Current Week
thisweek = year(timenow) == year(time) and weekofyear(timenow) == weekofyear(time)
LastOneWeek = year(timenow) == year(time) and weekofyear(timenow-604800000) == weekofyear(time)
LastTwoWeek = year(timenow) == year(time) and weekofyear(timenow-1209600000) == weekofyear(time)
LastThreeWeek = year(timenow) == year(time) and weekofyear(timenow-1814400000) == weekofyear(time)
LastFourWeek = year(timenow) == year(time) and weekofyear(timenow-2419200000) == weekofyear(time)
Last4Weeks = false
if thisweek == true or LastOneWeek == true or LastTwoWeek == true or LastThreeWeek == true or LastFourWeek == true
Last4Weeks := true
// Function to draw Vertical Lines
vline(Start, Color, linestyle, LineWidth) =>
line.new(x1=Start, y1=low - ta.tr, x2=Start, y2=high + ta.tr, xloc=xloc.bar_time, extend=extend.both, color=Color, style=linestyle, width=LineWidth)
// Function to convert forex pips into whole numbers
atr = ta.atr(14)
toWhole(number) =>
if syminfo.type == "forex" // This method only works on forex pairs
_return = atr < 1.0 ? (number / syminfo.mintick) / 10 : number
_return := atr >= 1.0 and atr < 100.0 and syminfo.currency == "JPY" ? _return * 100 : _return
else
number
// Function for determining the Start of a Session (taken from the Pinescript manual: www.tradingview.com )
SessionBegins(sess) =>
t = time("", sess , Timezone)
DOM and (not barstate.isfirst) and na(t ) and not na(t)
// BarIn Session
BarInSession(sess) =>
time(timeframe.period, sess, Timezone) != 0
// Label Type Logic
var SFistrue = true
if LabelTextOptioninput == "Time"
SFistrue := true
else
SFistrue := false
// Session String to int
SeshStartHour(Session) =>
math.round(str.tonumber(str.substring(Session,0,2)))
SeshStartMins(Session) =>
math.round(str.tonumber(str.substring(Session,2,4)))
SeshEndHour(Session) =>
math.round(str.tonumber(str.substring(Session,5,7)))
SeshEndMins(Session) =>
math.round(str.tonumber(str.substring(Session,7,9)))
// Time periods
CBDR = "1600-2000:1234567"
ASIA = "2000-0000:1234567"
FLOUT = "1600-0000:1234567"
midsesh = "0000-1600:1234567"
cbdrOpenTime = timestamp (Timezone, year, month, dayofmonth, SeshStartHour(CBDR), SeshStartMins(CBDR), 00)
cbdrEndTime = timestamp (Timezone, year, month, dayofmonth, SeshEndHour(CBDR), SeshEndMins(CBDR), 00)
asiaOpenTime = timestamp (Timezone, year, month, dayofmonth, SeshStartHour(ASIA), SeshStartMins(ASIA), 00)
asiaEndTime = timestamp (Timezone, year, month, dayofmonth, SeshEndHour(ASIA), SeshEndMins(ASIA), 00)+86400000
floutOpenTime = timestamp (Timezone, year, month, dayofmonth, SeshStartHour(FLOUT), SeshStartMins(FLOUT), 00)
floutEndTime = timestamp (Timezone, year, month, dayofmonth, SeshEndHour(FLOUT), SeshEndMins(FLOUT), 00)+86400000
CBDRTime = time (timeframe.period, CBDR, Timezone)
ASIATime = time (timeframe.period, ASIA, Timezone)
FLOUTTime = time (timeframe.period, FLOUT, Timezone)
LabelOnlyToday = true
// Time Periods
LondonStartTime = timestamp(Timezone, year, month, dayofmonth, SeshStartHour(LDNsesh), SeshStartMins(LDNsesh), 00)
LondonEndTime = timestamp(Timezone, year, month, dayofmonth, SeshEndHour(LDNsesh), SeshEndMins(LDNsesh), 00)
NYStartTime = timestamp(Timezone, year, month, dayofmonth, SeshStartHour(NYsesh), SeshStartMins(NYsesh), 00)
NYEndTime = timestamp(Timezone, year, month, dayofmonth, SeshEndHour(NYsesh), SeshEndMins(NYsesh), 00)
LCStartTime = timestamp(Timezone, year, month, dayofmonth, SeshStartHour(LCsesh), SeshStartMins(LCsesh), 00)
LCEndTime = timestamp(Timezone, year, month, dayofmonth, SeshEndHour(LCsesh), SeshEndMins(LCsesh), 00)
PMStartTime = timestamp(Timezone, year, month, dayofmonth, SeshStartHour(PMsesh), SeshStartMins(PMsesh), 00)
PMEndTime = timestamp(Timezone, year, month, dayofmonth, SeshEndHour(PMsesh), SeshEndMins(PMsesh), 00)
AsianStartTime = timestamp(Timezone, year, month, dayofmonth, SeshStartHour(ASIA2sesh), SeshStartMins(ASIA2sesh), 00)
AsianEndTime = timestamp(Timezone, year, month, dayofmonth, SeshEndHour(ASIA2sesh), SeshEndMins(ASIA2sesh), 00)
FreeStartTime = timestamp(Timezone, year, month, dayofmonth, SeshStartHour(FreeSesh), SeshStartMins(FreeSesh), 00)
FreeEndTime = timestamp(Timezone, year, month, dayofmonth, SeshEndHour(FreeSesh), SeshEndMins(FreeSesh), 00)
MidnightOpenTime = timestamp(Timezone, year, month, dayofmonth, 0, 0, 00)
CLEANUPTIME = timestamp(Timezone, year, month, dayofmonth, 0, 0, 00) - 16200000
LondonOpenTime = timestamp(Timezone, year, month, dayofmonth, 3, 0, 00)
NYOpenTime = timestamp(Timezone, year, month, dayofmonth, 8, 30, 00)
EquitiesOpenTime = timestamp(Timezone, year, month, dayofmonth, 9, 30, 00)
AfternoonOpenTime = timestamp(Timezone, year, month, dayofmonth, 13, 30, 00)
tMidnight = time("1", "0000-0001:1234567", Timezone)
// Cleanup - Remove old drawing objects
Cleanup(days) =>
// Delete old drawing objects
// One day is 86400000 milliseconds
removal_timestamp = (CLEANUPTIME) - (days * 86400000) // Remove every drawing object older than the start of the Today's Midnight
a_allLines = line.all
a_allLabels = label.all
a_allboxes = box.all
// Remove old lines
if array.size(a_allLines) > 0
for i = 0 to array.size(a_allLines) - 1
line_x2 = line.get_x2(array.get(a_allLines, i))
if line_x2 < (removal_timestamp)
line.delete(array.get(a_allLines, i))
// Remove old labels
if array.size(a_allLabels) > 0
for i = 0 to array.size(a_allLabels) - 1
label_x = label.get_x(array.get(a_allLabels, i))
if label_x < removal_timestamp
label.delete(array.get(a_allLabels, i))
// Remove old boxes
if array.size(a_allboxes) > 0
for i = 0 to array.size(a_allboxes) - 1
box_x = box.get_right(array.get(a_allboxes, i))
if box_x < (removal_timestamp - 86400000)
box.delete(array.get(a_allboxes, i))
// End of Cleanup function
// Terminus Function
Terminus(Terminus_Inp)=>
if Terminus_Inp == "Terminus @ Current Time"
_return = timenow
else if Terminus_Inp == "Terminus @ Current Time +15min"
_return = timenow + 900000
else if Terminus_Inp == "Terminus @ Current Time +30min"
_return = timenow + 1800000
else if Terminus_Inp == "Terminus @ Current Time +45min"
_return = timenow + 2700000
else if Terminus_Inp == "Terminus @ Current Time +1hr"
_return = timenow + 3600000
else if Terminus_Inp == "Terminus @ Current Time +2hr"
_return = timenow + 7200000
else
_return = timenow + 10800000
// Linestyle Function
MNOPLS = Midnight_Open_LS=="Solid" ? line.style_solid : Midnight_Open_LS == "Dotted" ? line.style_dotted : line.style_dashed
LNOPLS = london_Open_LS=="Solid" ? line.style_solid : london_Open_LS == "Dotted" ? line.style_dotted : line.style_dashed
NWYOPLS = NY_Open_LS=="Solid" ? line.style_solid : NY_Open_LS == "Dotted" ? line.style_dotted : line.style_dashed
EQOPLS = Equities_Open_LS=="Solid" ? line.style_solid : Equities_Open_LS == "Dotted" ? line.style_dotted : line.style_dashed
MOPLSS = MOPLS=="Solid" ? line.style_solid : MOPLS == "Dotted" ? line.style_dotted : line.style_dashed
NYOPLSS = NYOPLS=="Solid" ? line.style_solid : NYOPLS == "Dotted" ? line.style_dotted : line.style_dashed
EOPLSS = EOPLS=="Solid" ? line.style_solid : EOPLS == "Dotted" ? line.style_dotted : line.style_dashed
AFTOPLSS = AFTOPLS=="Solid" ? line.style_solid : AFTOPLS == "Dotted" ? line.style_dotted : line.style_dashed
WeekOpenLS = WOLS=="Solid" ? line.style_solid : WOLS == "Dotted" ? line.style_dotted : line.style_dashed
MonthOpenLS = MOLS=="Solid" ? line.style_solid : MOLS == "Dotted" ? line.style_dotted : line.style_dashed
// Linewidth Function
MOPLW = Midnight_Open_LW=="1px" ? 1 : Midnight_Open_LW == "2px" ? 2 : Midnight_Open_LW == "3px" ? 3 : Midnight_Open_LW == "4px" ? 4 : 5
LOPLW = London_Open_LW=="1px" ? 1 : London_Open_LW == "2px" ? 2 : London_Open_LW == "3px" ? 3 : London_Open_LW == "4px" ? 4 : 5
NYOPLW = NY_Open_LW=="1px" ? 1 : NY_Open_LW == "2px" ? 2 : NY_Open_LW == "3px" ? 3 : NY_Open_LW == "4px" ? 4 : 5
EOPLW = Equities_Open_LW=="1px" ? 1 : Equities_Open_LW == "2px" ? 2 : Equities_Open_LW == "3px" ? 3 : Equities_Open_LW == "4px" ? 4 : 5
MOPPLW = i_MOPLW=="1px" ? 1 : i_MOPLW == "2px" ? 2 : i_MOPLW == "3px" ? 3 : i_MOPLW == "4px" ? 4 : 5
NYOPPLW = i_NYOPLW=="1px" ? 1 : i_NYOPLW == "2px" ? 2 : i_NYOPLW == "3px" ? 3 : i_NYOPLW == "4px" ? 4 : 5
EOPPLW = i_EOPLW=="1px" ? 1 : i_EOPLW == "2px" ? 2 : i_EOPLW == "3px" ? 3 : i_EOPLW == "4px" ? 4 : 5
AFTOPLW = i_AFTOPLW=="1px" ? 1 : i_AFTOPLW == "2px" ? 2 : i_AFTOPLW == "3px" ? 3 : i_AFTOPLW == "4px" ? 4 : 5
WEEKOPPLW = i_WOPLW=="1px" ? 1 : i_WOPLW == "2px" ? 2 : i_WOPLW == "3px" ? 3 : i_WOPLW == "4px" ? 4 : 5
MONTHOPPLW = i_MONPLW=="1px" ? 1 : i_MONPLW == "2px" ? 2 : i_MONPLW == "3px" ? 3 : i_MONPLW == "4px" ? 4 : 5
// Label Size Function
LabelSize =LabelSizeInput=="Auto" ? size.auto : LabelSizeInput=="Tiny" ? size.tiny : LabelSizeInput=="Small" ? size.small : LabelSizeInput=="Normal" ? size.normal : LabelSizeInput=="Large" ? size.large : size.huge
// Creating Variables
var London_Start_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=LSVLC, width=1)
var London_End_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=LSVLC, width=1)
var LondonFill = linefill.new(London_Start_Vline, London_End_Vline, LSFC)
var NY_Start_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=NYSVLC, width=1)
var NY_End_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=NYSVLC, width=1)
var NYFill = linefill.new(NY_Start_Vline, NY_End_Vline, NYSFC)
var LC_Start_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=NYSVLC, width=1)
var LC_End_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=NYSVLC, width=1)
var LCFill = linefill.new(LC_Start_Vline, LC_End_Vline, LCSFC)
var PM_Start_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=PMSVLC, width=1)
var PM_End_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=PMSVLC, width=1)
var PMFill = linefill.new(PM_Start_Vline, PM_End_Vline, PMSFC)
var Asian_Start_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=ASVLC, width=1)
var Asian_End_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=ASVLC, width=1)
var AsianFill = linefill.new(Asian_Start_Vline, Asian_End_Vline, ASFC)
var Free_Start_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=ASVLC, width=1)
var Free_End_Vline = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=ASVLC, width=1)
var FreeFill = linefill.new(Free_Start_Vline, Free_End_Vline, FSFC)
var Midnight_Open = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=MOPColor, width=1)
var London_Open = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=LOPColor, width=1)
var NY_Open = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=NYOPColor, width=1)
var Equities_Open = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=EOPColor, width=1)
// When a New Day Starts, Start Drawing all lines
if newDay and dayofweek != dayofweek.sunday
// London Session
if (ShowLondon and DOM)
if ShowTSO
line.delete(London_Start_Vline )
line.delete(London_End_Vline )
linefill.delete(LondonFill )
London_Start_Vline := vline(LondonStartTime,transparentcol, line.style_solid, 1)
London_End_Vline := vline(LondonEndTime, transparentcol, line.style_solid, 1)
if ShowSFill
LondonFill := linefill.new(London_Start_Vline, London_End_Vline, LSFC)
// New York Session
if (ShowNY and DOM)
if ShowTSO
line.delete(NY_Start_Vline )
line.delete(NY_End_Vline )
linefill.delete(NYFill )
NY_Start_Vline := vline(NYStartTime, transparentcol, line.style_solid, 1)
NY_End_Vline := vline(NYEndTime, transparentcol, line.style_solid, 1)
if ShowSFill
NYFill := linefill.new(NY_Start_Vline, NY_End_Vline, NYSFC)
// London Close
if (ShowLC and DOM)
if ShowTSO
line.delete(LC_End_Vline )
linefill.delete(LCFill )
LC_Start_Vline := vline(LCStartTime, transparentcol, line.style_solid, 1)
LC_End_Vline := vline(LCEndTime, transparentcol, line.style_solid, 1)
if ShowSFill
LCFill := linefill.new(LC_Start_Vline, LC_End_Vline, LCSFC)
// PM Session
if (ShowPM and DOM)
if ShowTSO
line.delete(PM_Start_Vline )
line.delete(PM_End_Vline )
linefill.delete(PMFill )
PM_Start_Vline := vline(PMStartTime, transparentcol, line.style_solid, 1)
PM_End_Vline := vline(PMEndTime, transparentcol, line.style_solid, 1)
if ShowSFill
PMFill := linefill.new(PM_Start_Vline, PM_End_Vline, PMSFC)
// Asian Session
if (ShowAsian and DOM)
if ShowTSO
line.delete(Asian_Start_Vline )
line.delete(Asian_End_Vline )
linefill.delete(AsianFill )
Asian_Start_Vline := vline(AsianStartTime, transparentcol, line.style_solid, 1)
Asian_End_Vline := vline(AsianEndTime, transparentcol, line.style_solid, 1)
// if dayofweek == dayofweek.friday
// // line.delete(Asian_Start_Vline)
// // line.delete(Asian_End_Vline)
// Asian_Start_Vline := vline(MidnightOpenTime+244800000, transparentcol, line.style_solid, 1)
// Asian_End_Vline := vline(MidnightOpenTime+259200000, transparentcol, line.style_solid, 1)
if ShowSFill
AsianFill := linefill.new(Asian_Start_Vline, Asian_End_Vline, ASFC)
// Free Session
if (ShowFreeSesh and DOM)
if ShowTSO
line.delete(Free_Start_Vline )
line.delete(Free_End_Vline )
linefill.delete(FreeFill )
Free_Start_Vline := vline(FreeStartTime, transparentcol, line.style_solid, 1)
Free_End_Vline := vline(FreeEndTime, transparentcol, line.style_solid, 1)
if ShowSFill
FreeFill := linefill.new(Free_Start_Vline, Free_End_Vline, FSFC)
// Midnight Opening Price
if (ShowMOP and DOM)
if MOLHist == false
line.delete(Midnight_Open )
Midnight_Open := vline(MidnightOpenTime, MOPColor, MNOPLS, MOPLW)
// London Opening Price
if (ShowLOP and DOM)
if ShowTSO
line.delete(London_Open )
London_Open := vline(LondonOpenTime, LOPColor, LNOPLS, LOPLW)
// New York Opening Price
if (ShowNYOP and DOM)
if ShowTSO
line.delete(NY_Open )
NY_Open := vline(NYOpenTime, NYOPColor, NWYOPLS, NYOPLW)
// Equities Opening Price
if (ShowEOP and DOM)
if ShowTSO
line.delete(Equities_Open )
Equities_Open := vline(EquitiesOpenTime, EOPColor, EQOPLS, EOPLW)
// Variables
var label MOPLB = na
var line MOPLN = na
var label NYOPLB = na
var line NYOPLN = na
var label EOPLB = na
var line EOPLN = na
var line AFTLN = na
var label AFTLB = na
// New York Midnight Open Price line
var openMidnight = 0.0
if tMidnight
if not tMidnight
openMidnight := open
else
openMidnight := math.max(open, openMidnight)
if (ShowMOPP and (openMidnight != openMidnight ) and DOM and barstate.isconfirmed)
label.delete(MOPLB )
if ShowMOPL == false
line.delete(MOPLN )
MOPLN := line.new(x1=tMidnight, y1=openMidnight, x2=tMidnight+86400000, xloc=xloc.bar_time, y2=openMidnight, color=MOPColP, style=MOPLSS, width=MOPPLW)
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
line.set_x2(MOPLN, tMidnight+259200000)
if ShowLabel
MOPLB := label.new(x=tMidnight+86400000, y=openMidnight, xloc=xloc.bar_time, color=LabelColor, textcolor=MOPColP, style=label.style_label_left, size=LabelSize, tooltip="Midnight Opening Price")
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
label.set_x(MOPLB, tMidnight+259200000)
if ShowLabelText
if SFistrue
if ShowPrices == true
label.set_text(MOPLB, " 00:00 | " + str.tostring(open))
else
label.set_text(MOPLB, " 00:00 ")
label.set_tooltip(MOPLB, "Midnight Opening Price")
else
if ShowPrices == true
label.set_text(MOPLB, " Midnight Opening Price | " + str.tostring(open))
else
label.set_text(MOPLB, " Midnight Opening Price ")
label.set_tooltip(MOPLB, "")
label.set_textcolor(MOPLB, LabelTextColor)
label.set_size(MOPLB,LabelSize)
if time > PMEndTime and time < (MidnightOpenTime + 86400000)
line.delete(MOPLN )
if Terminusinp != "Terminus @ Next Midnight" and ShowMOPL == false
line.set_x2(MOPLN, Terminus(Terminusinp))
label.set_x(MOPLB, Terminus(Terminusinp))
// New York Opening Price Line
if (ShowNYOPP and (time == NYOpenTime) and DOM)
label.delete(NYOPLB )
if ShowPrev == false
line.delete(NYOPLN )
NYOPLN := line.new(x1=NYOpenTime, y1=open, x2=NYOpenTime+55800000, xloc=xloc.bar_time, y2=open, color=NYOPColP, style=NYOPLSS, width=NYOPPLW)
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
line.set_x2(NYOPLN, NYOpenTime+228600000)
if ShowLabel
NYOPLB := label.new(x=NYOpenTime+55800000, y=open, xloc=xloc.bar_time, color=LabelColor, textcolor=NYOPColP, style=label.style_label_left, size=LabelSize, tooltip="New York Opening Price")
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
label.set_x(NYOPLB, NYOpenTime+228600000)
if ShowLabelText
if SFistrue
if ShowPrices == true
label.set_text(NYOPLB, " 08:30 | " + str.tostring(open))
else
label.set_text(NYOPLB, " 08:30 ")
label.set_tooltip(NYOPLB, "New York Opening Price")
else
if ShowPrices == true
label.set_text(NYOPLB, " New York Opening Price | " + str.tostring(open))
else
label.set_text(NYOPLB, " New York Opening Price ")
label.set_tooltip(NYOPLB, "")
label.set_textcolor(NYOPLB, LabelTextColor)
label.set_size(NYOPLB,LabelSize)
if Terminusinp != "Terminus @ Next Midnight" and ShowPrev == false
line.set_x2(NYOPLN, Terminus(Terminusinp))
label.set_x(NYOPLB, Terminus(Terminusinp))
// Equities Opening Price Line
if (ShowEOPP and (time == EquitiesOpenTime) and DOM)
label.delete(EOPLB )
if ShowPrev == false
line.delete(EOPLN )
EOPLN := line.new(x1=EquitiesOpenTime, y1=open, x2=EquitiesOpenTime+52200000, xloc=xloc.bar_time, y2=open, color=EOPColP, style=EOPLSS, width=EOPPLW)
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
line.set_x2(EOPLN, EquitiesOpenTime+225000000)
if ShowLabel
EOPLB := label.new(x=EquitiesOpenTime+52200000, y=open, xloc=xloc.bar_time, color=LabelColor, textcolor=EOPColP, style=label.style_label_left, size=LabelSize, tooltip="Equities Opening Price")
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
label.set_x(EOPLB, EquitiesOpenTime+225000000)
if ShowLabelText
if SFistrue
if ShowPrices == true
label.set_text(EOPLB, " 09:30 | " + str.tostring(open))
else
label.set_text(EOPLB, " 09:30 ")
label.set_tooltip(EOPLB, "Equities Opening Price")
else
if ShowPrices == true
label.set_text(EOPLB, " Equities Opening Price | " + str.tostring(open))
else
label.set_text(EOPLB, " Equities Opening Price ")
label.set_tooltip(EOPLB, "")
label.set_textcolor(EOPLB, LabelTextColor)
label.set_size(EOPLB,LabelSize)
if Terminusinp != "Terminus @ Next Midnight" and ShowPrev == false
line.set_x2(EOPLN, Terminus(Terminusinp))
label.set_x(EOPLB, Terminus(Terminusinp))
// Afternoon Opening Price Line
if (ShowAFTPP and (time == AfternoonOpenTime) and DOM)
label.delete(AFTLB )
if ShowPrev == false
line.delete(AFTLN )
AFTLN := line.new(x1=AfternoonOpenTime, y1=open, x2=EquitiesOpenTime+52200000, xloc=xloc.bar_time, y2=open, color=AFTOPColP, style=AFTOPLSS, width=AFTOPLW)
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
line.set_x2(AFTLN, EquitiesOpenTime+225000000)
if ShowLabel
AFTLB := label.new(x=EquitiesOpenTime+52200000, y=open, xloc=xloc.bar_time, color=LabelColor, textcolor=AFTOPColP, style=label.style_label_left, size=LabelSize, tooltip="Equities Opening Price")
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
label.set_x(AFTLB, EquitiesOpenTime+225000000)
if ShowLabelText
if SFistrue
if ShowPrices == true
label.set_text(AFTLB, " 01:30 | " + str.tostring(open))
else
label.set_text(AFTLB, " 01:30 ")
label.set_tooltip(AFTLB, " Afternoon Opening Price")
else
if ShowPrices == true
label.set_text(AFTLB, " Afternoon Opening Price | " + str.tostring(open))
else
label.set_text(AFTLB, " Afternoon Opening Price ")
label.set_tooltip(AFTLB, "")
label.set_textcolor(AFTLB, LabelTextColor)
label.set_size(AFTLB,LabelSize)
if Terminusinp != "Terminus @ Next Midnight" and ShowPrev == false
line.set_x2(AFTLN, Terminus(Terminusinp))
label.set_x(AFTLB, Terminus(Terminusinp))
// HTF Variables
var Weekly_open = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=i_WeekOpenCol, style=WeekOpenLS, width=1)
var Weekly_openlbl = label.new(x=na, y=na, xloc=xloc.bar_time, color=LabelColor, textcolor=LabelTextColor, style=label.style_label_left, size=LabelSize)
var WeeklyOpenTime = time
var Monthly_open = line.new(x1=na, y1=na, x2=na, xloc=xloc.bar_time, y2=close, color=i_MonthOpenCol, style=MonthOpenLS, width=1)
var Monthly_openlbl = label.new(x=na, y=na, xloc=xloc.bar_time, color=LabelColor, textcolor=LabelTextColor, style=label.style_label_left, size=LabelSize)
var MonthlyOpenTime = time
// Get HTF Price levels
WeeklyOpen = request.security(syminfo.tickerid, "W", open, lookahead = barmerge.lookahead_on)
MonthlyOpen = request.security(syminfo.tickerid, "M", open, lookahead = barmerge.lookahead_on)
// Weekly Open
if newWeek
WeeklyOpenTime := time
if ShowWeekOpen and newDay and Last4Weeks
label.delete(Weekly_openlbl )
line.delete(Weekly_open )
// if ShowPrev == false
// line.delete(Weekly_open )
Weekly_open:= line.new(x1=WeeklyOpenTime-25200000, y1=WeeklyOpen, x2=EquitiesOpenTime+52200000, xloc=xloc.bar_time, y2=WeeklyOpen, color=i_WeekOpenCol, style=WeekOpenLS, width=WEEKOPPLW)
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
line.set_x2(Weekly_open, EquitiesOpenTime+225000000)
if ShowLabel
Weekly_openlbl := label.new(x=EquitiesOpenTime+52200000, y=WeeklyOpen, xloc=xloc.bar_time, color=LabelColor, textcolor=LabelTextColor, style=label.style_label_left, size=LabelSize, tooltip="Weekly Open: " + str.tostring(WeeklyOpen))
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
label.set_x(Weekly_openlbl, EquitiesOpenTime+225000000)
if ShowLabelText
if SFistrue
if ShowPrices == true
label.set_text(Weekly_openlbl," W.O. | " + str.tostring(WeeklyOpen))
else
label.set_text(Weekly_openlbl," W.O. ")
label.set_tooltip(Weekly_openlbl, " Weekly Opening Price ")
else
if ShowPrices == true
label.set_text(Weekly_openlbl," Weekly Open | " + str.tostring(WeeklyOpen))
else
label.set_text(Weekly_openlbl," Weekly Open ")
label.set_tooltip(Weekly_openlbl, "")
label.set_textcolor(Weekly_openlbl, LabelTextColor)
label.set_size(Weekly_openlbl, LabelSize)
if timeframe.multiplier > 60
line.set_x2(Weekly_open, AsianEndTime + 232000000)
label.set_x(Weekly_openlbl, AsianEndTime + 232000000)
if timeframe.period == "D"
line.set_x2(Weekly_open, AsianEndTime + 832000000)
label.set_x(Weekly_openlbl, AsianEndTime + 832000000)
if timeframe.period == "M"
line.delete(Weekly_open)
label.delete(Weekly_openlbl)
if Terminusinp != "Terminus @ Next Midnight" and DOM
line.set_x2(Weekly_open, Terminus(Terminusinp))
label.set_x(Weekly_openlbl, Terminus(Terminusinp))
// Monthly Open
if newMonth
MonthlyOpenTime := time
if showMonthOpen and newDay
line.delete(Monthly_open )
label.delete(Monthly_openlbl )
Monthly_open:= line.new(x1=MonthlyOpenTime, y1=MonthlyOpen, x2=AsianEndTime, xloc=xloc.bar_time, y2=MonthlyOpen, color=i_MonthOpenCol, style=MonthOpenLS, width=MONTHOPPLW)
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
line.set_x2(Monthly_open, EquitiesOpenTime+225000000)
if ShowLabel
Monthly_openlbl := label.new(x=AsianEndTime, y=MonthlyOpen, xloc=xloc.bar_time, color=LabelColor, textcolor=LabelTextColor, style=label.style_label_left, size=LabelSize, tooltip="Monthly Open: " + str.tostring(MonthlyOpen))
if dayofweek == dayofweek.friday and syminfo.type != "crypto"
label.set_x(Monthly_openlbl, EquitiesOpenTime+225000000)
if ShowLabelText
if SFistrue
if ShowPrices == true
label.set_text(Monthly_openlbl," M.O. | " + str.tostring(MonthlyOpen))
else
label.set_text(Monthly_openlbl," M.O. ")
label.set_tooltip(Monthly_openlbl, " Monthly Opening Price ")
else
if ShowPrices == true
label.set_text(Monthly_openlbl, " Monthly Open | " + str.tostring(MonthlyOpen))
else
label.set_text(Monthly_openlbl, " Monthly Open ")
label.set_tooltip(Monthly_openlbl, "")
label.set_textcolor(Monthly_openlbl, LabelTextColor)
label.set_size(Monthly_openlbl, LabelSize)
if timeframe.multiplier > 60
line.set_x2(Monthly_open, AsianEndTime + 232000000)
label.set_x(Monthly_openlbl, AsianEndTime + 232000000)
if timeframe.period == "D"
line.set_x2(Monthly_open, AsianEndTime + 832000000)
label.set_x(Monthly_openlbl, AsianEndTime + 832000000)
if timeframe.period == "W"
line.set_x2(Monthly_open, AsianEndTime + 2592000000)
label.set_x(Monthly_openlbl, AsianEndTime + 2592000000)
if timeframe.period == "M"
line.delete(Monthly_open)
label.delete(Monthly_openlbl)
if Terminusinp != "Terminus @ Next Midnight" and DOM
line.set_x2(Monthly_open, Terminus(Terminusinp))
label.set_x(Monthly_openlbl, Terminus(Terminusinp))
// CBDR Stuff
var float cbdr_hi = na
var float cbdr_lo = na
var float cbdr_diff = na
var box cbdrbox = na
var line cbdr_hi_line = na
var line cbdr_lo_line = na
var line dev01negline = na
var line dev02negline = na
var line dev03negline = na
var line dev04negline = na
var line dev01posline = na
var line dev02posline = na
var line dev03posline = na
var line dev04posline = na
if SessionBegins(CBDR) and DOM
cbdr_hi := high
cbdr_lo := low
cbdr_diff := cbdr_hi - cbdr_lo
if ShowTSO
box.delete(cbdrbox )
line.delete(dev01posline )
line.delete(dev01negline )
line.delete(dev02posline )
line.delete(dev02negline )
line.delete(dev03posline )
line.delete(dev03negline )
line.delete(dev04posline )
line.delete(dev04negline )
if ShowCBDR
cbdrbox := box.new(cbdrOpenTime, cbdr_hi, cbdrEndTime, cbdr_lo, color.new(CBDRBoxCol,90), 1, line.style_solid, extend.none, xloc.bar_time, color.new(CBDRBoxCol,90), txt0, size.auto, color.new(box_text_cbdr_col,80), text_wrap=text.wrap_auto)
if dayofweek == dayofweek.friday
box.set_right(cbdrbox, cbdrOpenTime+187200000)
line.set_x2(cbdr_hi_line, cbdrOpenTime+187200000)
line.set_x2(cbdr_lo_line, cbdrOpenTime+187200000)
if box_text_cbdr == false
box.set_text(cbdrbox, "")
if ShowDev and ShowCBDR and bool_cbdr_dev
for i = 1 to DevCount by 1
if i == 1
dev01posline := line.new(cbdrOpenTime, cbdr_hi + cbdr_diff * i, cbdrEndTime, cbdr_hi + cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev01negline := line.new(cbdrOpenTime, cbdr_hi - cbdr_diff * i, cbdrEndTime, cbdr_lo - cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev01posline, cbdrOpenTime+187200000)
line.set_x2(dev01negline, cbdrOpenTime+187200000)
if i == 2
dev02posline := line.new(cbdrOpenTime, cbdr_hi + cbdr_diff * i, cbdrEndTime, cbdr_lo + cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev02negline := line.new(cbdrOpenTime, cbdr_hi - cbdr_diff * i, cbdrEndTime, cbdr_lo - cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev02posline, cbdrOpenTime+187200000)
line.set_x2(dev02negline, cbdrOpenTime+187200000)
if i == 3
dev03posline := line.new(cbdrOpenTime, cbdr_hi + cbdr_diff * i, cbdrEndTime, cbdr_lo + cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev03negline := line.new(cbdrOpenTime, cbdr_hi - cbdr_diff * i, cbdrEndTime, cbdr_lo - cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev03posline, cbdrOpenTime+187200000)
line.set_x2(dev03negline, cbdrOpenTime+187200000)
if i == 4
dev04posline := line.new(cbdrOpenTime, cbdr_hi + cbdr_diff * i, cbdrEndTime, cbdr_lo + cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev04negline := line.new(cbdrOpenTime, cbdr_hi - cbdr_diff * i, cbdrEndTime, cbdr_lo - cbdr_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev04posline, cbdrOpenTime+187200000)
line.set_x2(dev04negline, cbdrOpenTime+187200000)
else if CBDRTime
cbdr_hi := math.max(high, cbdr_hi)
cbdr_lo := math.min(low, cbdr_lo)
cbdr_diff := cbdr_hi - cbdr_lo
for i = 1 to DevCount by 1
if i == 1 and ShowDev
line.set_y1(dev01posline, cbdr_hi + cbdr_diff * i)
line.set_y2(dev01posline, cbdr_hi + cbdr_diff * i)
line.set_y1(dev01negline, cbdr_lo - cbdr_diff * i)
line.set_y2(dev01negline, cbdr_lo - cbdr_diff * i)
if i == 2 and ShowDev
line.set_y1(dev02posline, cbdr_hi + cbdr_diff * i)
line.set_y2(dev02posline, cbdr_hi + cbdr_diff * i)
line.set_y1(dev02negline, cbdr_lo - cbdr_diff * i)
line.set_y2(dev02negline, cbdr_lo - cbdr_diff * i)
if i == 3 and ShowDev
line.set_y1(dev03posline, cbdr_hi + cbdr_diff * i)
line.set_y2(dev03posline, cbdr_hi + cbdr_diff * i)
line.set_y1(dev03negline, cbdr_lo - cbdr_diff * i)
line.set_y2(dev03negline, cbdr_lo - cbdr_diff * i)
if i == 4 and ShowDev
line.set_y1(dev04posline, cbdr_hi + cbdr_diff * i)
line.set_y2(dev04posline, cbdr_hi + cbdr_diff * i)
line.set_y1(dev04negline, cbdr_lo - cbdr_diff * i)
line.set_y2(dev04negline, cbdr_lo - cbdr_diff * i)
if (cbdr_hi > cbdr_hi )
if ShowCBDR
box.set_top(cbdrbox, cbdr_hi)
if (cbdr_lo < cbdr_lo )
if ShowCBDR
box.set_bottom(cbdrbox, cbdr_lo)
if DevDirection == "Upside Only"
line.delete(dev01negline)
line.delete(dev02negline)
line.delete(dev03negline)
line.delete(dev04negline)
else if DevDirection == "Downside Only"
line.delete(dev01posline)
line.delete(dev02posline)
line.delete(dev03posline)
line.delete(dev04posline)
// ASIA Stuff
var float asia_hi = na
var float asia_lo = na
var float asia_diff = na
var box asia_box = na
var line asia_hi_line = na
var line asia_lo_line = na
var line dev01negline_asia = na
var line dev02negline_asia = na
var line dev03negline_asia = na
var line dev04negline_asia = na
var line dev01posline_asia = na
var line dev02posline_asia = na
var line dev03posline_asia = na
var line dev04posline_asia = na
if SessionBegins(ASIA) and DOM
asia_hi := high
asia_lo := low
asia_diff := asia_hi - asia_lo
if ShowTSO
box.delete(asia_box )
line.delete(dev01posline_asia )
line.delete(dev01negline_asia )
line.delete(dev02posline_asia )
line.delete(dev02negline_asia )
line.delete(dev03posline_asia )
line.delete(dev03negline_asia )
line.delete(dev04posline_asia )
line.delete(dev04negline_asia )
if ShowASIA
asia_box := box.new(asiaOpenTime, asia_hi, asiaEndTime, asia_lo, color.new(ASIABoxCol,90), 1, line.style_solid, extend.none, xloc.bar_time, color.new(ASIABoxCol,90), txt1, size.auto, color.new(box_text_asia_col,80), text_wrap=text.wrap_auto)
if box_text_asia == false
box.set_text(asia_box, "")
if ShowDev and ShowASIA and bool_asia_dev
for i = 1 to DevCount by 1
if i == 1
dev01posline_asia := line.new(asiaOpenTime, asia_hi + asia_diff * i, asiaEndTime, asia_hi + asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev01negline_asia := line.new(asiaOpenTime, asia_hi - asia_diff * i, asiaEndTime, asia_lo - asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if i == 2
dev02posline_asia := line.new(asiaOpenTime, asia_hi + asia_diff * i, asiaEndTime, asia_lo + asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev02negline_asia := line.new(asiaOpenTime, asia_hi - asia_diff * i, asiaEndTime, asia_lo - asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if i == 3
dev03posline_asia := line.new(asiaOpenTime, asia_hi + asia_diff * i, asiaEndTime, asia_lo + asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev03negline_asia := line.new(asiaOpenTime, asia_hi - asia_diff * i, asiaEndTime, asia_lo - asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if i == 4
dev04posline_asia := line.new(asiaOpenTime, asia_hi + asia_diff * i, asiaEndTime, asia_lo + asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev04negline_asia := line.new(asiaOpenTime, asia_hi - asia_diff * i, asiaEndTime, asia_lo - asia_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
else if ASIATime
asia_hi := math.max(high, asia_hi)
asia_lo := math.min(low, asia_lo)
asia_diff := asia_hi - asia_lo
for i = 1 to DevCount by 1
if i == 1 and ShowDev
line.set_y1(dev01posline_asia, asia_hi + asia_diff * i)
line.set_y2(dev01posline_asia, asia_hi + asia_diff * i)
line.set_y1(dev01negline_asia, asia_lo - asia_diff * i)
line.set_y2(dev01negline_asia, asia_lo - asia_diff * i)
if i == 2 and ShowDev
line.set_y1(dev02posline_asia, asia_hi + asia_diff * i)
line.set_y2(dev02posline_asia, asia_hi + asia_diff * i)
line.set_y1(dev02negline_asia, asia_lo - asia_diff * i)
line.set_y2(dev02negline_asia, asia_lo - asia_diff * i)
if i == 3 and ShowDev
line.set_y1(dev03posline_asia, asia_hi + asia_diff * i)
line.set_y2(dev03posline_asia, asia_hi + asia_diff * i)
line.set_y1(dev03negline_asia, asia_lo - asia_diff * i)
line.set_y2(dev03negline_asia, asia_lo - asia_diff * i)
if i == 4 and ShowDev
line.set_y1(dev04posline_asia, asia_hi + asia_diff * i)
line.set_y2(dev04posline_asia, asia_hi + asia_diff * i)
line.set_y1(dev04negline_asia, asia_lo - asia_diff * i)
line.set_y2(dev04negline_asia, asia_lo - asia_diff * i)
if (asia_hi > asia_hi )
box.set_top(asia_box, asia_hi)
if (asia_lo < asia_lo )
box.set_bottom(asia_box, asia_lo)
if DevDirection == "Upside Only"
line.delete(dev01negline_asia)
line.delete(dev02negline_asia)
line.delete(dev03negline_asia)
line.delete(dev04negline_asia)
else if DevDirection == "Downside Only"
line.delete(dev01posline_asia)
line.delete(dev02posline_asia)
line.delete(dev03posline_asia)
line.delete(dev04posline_asia)
// FLOUT Stuff
var float flout_hi = na
var float flout_lo = na
var float flout_diff = na
var box floutbox = na
var line flout_hi_line = na
var line flout_lo_line = na
var line dev01negline_flout = na
var line dev02negline_flout = na
var line dev03negline_flout = na
var line dev04negline_flout = na
var line dev01posline_flout = na
var line dev02posline_flout = na
var line dev03posline_flout = na
var line dev04posline_flout = na
if SessionBegins(FLOUT) and DOM
flout_hi := high
flout_lo := low
flout_diff := flout_hi - flout_lo
if ShowTSO
box.delete(floutbox )
line.delete(dev01posline_flout )
line.delete(dev01negline_flout )
line.delete(dev02posline_flout )
line.delete(dev02negline_flout )
line.delete(dev03posline_flout )
line.delete(dev03negline_flout )
line.delete(dev04posline_flout )
line.delete(dev04negline_flout )
if ShowFLOUT
floutbox := box.new(floutOpenTime, flout_hi, floutEndTime, flout_lo, color.new(FLOUTBoxCol,90), 1, line.style_solid, extend.none, xloc.bar_time, color.new(FLOUTBoxCol,90), txt7, size.auto, color.new(box_text_flout_col,80), text_wrap=text.wrap_auto)
if dayofweek == dayofweek.friday
box.set_right(floutbox, floutOpenTime+201600000)
line.set_x2(flout_hi_line, floutOpenTime+201600000)
line.set_x2(flout_lo_line, floutOpenTime+201600000)
if box_text_cbdr == false
box.set_text(floutbox, "")
if ShowDev and ShowFLOUT and bool_flout_dev
for i = 0.5 to DevCount by 0.5
if i == 0.5
dev01posline_flout := line.new(floutOpenTime, flout_hi + flout_diff * i, floutEndTime, flout_hi + flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev01negline_flout := line.new(floutOpenTime, flout_hi - flout_diff * i, floutEndTime, flout_lo - flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev01posline_flout, floutOpenTime+201600000)
line.set_x2(dev01negline_flout, floutOpenTime+201600000)
if i == 1
dev02posline_flout := line.new(floutOpenTime, flout_hi + flout_diff * i, floutEndTime, flout_lo + flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev02negline_flout := line.new(floutOpenTime, flout_hi - flout_diff * i, floutEndTime, flout_lo - flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev02posline_flout, floutOpenTime+201600000)
line.set_x2(dev02negline_flout, floutOpenTime+201600000)
if i == 1.5
dev03posline_flout := line.new(floutOpenTime, flout_hi + flout_diff * i, floutEndTime, flout_lo + flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev03negline_flout := line.new(floutOpenTime, flout_hi - flout_diff * i, floutEndTime, flout_lo - flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev03posline_flout, floutOpenTime+201600000)
line.set_x2(dev03negline_flout, floutOpenTime+201600000)
if i == 2
dev04posline_flout := line.new(floutOpenTime, flout_hi + flout_diff * i, floutEndTime, flout_lo + flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
dev04negline_flout := line.new(floutOpenTime, flout_hi - flout_diff * i, floutEndTime, flout_lo - flout_diff * i, xloc=xloc.bar_time, color=DevLNCol, style=DEVLSS, width=DEVLW)
if dayofweek == dayofweek.friday
line.set_x2(dev04posline_flout, floutOpenTime+201600000)
line.set_x2(dev04negline_flout, floutOpenTime+201600000)
else if FLOUTTime
flout_hi := math.max(high, flout_hi)
flout_lo := math.min(low, flout_lo)
flout_diff := flout_hi - flout_lo
for i = 0.5 to DevCount by 0.5
if i == 0.5 and ShowDev
line.set_y1(dev01posline_flout, flout_hi + flout_diff * i)
line.set_y2(dev01posline_flout, flout_hi + flout_diff * i)
line.set_y1(dev01negline_flout, flout_lo - flout_diff * i)
line.set_y2(dev01negline_flout, flout_lo - flout_diff * i)
if i == 1 and ShowDev
line.set_y1(dev02posline_flout, flout_hi + flout_diff * i)
line.set_y
Multi-Timeframe SMTSummery
The Multi-Timeframe SMT indicator is designed to identify and visualize Higher Timeframe (HTF) data on a Lower Timeframe (LTF) chart, allowing traders to see the broader market context without changing their current chart's resolution. It accurately draws pivots and SMT divergences from higher timeframes on the corresponding candles of your current lower timeframe chart.
Its core features include:
Multi-Timeframe Analysis: Configure and monitor pivots on up to four independent timeframes, from intraday to monthly.
Customizable Pivot Detection: Define the strength of pivots by adjusting the number of bars to the left and right.
SMT Divergence: Automatically identifies bullish and bearish SMT divergences by comparing the price action of the main chart symbol with a chosen correlated asset.
Early SMT Detection: A unique feature that monitors a lower "detection timeframe" to provide early warnings of potential SMT setups before they're confirmed on the main timeframe. Note that this early detection is only shown on timeframes equal to or lower than the "Detection timeframe" you have set.
Visual Cues & Alerts: Clear on-chart labels, lines, and fully customizable alerts notify you of confirmed pivots and SMT divergences, ensuring you don't miss key opportunities.
Important Nuance Regarding Pivot Label Display
Due to a self-imposed limit within this script's drawing management logic, the indicator might quickly reach its drawing capacity if you enable pivot crosses for multiple timeframes simultaneously. When this internal drawing limit is exceeded, the script is designed to automatically remove the oldest drawings to make space for new ones.
Therefore, to ensure optimal performance and visibility of the most recent and relevant pivots, it's highly recommended to only enable the "Show Pivot Crosses" option for one timeframe at a time. If you wish to view pivots for a different timeframe, simply disable the pivot crosses for the currently active timeframe and then enable them for your desired one. This approach prevents the rapid cycling and disappearance of pivot labels, providing a clearer and more stable visual experience.
In-Depth Explanation of the Logic
This script is built on two primary concepts: pivot points and Smart Money Technique (SMT) divergence. It systematically collects historical data on multiple timeframes, identifies pivots, and then compares them between two assets to find divergences.
Pivot Point Identification
A pivot is a turning point in the market. A pivot high is a candle that has a higher high than the candles to its immediate left and right. Conversely, a pivot low is a candle with a lower low than its neighbors.
How it Works in the Script:
The script tracks the highest high and lowest low for each period of the selected timeframe (e.g., for each 4-hour candle). When a new high-timeframe candle closes, it stores that high/low value and its bar index in an array. The checkForPivot() function then checks if a recently stored high or low qualifies as a pivot.
Key Inputs:
Left Strength (leftBars1): The number of candles to the left that must have a lower high (for a pivot high) or higher low (for a pivot low).
Right Strength (rightBars1): The number of candles to the right that must meet the same criteria.
For example, with Left Strength and Right Strength both set to 3, a pivot high is only confirmed when its high is greater than the highs of the 3 previous high-timeframe candles and the 3 subsequent high-timeframe candles. Increasing these values will identify more significant, longer-term pivots.
Smart Money Technique (SMT) Divergence
SMT Divergence is a concept popularized by The Inner Circle Trader (ICT). It occurs when two closely correlated assets fail to move in sync. For instance, if Asset A makes a higher high but Asset B fails to do so and instead makes a lower high, this creates a bearish SMT divergence. It suggests that the "smart money" may not be supporting the move in Asset A, signaling a potential reversal.
Bearish SMT: Main asset makes a higher high, while the correlated asset makes a lower high. This is a potential sell signal.
Bullish SMT: Main asset makes a lower low, while the correlated asset makes a higher low. This is a potential buy signal.
How it Works in the Script:
Data Request: For each timeframe, the script uses the request.security() function to fetch the high and low data for both the main chart symbol (syminfo.tickerid) and the chosen Comparison Asset.
Pivot Comparison: When a new pivot is confirmed on the main asset, the script checks if a corresponding pivot also formed on the comparison asset at the same time.
Divergence Check: It then compares the direction of the pivots. For a bearish SMT, it checks if the main asset's new pivot high is higher than its previous pivot high, while the comparison asset's new pivot high is lower than its previous one. The logic is reversed for bullish SMT.
Visualization: If a divergence is found, the script draws a red (bearish) or green (bullish) line connecting the two pivots on your chart and places an "SMT" label.
Early SMT Detection
This is a proactive feature designed to give you a heads-up. Waiting for a 4-hour or daily pivot to form can take a long time. The early detection system looks for SMT divergences on a much smaller, user-defined Detection timeframe (e.g., 15-minute).
How it Works in the Script:
Awaiting Setup: After a primary pivot (Pivot A) is formed on the main timeframe (e.g., a Daily pivot high), the script begins monitoring.
Intraday Monitoring: It then watches the Detection timeframe (e.g., 15-minute) for smaller intraday pivots.
Potential Divergence: It looks for an intraday pivot that forms a divergence against the primary Pivot A.
Watchline & Alert: When this "potential" divergence occurs, the script draws a dashed white line and triggers a "Potential SMT" alert. This isn't a confirmed SMT on the main timeframe yet, but it's a powerful early warning that one may be forming.
Drawing & Object Management
To keep the chart clean and prevent performance issues, the script manages its drawings (lines and labels) efficiently. It stores them in arrays and uses a drawing limit to automatically delete the oldest drawings as new ones are created, ensuring your TradingView remains responsive.
How to Use the Indicator
Configuration
Enable Timeframes: Use the checkboxes (Enable Timeframe 1, Enable Timeframe 2, etc.) to activate the timeframes you want to monitor. It's often best to start with one or two to keep the chart clean.
Select Timeframes: Choose the higher timeframes you want to analyze (e.g., 240 for 4-hour, D for Daily, W for Weekly).
Set Pivot Strength: The default of 3 for Left/Right strength is a good starting point. Increase it to find more significant market structure points or decrease it for more frequent, shorter-term pivots.
Configure SMT:
Check Enable SMT for the timeframes where you want to detect divergence.
Enter a Comparison Asset . This is crucial. Ensure the assets are correlated.
To use the early warning system, check Enable early SMT detection and select an appropriate Detection timeframe (e.g., 15 or 60 minutes for a Daily analysis).
Elliott Wave Probability SystemAdvanced Elliott Wave analysis system with AI-powered probability calculations for price targets. Combines multiple technical indicators to generate high-probability trading signals with specific price objectives.
🎯 KEY FEATURES:
- Automatic Elliott Wave pattern detection
- Dynamic Fibonacci retracement & extension levels
- Probability-weighted price targets (up to 10 levels)
- Multi-indicator confluence scoring system
- Real-time probability calculations
- Visual wave projections with success rates
- Comprehensive status dashboard
📊 TECHNICAL INDICATORS INTEGRATED:
- Elliott Wave pattern recognition
- Fibonacci levels (0-261.8%)
- RSI momentum analysis
- MACD trend confirmation
- Stochastic oscillator
- Volume spike detection
- Weighted scoring algorithm
💡 PROBABILITY ENGINE:
- Calculates target probabilities based on:
- Current wave position
- Technical indicator alignment
- Volume confirmation
- Market structure
- Updates in real-time
- Adjusts for market conditions
🎨 VISUAL ELEMENTS:
- Wave connection lines
- Fibonacci grid with prices
- Probability table with 5-10 targets
- Color-coded signal strength
- Status dashboard
- Target projection lines
🔧 CUSTOMIZATION:
- Adjustable wave detection period
- Number of price targets (3-10)
- Toggle visual elements
- Custom color schemes
- Flexible indicator parameters
📈 TRADING METHODOLOGY:
- Entry: High probability targets + confluence
- Exit: Target completion or signal reversal
- Risk: Use Fibonacci levels for stops
- Position sizing: Based on probability %
Perfect for traders seeking objective, probability-based price targets using Elliott Wave theory combined with technical confirmation.
⚡ ALERTS INCLUDED:
- Strong buy/sell signals
- Target approach notifications
- Wave completion alerts
Correlating AI Agent coded by ITECS .