OneTrend Lite EMAOneTrend Lite EMA uses exponential moving averages (EMA) to define market trend direction and employs a dynamic ATR-based threshold adjusted by a custom ADX calculation to generate bullish (blue) and bearish (pink) zones.
It enters long positions when the fast EMA exceeds the threshold (blue zone) and exits when it falls below the threshold (pink zone), providing clear, rule-based signals for trend-following trades.
Pros include adaptive thresholding that reflects market volatility and trend strength, while cons are potential lag in sideways or choppy markets as EMAs are inherently lagging by nature.
Trend Analysis
Fibonacci Trend with Adaptive ChannelsFibonacci Trend with Adaptive Channels
The "Fibonacci Trend with Adaptive Channels" indicator is a powerful technical analysis tool that blends dynamic Fibonacci retracement levels with adaptive trend channels and exponential moving averages (EMAs). Designed for traders seeking a comprehensive view of market trends and key price levels, this script combines the precision of ChartPrime's Fibonacci Trend with Julien Eche's Adaptive Trend Finder, enhanced with customizable EMAs. Whether you're a swing trader, day trader, or long-term investor, this indicator offers a versatile approach to identifying support, resistance, and trend direction.
Fibonacci Levels
At its core, the indicator dynamically plots Fibonacci retracement levels (0, 0.236, 0.382, 0.5, 0.618, 0.786, 1) based on the Supertrend indicator's direction. When a trend shift occurs, the script identifies the highest high and lowest low within the trend, extending these levels forward by a user-defined number of bars. Traders can customize the Fibonacci line color and fill color between levels, making it easy to spot potential reversal zones or continuation patterns in any market condition.
Exponential Moving Averages (EMAs)
To complement the Fibonacci analysis, the indicator overlays three EMAs with periods of 10, 55, and 200. These moving averages provide additional context for trend strength and momentum. The short-term EMA (10) tracks rapid price movements, the medium-term EMA (55) offers a balanced view, and the long-term EMA (200) highlights the broader market direction. Each EMA's color is fully customizable, allowing users to tailor the visual experience to their preferences.
Adaptive Trend Channels
The Adaptive Trend Finder component introduces logarithmic regression-based channels that automatically adjust to the strongest historical trend. Users can toggle between short-term (20-200 bars) and long-term (300-1200 bars) channel modes, with customizable deviation multipliers, line styles, and colors for both the midline and outer channels. This adaptive approach ensures that the channels reflect the most statistically significant trend, providing a robust framework for price action analysis.
Statistical Insights
A standout feature is the integrated table, which displays key metrics about the detected trend. Traders can choose to show the auto-selected period (the length with the highest correlation), trend strength (via a descriptive label or Pearson's R value), and the annualized return (CAGR) for daily or weekly timeframes. The table's position and text size are adjustable, offering flexibility to keep your chart clean while accessing critical data at a glance.
Customization and Flexibility
This indicator is built with customization in mind. Beyond color options for Fibonacci levels, EMAs, and channels, users can adjust the Supertrend period, Fibonacci extension length, channel deviation, and table settings. Whether you prefer a minimalist setup with just the essentials or a detailed display with all features enabled, the script adapts to your trading style. Load it twice to view short-term and long-term channels simultaneously for a multi-timeframe perspective.
Usage and Licensing
Ideal for stocks, forex, cryptocurrencies, and more, this indicator is published under a dual-license framework: MPL-2.0 for the Fibonacci Trend component (© ChartPrime) and GPL-3.0 for the Adaptive Trend Finder component (© Julien Eche). For optimal performance, ensure sufficient historical data is loaded, especially in long-term channel mode. Scroll back on your chart if channels aren't visible, and experiment with settings to fine-tune the tool to your market and timeframe of choice.
SemaforThis is the 4 Level Semafor indicator with Daily Open Line and Average Session Range. Also on the chart is the EMA Ribbon indicator.
Credit to:
Devlucem for the Semafor indicator
Quantvue for the Average Session Range
Shusterivi for the Daily Open Line
MYNAMEISBRANDON for the EMA Ribbon
The Semafors are based on the ZigZag indicator and show higher highs/lower lows of a specified period, determined by the user and applied in settings.
The default periods I use are:
10 period (hidden on this chart)
50 period-blue dots
250 period-white dots
615 period-black dots
Just as the ZigZag indicator will recalculate so to will the semafors, as additional candles are built. The semafor indicator is never to be used as a stand alone signal. It must be combined with other indicators to be used effectively. What we look for are the semafor patterns of a large white dot followed by a 1st blue dot opposite of the white. Then a 2nd blue dot in agreement with the white dot. In theory, the 2nd blue dot is seen as confirmation of the establishment of the white semafor..
When combined with Daily Open Line, ADR (Average Sessions Range), EMA cross and VWAP anchored to your 250 semafors, your odds are greatly increased. Add to that the knowledge of basic market structure and the wisdom that comes from patience and you have a very powerful weapon.
The Daily Open...I trade the M1 chart and also draw a H4 Open Line on my chart for the smaller time frames. Price will tend to trade away from the Daily Open Line. In many cases until it reaches certain levels...Fib, Gann, ADR, etc., then runs through a pullback cycle. I like the ADR levels. The ADR can give clues when entering a consolidation phase, ie trading between the buy side and sell side 15% levels. Trading away from the Daily Open(or H4 open) along with breaking the 15% level, while in agreement with a semafor pattern is a good sign.
Add to that confluence the agreement of your MA cross and the 250 semafor Anchored VWAP and you have a solid signal to help determine your actions. This trend following layout will work on any time frame. I just really like the M1 for its precision, not for crazy back and forth all day. With the exception of some strong pull back signals, I don't enter any more trades on the M1 than on M5, 15 or 30.
This is based on and follows the teachings of Xard and his trading strategy. Just as I don't want to take anyone's credit for these indicators, I won't take credit for what I have been taught either.
The trader can obviously use their favorite MA cross indicator. But this one is visually beautiful AND displays the current time frame and 1 time frame higher on the chart...awesome!
Of note, I do run into trouble at times with the 615 period semafor. I have been told it is because TradingView has trouble with extended period indicators. As a matter of fact, I would like a much higher period for my biggest semafor. I would like it set at 1250, but that seems to be a no starter. If anyone has a solution, that would be welcomed news.
Killzones (Box Style, Custom Colors) - NY TimeThis indicator visually highlights the 3 main trading sessions ("killzones") — Asia, London, and New York — on any intraday chart using box overlays that automatically adjust to price action and time, locked to America/New_York timezone.
📅 Killzones Defined:
Killzone NY Time Purpose
Asia Session 7:00 PM – 10:00 PM (Previous Day) Preps for overnight moves, often shows low volatility or accumulation
London Session 2:00 AM – 5:00 AM Often sets the daily high/low, high volatility
NY Session 7:00 AM – 10:00 AM Big volume from US open, news events, major moves
Each killzone is shown with a colored box that:
Begins at the exact killzone open time
Ends at the killzone close
Expands vertically to encompass all highs and lows that occur within the session
TimeMapTimeMap is a visual price-reference indicator designed to help traders rapidly visualize how current price levels relate to significant historical closing prices. It overlays your chart with reference lines representing past weekly, monthly, quarterly (3-month), semi-annual (6-month), and annual closing prices. By clearly plotting these historical price references, TimeMap helps traders quickly gauge price position relative to historical market structure, aiding in the identification of trends, support/resistance levels, and potential reversals.
How it Works:
The indicator calculates the precise number of historical bars corresponding to weekly, monthly, quarterly, semi-annual, and annual intervals, dynamically adjusting according to your chart’s timeframe (intraday, daily, weekly, monthly) and chosen market type (Stocks US, Crypto, Forex, or Futures). Historical closing prices from these periods are plotted directly on your chart as horizontal reference lines.
For intraday traders, the script accurately calculates historical offsets considering regular and extended trading sessions (e.g., pre-market and after-hours sessions for US stocks), ensuring correct positioning of historical lines.
User-Configurable Inputs Explained in Detail:
Market Type:
Allows you to specify your trading instrument type, automatically adjusting calculations for:
- Stocks US (default): 390 minutes per regular session (780 minutes if extended hours enabled), 5 trading days/week.
- Crypto: 1440 minutes/day, 7 trading days/week.
- Forex: 1440 minutes/day, 5 trading days/week.
- Futures: 1320 minutes/day, 5 trading days/week.
Show Weekly Close:
When enabled, plots a line at the exact closing price from one week ago. Provides short-term context and helps identify recent price momentum.
Show Monthly Close:
When enabled, plots a line at the exact closing price from one month ago. Helpful for evaluating medium-term price positioning and monthly trend strength.
Show 3-Month Close:
When enabled, plots a line at the exact closing price from three months ago. Useful for assessing quarterly market shifts, intermediate trend changes, and broader market sentiment.
Show 6-Month Close:
When enabled, plots a line at the exact closing price from six months ago. Useful for identifying semi-annual trends, significant price pivots, and longer-term support/resistance levels.
Show 1-Year Close:
When enabled, plots a line at the exact closing price from one year ago. Excellent for assessing long-term market direction and key annual price levels.
Enable Smoothing:
Activates a Simple Moving Average (SMA) smoothing of historical reference lines, reducing volatility and providing clearer visual references. Recommended for traders preferring less volatile reference levels.
Smoothing Length:
Determines the number of bars used in calculating the SMA smoothing of historical lines. Higher values result in smoother but slightly delayed reference lines; lower values offer more immediate yet more volatile levels.
Use Extended Hours (Intraday Only):
When enabled (only applicable for Stocks US), it accounts for pre-market and after-hours trading sessions, providing accurate intraday historical line calculations based on extended sessions (typically 780 minutes/day total).
Important Notes and Compliance:
- This indicator does not provide trading signals, recommendations, or predictions. It serves purely as a visual analytical tool to supplement traders’ existing methods.
- Historical lines plotted are strictly based on past available price data; the indicator never accesses future data or data outside the scope of Pine Script’s standard capabilities.
- The script incorporates built-in logic to avoid runtime errors if insufficient historical data exists for a selected timeframe, ensuring robustness even with limited historical bars.
- TimeMap is original work developed exclusively by Julien Eche (@Julien_Eche). It does not reuse or replicate third-party or existing open-source scripts.
Recommended Best Practices:
- Use TimeMap as a complementary analytical reference, not as a standalone strategy or trade decision-making tool.
- Adapt displayed historical periods and smoothing settings based on your trading style and market approach.
- Default plot colors are optimized for readability on dark-background charts; adjust as necessary according to your preference and chart color scheme.
This script is published open-source to benefit the entire TradingView community and fully complies with all TradingView script publishing rules and guidelines.
Low Liquidity Zones [PhenLabs]📊 Low Liquidity Zones
Version: PineScript™ v6
📌 Description
Low Liquidity Zones identifies and highlights periods of unusually low trading volume on your chart, marking areas where price movement occurred with minimal participation. These zones often represent potential support and resistance levels that may be more susceptible to price breakouts or reversals when revisited with higher volume.
Unlike traditional volume analysis tools that focus on high volume spikes, this indicator specializes in detecting low liquidity areas where price moved with minimal resistance. Each zone displays its volume delta, providing insight into buying vs. selling pressure during these thin liquidity periods. This combination of low volume detection and delta analysis helps traders identify potential price inefficiencies and weak structures in the market.
🚀 Points of Innovation
• Identifies low liquidity zones that most volume indicators overlook but which often become significant technical levels
• Displays volume delta within each zone, showing net buying/selling pressure during low liquidity periods
• Dynamically adjusts to different timeframes, allowing analysis across multiple time horizons
• Filters zones by maximum size percentage to focus only on precise price levels
• Maintains historical zones until they expire based on your lookback settings, creating a cumulative map of potential support/resistance areas
🔧 Core Components
• Low Volume Detection: Identifies candles where volume falls below a specified threshold relative to recent average volume, highlighting potential liquidity gaps.
• Volume Delta Analysis: Calculates and displays the net buying/selling pressure within each low liquidity zone, providing insight into the directional bias during low participation periods.
• Dynamic Timeframe Adjustment: Automatically scales analysis periods to match your selected timeframe preference, ensuring consistent identification of low liquidity zones regardless of chart settings.
• Zone Management System: Creates, tracks, and expires low liquidity zones based on your configured settings, maintaining visual clarity on the chart.
🔥 Key Features
• Low Volume Identification: Automatically detects and highlights candles where volume falls below your specified threshold compared to the moving average.
• Volume Delta Visualization: Shows the net volume delta within each zone, providing insight into whether buyers or sellers were dominant despite the low overall volume.
• Flexible Timeframe Analysis: Analyze low liquidity zones across multiple predefined timeframes or use a custom lookback period specific to your trading style.
• Zone Size Filtering: Filters out excessively large zones to focus only on precise price levels, improving signal quality.
• Automatic Zone Expiration: Older zones are automatically removed after your specified lookback period to maintain a clean, relevant chart display.
🎨 Visualization
• Volume Delta Labels: Each zone displays its volume delta with “+” or “-” prefix and K/M suffix for easy interpretation, showing the strength and direction of pressure during the low volume period.
• Persistent Historical Mapping: Zones remain visible for your specified lookback period, creating a cumulative map of potential support and resistance levels forming under low liquidity conditions.
📖 Usage Guidelines
Analysis Timeframe
Default: 1D
Range/Options: 15M, 1HR, 3HR, 4HR, 8HR, 16HR, 1D, 3D, 5D, 1W, Custom
Description: Determines the historical period to analyze for low liquidity zones. Shorter timeframes provide more recent data while longer timeframes offer a more comprehensive view of significant zones. Use Custom option with the setting below for precise control.
Custom Period (Bars)
Default: 1000
Range: 1+
Description: Number of bars to analyze when using Custom timeframe option. Higher values show more historical zones but may impact performance.
Volume Analysis
Volume Threshold Divisor
Default: 0.5
Range: 0.1-1.0
Description: Maximum volume relative to average to identify low volume zones. Example: 0.5 means volume must be below 50% of the average to qualify as low volume. Lower values create more selective zones while higher values identify more zones.
Volume MA Length
Default: 15
Range: 1+
Description: Period length for volume moving average calculation. Shorter periods make the indicator more responsive to recent volume changes, while longer periods provide a more stable baseline.
Zone Settings
Zone Fill Color
Default: #2196F3 (80% transparency)
Description: Color and transparency of the low liquidity zones. Choose colors that stand out against your chart background without obscuring price action.
Maximum Zone Size %
Default: 0.5
Range: 0.1+
Description: Maximum allowed height of a zone as percentage of price. Larger zones are filtered out. Lower values create more precise zones focusing on tight price ranges.
Display Options
Show Volume Delta
Default: true
Description: Toggles the display of volume delta within each zone. Enabling this provides additional insight into buying vs. selling pressure during low volume periods.
Delta Text Position
Default: Right
Options: Left, Center, Right
Description: Controls the horizontal alignment of the delta text within zones. Adjust based on your chart layout for optimal readability.
✅ Best Use Cases
• Identifying potential support and resistance levels that formed during periods of thin liquidity
• Spotting price inefficiencies where larger players may have moved price with minimal volume
• Finding low-volume consolidation areas that may serve as breakout or reversal zones when revisited
• Locating potential stop-hunting zones where price moved on minimal participation
• Complementing traditional support/resistance analysis with volume context
⚠️ Limitations
• Requires volume data to function; will not work on symbols where the data provider doesn’t supply volume information
• Low volume zones don’t guarantee future support/resistance - they simply highlight potential areas of interest
• Works best on liquid instruments where volume data has meaningful fluctuations
• Historical analysis is limited by the maximum allowed box count (500) in TradingView
• Volume delta in some markets may not perfectly reflect buying vs. selling pressure due to data limitations
💡 What Makes This Unique
• Focus on Low Volume: Unlike some indicators that highlight high volume events particularly like our very own TLZ indicator, this tool specifically identifies potentially significant price zones that formed with minimal participation.
• Delta + Low Volume Integration: Combines volume delta analysis with low volume detection to reveal directional bias during thin liquidity periods.
• Flexible Lookback System: The dynamic timeframe system allows analysis across any timeframe while maintaining consistent zone identification criteria.
• Support/Resistance Zone Generation: Automatically builds a visual map of potential technical levels based on volume behavior rather than just price patterns.
🔬 How It Works
1. Volume Baseline Calculation:
The indicator calculates a moving average of volume over your specified period to establish a baseline for normal market participation. This adaptive baseline accounts for natural volume fluctuations across different market conditions.
2. Low Volume Detection:
Each candle’s volume is compared to the moving average and flagged when it falls below your threshold divisor. The indicator also filters zones by maximum size to ensure only precise price levels are highlighted.
3. Volume Delta Integration:
For each identified low volume candle, the indicator retrieves the volume delta from a lower timeframe. This delta value is formatted with appropriate scaling (K/M) and displayed within the zone.
4. Zone Management:
New zones are created and tracked in a dynamic array, with each zone extending rightward until it expires. The system automatically removes expired zones based on your lookback period to maintain a clean chart.
💡 Note:
Low liquidity zones often represent areas where price moved with minimal participation, which can indicate potential market inefficiencies. These zones frequently become important support/resistance levels when revisited, especially if approached with higher volume. Consider using this indicator alongside traditional technical analysis tools for comprehensive market context. For best results, experiment with different volume threshold settings based on the specific instrument’s typical volume patterns.
HEMA Trend Levels [AlgoAlpha]OVERVIEW
This script plots two Hull-EMA (HEMA) curves to define a color-coded dynamic trend zone and generate context-aware breakout levels, allowing traders to easily visualize prevailing momentum and identify high-probability breakout retests. The script blends smoothed price tracking with conditional box plotting, delivering both trend-following and mean-reversion signals within one system. It is designed to be simple to read visually while offering nuanced trend shifts and test confirmations.
█ CONCEPTS
The Hull-EMA (HEMA) is a hybrid moving average combining the responsiveness of short EMAs with the smoothness of longer ones. It applies layered smoothing: first by subtracting a full EMA from a half-length EMA (doubling the short EMA's weight), and then by smoothing the result again with the square root of the original length. This process reduces lag while maintaining clarity in direction changes. In this script, two HEMAs—fast and slow—are used to define the trend structure and trigger events when they cross. These crossovers generate "trend shift boxes"—temporary support or resistance zones drawn immediately after trend transitions—to detect price retests in the new direction. When price cleanly retests these levels, the script marks them as confirmations with triangle symbols, helping traders isolate better continuation setups. Color-coded bars further enhance visual interpretation: bullish bars when price is above both HEMAs, bearish when below, and neutral (gray) when indecisive.
█ FEATURES
Bullish and bearish bar coloring based on price and HEMA alignment.
Box plotting at each crossover (bullish or bearish) to create short-term decision zones.
Real-time test detection: price must cleanly test and bounce from box levels to be considered valid.
Multiple alert conditions: crossover alerts, test alerts, and trend continuation alerts.
█ USAGE
Use this indicator on any time frame and asset. Adjust HEMA lengths to match your trading style—shorter lengths for scalping or intraday, longer for swing trading. The shaded area between HEMAs helps visually define the current trend. Watch for crossovers: a bullish crossover plots a green support box just below price, and a bearish one plots a red resistance box just above. These zones act as short-term decision points. When price returns to test a box and confirms with strong rejection (e.g., closes above for bullish or below for bearish), a triangle symbol is plotted. These tests can signal strong trend continuation. For traders looking for clean entries, combining the crossover with a successful retest improves reliability. Alerts can be enabled for all key signals: trend shift, test confirmations, and continuation conditions, making it suitable for automated setups or discretionary traders tracking multiple charts.
Date-Based Price Projection (Offset)Predict future price movements by analyzing past trends—customizable, visually intuitive, and perfect for traders! 📊🚀
1️⃣ Predict Future Prices: Uses past price movements to project potential future trends.
2️⃣ Custom Date Selection: Analyze price behavior from any historical date of your choice.
3️⃣ Time Offset Feature: Shift data forward or backward to compare past trends with today.
4️⃣ Visual Projections: Displays future price estimates in a stylish table for easy reference.
5️⃣ Color-Coded Movements: Green for uptrends, red for downtrends—customizable to your preference.
6️⃣ Avoids Weekend Bias: Automatically skips non-trading days for accurate projections.
7️⃣ Great for Trend Analysis: Identify repeating price patterns to enhance trading strategies.
8️⃣ Quick Insights: Instantly see percentage changes and projected prices at a glance.
9️⃣ Works on Any Market: Use it for stocks, forex, crypto, or any chart with historical data.
🔟 Boosts Decision-Making: Helps traders anticipate potential price movements with confidence! 🚀
Advanced Supply and Demand ZonesThe "Advanced Supply and Demand Zones" indicator is a powerful tool designed to help traders identify key market zones where price reversals are likely to occur. This indicator dynamically detects and visualizes supply and demand zones, providing traders with high-probability trade setups based on price action, volume, and momentum filters.
With enhanced filtering options, including candle size confirmation, RSI-based validation, and trend direction analysis, this tool improves trading accuracy while minimizing false signals.
Key Features
✅ Automatic Supply & Demand Zone Detection – The indicator dynamically detects and updates supply and demand zones.
✅ Customizable Zone Detection Length – Traders can adjust zone sensitivity to match different trading styles.
✅ Multi-Layer Filtering System
✅ Candle Size Confirmation – Ensures price movement is significant before triggering signals.
✅ RSI-Based Filtering – Helps validate overbought and oversold conditions for stronger trade setups.
✅ Consecutive Bars Confirmation – Prevents premature signals by requiring multiple confirmations.
✅ Buy & Sell Signal Generation – Identifies optimal trade entries at strong supply and demand zones.
✅ Market Trend Indicator – Built-in SMA trend filter helps identify bullish and bearish market conditions.
✅ Dashboard with Key Information – Displays market trend, supply zone, and demand zone details directly on the chart.
✅ Optimized for All Markets – Works on stocks, forex, crypto, indices, and all timeframes.
How It Works
📌 Supply Zone Identification:
✅ Detects strong resistance areas where sellers are dominant.
✅ Uses highest price levels over a selected period to define zones.
✅ Triggers sell signals when price approaches the supply zone.
📌 Demand Zone Identification:
✅ Identifies strong support levels where buyers take control.
✅ Uses lowest price levels over a selected period to define demand zones.
✅ Triggers buy signals when price nears the demand zone.
📌 Trend Analysis & Filtering:
✅ Uses 9-period & 21-period SMAs to determine the market trend.
✅ Bullish trend when short SMA is above long SMA.
✅ Bearish trend when short SMA is below long SMA.
📌 Buy & Sell Signal Conditions:
✅ Buy Signal:
Price enters demand zone.
RSI confirms oversold conditions (if enabled).
Candle size and consecutive bar confirmations are met.
✅ Sell Signal:
Price enters supply zone.
RSI confirms overbought conditions (if enabled).
Candle size and confirmation filters validate the trade.
Customization & Settings
🔹 Zone Detection Length – Adjusts the number of candles used for identifying supply & demand zones.
🔹 RSI Filtering – Enables RSI-based trade validation with adjustable overbought/oversold levels.
🔹 Trend Filter – Uses moving averages to filter trades in the direction of the market trend.
🔹 Candle Size Confirmation – Ensures price moves are significant before validating trades.
🔹 Dashboard Positioning – Allows users to move the dashboard for better visibility.
Why Use This Indicator?
🚀 Enhances Trading Accuracy – Reduces false signals with multi-layer filtering.
📊 Works Across All Timeframes – Suitable for day trading, swing trading, and scalping.
⚡ Perfect for Trend & Reversal Traders – Identifies strong support and resistance areas for high-probability setups.
💡 No Overlapping Zones – Ensures clean charting with clearly defined supply and demand areas.
Best Use Cases
📉 Swing Trading – Identify key reversal points to time entries and exits.
📈 Breakout Trading – Detect strong supply/demand zones for breakout confirmation.
🎯 Trend Following – Use with trend filters to maximize trade efficiency.
🔥 Take Your Trading to the Next Level with the "Advanced Supply and Demand Zones" Indicator! 🔥
Combined Market Structure Indicator### 🧠 Combined Market Structure Indicator – Supertrend + QQE + EMA + OB/MSB
The **Combined Market Structure Indicator** is a powerful, all-in-one trading tool designed to help you identify **market structure breaks (MSBs)**, **order blocks (OBs)**, **EMA crossovers**, and popular **trend-following indicators** like **Supertrend** and **QQE** – all in a single script.
#### 🚀 Key Features:
🔹 **Supertrend Buy/Sell Signals**
Identifies trend changes with customizable ATR and factor values. Alerts are built-in for both long and short opportunities.
🔹 **QQE Momentum Signals**
A refined QQE (Quantitative Qualitative Estimation) implementation to catch early momentum shifts. Plots buy/sell signals on the chart.
🔹 **EMA Crossovers**
Customizable fast and slow exponential moving averages highlight classic trend continuation or reversal points with optional alerts.
🔹 **Market Structure Break (MSB)**
Detects bullish and bearish market structure breaks using dynamic zigzag swing points and Fibonacci-based confirmation logic. MSBs are clearly labeled on the chart.
🔹 **Order Block (OB) Detection**
Automatically draws bullish and bearish OB zones based on candle structure and market shifts. Alerts notify when price revisits these areas.
🔹 **Breaker Block & Mitigation Block Zones (BB/MB)**
Visual zones for potential rejections or continuations, helping traders anticipate key reaction levels in the price structure.
🔹 **Dynamic ZigZag Visualization**
Optional zigzag line plotting to visualize swing highs/lows, providing better structure clarity and confirming OB/MSB zones.
🔹 **Custom Alert System**
Smart alerts for Supertrend, EMA crossovers, QQE signals, and price entering key OB/BB zones – fully customizable.
#### 🎛️ User Inputs:
- Supertrend Factor, ATR Length
- QQE RSI Length
- Fast/Slow EMA periods
- Alert toggles for each system
- Zigzag sensitivity and visualization toggle
- Full control over OB/BB colors, labels, and cleanup behavior
#### 📊 Ideal For:
- Swing Traders
- Smart Money / ICT Style Traders
- Trend Followers
- Breakout/Breakdown Traders
- Anyone seeking structure-based confluence zones
Dynamic Momentum Bands | AlphaAlgosDynamic Momentum Bands | AlphaAlgos
Overview
The Dynamic Momentum Bands indicator is an advanced technical analysis tool that combines multiple analytical techniques to provide a comprehensive view of market momentum and trend dynamics. By integrating RSI (Relative Strength Index), volatility analysis, and adaptive moving averages, this indicator offers traders a nuanced perspective on market conditions.
Key Features
Adaptive band calculation based on price momentum
Integrated RSI-driven volatility scaling
Multiple moving average type options (EMA, SMA, VWMA)
Smooth, gradient-based band visualization
Optional price bar coloring for trend identification
Technical Methodology
The indicator employs a sophisticated approach to market analysis:
1. Momentum Calculation
Calculates RSI using a customizable length
Uses RSI to dynamically adjust band volatility
Scales band width based on distance from the 50 RSI level
2. Band Construction
Applies a selected moving average type to the price source
Calculates deviation using ATR (Average True Range)
Smooths band edges for improved visual clarity
Configuration Options
Core Settings:
Price Source: Choose the price data used for calculations
RSI Length: Customize the RSI calculation period (1-50)
Band Length: Adjust the moving average period (5-100)
Volatility Multiplier: Fine-tune band width
Band Type: Select between EMA, SMA, and VWMA
Visual Settings:
Bar Coloring: Toggle color-coded price bars
Gradient-based band visualization
Smooth color transitions for trend representation
Trend Identification
The indicator provides trend insights through:
Color-coded bands (blue for bullish, pink for bearish)
Smooth gradient visualization
Optional price bar coloring
Trading Applications
Trend Following:
- Use band position relative to price as trend indicator
- Identify momentum shifts through color changes
- Utilize gradient zones for trend strength assessment
Volatility Analysis:
Observe band width changes
Detect potential breakout or consolidation periods
Use RSI-driven volatility scaling for market context
Best Practices
Adjust RSI length to match trading timeframe
Experiment with different moving average types
Use in conjunction with other technical indicators
Consider volatility multiplier for different market conditions
This indicator is provided for informational purposes only. Always use proper risk management when trading. Past performance is not indicative of future results. Not financial Advise
Relative StrengthRelative Strength (RS) indicator lets you plot the relative strength of given instrument against another one. It will help you compare relative strength of given assets for the specified timeframe and duration.
Why another RS indicator?
Many of the existing RS indicators, even those highly rated, work incorrectly. Some of them use close values for calculating RS without any normalization which is grossly incorrect. Then there are few others which work but they have too many parameters to configure which makes it difficult to understand and use.
I have tried to keep it as simple as I could and have added tooltips for each config parameter to ensure you are aware of why that parameter is needed.
Enjoy!
Market Symphony (Dragon Trader)The "Market Symphony (Dragon Trader)" indicator is a powerful technical analysis tool designed for traders seeking to identify potential buy and sell signals in the financial markets. This indicator combines multiple technical indicators into a single, easy-to-interpret visual display, allowing traders to make informed decisions quickly.
Key Features:
Multi-Indicator Approach: The indicator incorporates a symphony of popular technical indicators, including:
Loxxer
Moving Average Convergence Divergence (MACD)
Relative Strength Index (RSI)
Stochastic Oscillator
Commodity Channel Index (CCI)1
Velocity
Visual Clarity: The indicator utilizes color-coded squares and other shapes to represent buy and sell signals, making it easy to identify potential trading opportunities at a glance.
Customizable Settings: Traders can adjust various parameters to fine-tune the indicator to their specific trading style and market conditions.
Alert Functionality: The indicator provides real-time alerts for potential buy and sell signals, ensuring that traders never miss a trading opportunity.
Bar Coloring: the indicator can color the price bar, to give a better overview of the trend.
Repainting Option: The indicator gives the option to allow repainting in some of its calculations.
How it Works:
The "Market Symphony (Dragon Trader)" indicator analyzes price data using the aforementioned technical indicators. When a confluence of these indicators suggests a potential buy or sell signal, the indicator displays a corresponding visual cue on the chart. Traders can then use this information to make informed trading decisions.
Benefits:
Simplified Analysis: The indicator consolidates multiple technical indicators into a single display, saving traders time and effort.
Improved Accuracy: By considering a range of technical indicators, the indicator can help traders identify more reliable trading signals.
Enhanced Decision-Making: The indicator's clear visual cues and real-time alerts empower traders to make confident trading decisions.
In Conclusion:
The "Market Symphony (Dragon Trader)" indicator is a valuable tool for traders of all experience levels. Its comprehensive approach, visual clarity, and customizable settings make it an essential addition to any trader's arsenal.
I hope this description is helpful.
Predictave buy/sell EMA assist for Ripster INDPredictive buy/sell EMA assist. This was actually made to help **predict** the EMA cross overs that are visual on Ripsters indicator. Simple arrow up(Buy) arrow down(sell). The "Buy" arrow tolerance is adjustable to fine tune against your stock choice. Although this can be used standalone, the predictive and EMA portion was tailored to work in conjunction with Ripsters.
Multi-Anchored Linear Regression Channels [TANHEF]█ Overview:
The 'Multi-Anchored Linear Regression Channels ' plots multiple dynamic regression channels (or bands) with unique selectable calculation types for both regression and deviation. It leverages a variety of techniques, customizable anchor sources to determine regression lengths, and user-defined criteria to highlight potential opportunities.
Before getting started, it's worth exploring all sections, but make sure to review the Setup & Configuration section in particular. It covers key parameters like anchor type, regression length, bias, and signal criteria—essential for aligning the tool with your trading strategy.
█ Key Features:
⯁ Multi-Regression Capability:
Plot up to three distinct regression channels and/or bands simultaneously, each with customizable anchor types to define their length.
⯁ Regression & Deviation Methods:
Regressions Types:
Standard: Uses ordinary least squares to compute a simple linear trend by averaging the data and deriving a slope and endpoints over the lookback period.
Ridge: Introduces L2 regularization to stabilize the slope by penalizing large coefficients, which helps mitigate multicollinearity in the data.
Lasso: Uses L1 regularization through soft-thresholding to shrink less important coefficients, yielding a simpler model that highlights key trends.
Elastic Net: Combines L1 and L2 penalties to balance coefficient shrinkage and selection, producing a robust weighted slope that handles redundant predictors.
Huber: Implements the Huber loss with iteratively reweighted least squares (IRLS) and EMA-style weights to reduce the impact of outliers while estimating the slope.
Least Absolute Deviations (LAD): Reduces absolute errors using iteratively reweighted least squares (IRLS), yielding a slope less sensitive to outliers than squared-error methods.
Bayesian Linear: Merges prior beliefs with weighted data through Bayesian updating, balancing the prior slope with data evidence to derive a probabilistic trend.
Deviation Types:
Regressive Linear (Reverse): In reverse order (recent to oldest), compute weighted squared differences between the data and a line defined by a starting value and slope.
Progressive Linear (Forward): In forward order (oldest to recent), compute weighted squared differences between the data and a line defined by a starting value and slope.
Balanced Linear: In forward order (oldest to newest), compute regression, then pair to source data in reverse order (newest to oldest) to compute weighted squared differences.
Mean Absolute: Compute weighted absolute differences between each data point and its regression line value, then aggregate them to yield an average deviation.
Median Absolute: Determine the weighted median of the absolute differences between each data point and its regression line value to capture the central tendency of deviations.
Percent: Compute deviation as a percentage of a base value by multiplying that base by the specified percentage, yielding symmetric positive and negative deviations.
Fitted: Compare a regression line with high and low series values by computing weighted differences to determine the maximum upward and downward deviations.
Average True Range: Iteratively compute the weighted average of absolute differences between the data and its regression line to yield an ATR-style deviation measure.
Bias:
Bias: Applies EMA or inverse-EMA style weighting to both Regression and/or Deviation, emphasizing either recent or older data.
⯁ Customizable Regression Length via Anchors:
Anchor Types:
Fixed: Length.
Bar-Based: Bar Highest/Lowest, Volume Highest/Lowest, Spread Highest/Lowest.
Correlation: R Zero, R Highest, R Lowest, R Absolute.
Slope: Slope Zero, Slope Highest, Slope Lowest, Slope Absolute.
Indicator-Based: Indicators Highest/Lowest (ADX, ATR, BBW, CCI, MACD, RSI, Stoch).
Time-Based: Time (Day, Week, Month, Quarter, Year, Decade, Custom).
Session-Based: Session (Tokyo, London, New York, Sydney, Custom).
Event-Based: Earnings, Dividends, Splits.
External: Input Source Highest/Lowest.
Length Selection:
Maximum: The highest allowed regression length (also fixed value of “Length” anchor).
Minimum: The shortest allowed length, ensuring enough bars for a valid regression.
Step: The sampling interval (e.g., 1 checks every bar, 2 checks every other bar, etc.). Increasing the step reduces the loading time, most applicable to “Slope” and “R” anchors.
Adaptive lookback:
Adaptive Lookback: Enable to display regression regardless of too few historical bars.
⯁ Selecting Bias:
Bias applies separately to regression and deviation.
Positive values emphasize recent data (EMA-style), negative invert, and near-zero maintains balance. (e.g., a length 100, bias +1 gives the newest price ~7× more weight than the oldest).
It's best to apply bias to both (regression and deviation) or just the deviation. Biasing only regression may distort deviation visually, while biasing both keeps their relationship intuitive. Using bias only for deviation scales it without altering regression, offering unique analysis.
⯁ Scale Awareness:
Supports linear and logarithmic price scaling, the regression and deviations adjust accordingly.
⯁ Signal Generation & Alerts:
Customizable entry/exit signals and alerts, detailed in the dedicated section below.
⯁ Visual Enhancements & Real-World Examples:
Optional on-chart table display summarizing regression input criteria (display type, anchor type, source, regression type, regression bias, deviation type, deviation bias, deviation multiplier) and key calculated metrics (regression length, slope, Pearson’s R, percentage position within deviations, etc.) for quick reference.
█ Understanding R (Pearson Correlation Coefficient):
Pearson’s R gauges data alignment to a straight-line trend within the regression length:
Range: R varies between –1 and +1.
R = +1 → Perfect positive correlation (strong uptrend).
R = 0 → No linear relationship detected.
R = –1 → Perfect negative correlation (strong downtrend).
This script uses Pearson’s R as an anchor, adjusting regression length to target specific R traits. Strong R (±1) follows the regression channel, while weak R (0) shows inconsistency.
█ Understanding the Slope:
The slope is the direction and rate at which the regression line rises or falls per bar:
Positive Slope (>0): Uptrend – Steeper means faster increase.
Negative Slope (<0): Downtrend – Steeper means sharper drop.
Zero or Near-Zero Slope: Sideways – Indicating range-bound conditions.
This script uses highest and lowest slope as an anchor, where extremes highlight strong moves and trend lines, while values near zero indicate sideways action and possible support/resistance.
█ Setup & Configuration:
Whether you’re new to this script or want to quickly adjust all critical parameters, the panel below shows the main settings available. You can customize everything from the anchor type and maximum length to the bias, signal conditions, and more.
Scale (select Log Scale for logarithmic, otherwise linear scale).
Display (regression channel and/or bands).
Anchor (how regression length is determined).
Length (control bars analyzed):
• Max – Upper limit.
• Min – Prevents regression from becoming too short.
• Step – Controls scanning precision; increasing Step reduces load time.
Regression:
• Type – Calculation method.
• Bias – EMA-style emphasis (>0=new bars weighted more; <0=old bars weighted more).
Deviation:
• Type – Calculation method.
• Bias – EMA-style emphasis (>0=new bars weighted more; <0=old bars weighted more).
• Multiplier - Adjusts Upper and Lower Deviation.
Signal Criteria:
• % (Price vs Deviation) – (0% = lower deviation, 50% = regression, 100% = upper deviation).
• R – (0 = no correlation, ±1 = perfect correlation; >0 = +slope, <0 = -slope).
Table (analyze table of input settings, calculated results, and signal criteria).
Adaptive Lookback (display regression while too few historical bars).
Multiple Regressions (steps 2 to 7 apply to #1, #2, and #3 regressions).
█ Signal Generation & Alerts:
The script offers customizable entry and exit signals with flexible criteria and visual cues (background color, dots, or triangles). Alerts can also be triggered for these opportunities.
Percent Direction Criteria:
(0% = lower deviation, 50% = regression line, 100% = upper deviation)
Above %: Triggers if price is above a specified percent of the deviation channel.
Below %: Triggers if price is below a specified percent of the deviation channel.
(Blank): Ignores the percent‐based condition.
Pearson's R (Correlation) Direction Criteria:
(0 = no correlation, ±1 = perfect correlation; >0 = positive slope, <0 = negative slope)
Above R / Below R: Compares the correlation to a threshold.
Above│R│ / Below│R│: Uses absolute correlation to focus on strength, ignoring direction.
Zero to R: Checks if R is in the 0-to-threshold range.
(Blank): Ignores correlation-based conditions.
█ User Tips & Best Practices:
Choose an anchor type that suits your strategy, “Bar Highest/Lowest” automatically spots commonly used regression zones, while “│R│ Highest” targets strong linear trends.
Consider enabling or disabling the Adaptive Lookback feature to ensure you always have a plotted regression if your chart doesn’t meet the maximum-length requirement.
Use a small Step size (1) unless relying on R-correlation or slope-based anchors as the are time-consuming to calculate. Larger steps speed up calculations but reduce precision.
Fine-tune settings such as lookback periods, regression bias, and deviation multipliers, or trend strength. Small adjustments can significantly affect how channels and signals behave.
To reduce loading time , show only channels (not bands) and disable signals, this limits calculations to the last bar and supports more extreme criteria.
Use the table display to monitor anchor type, calculated length, slope, R value, and percent location at a glance—especially if you have multiple regressions visible simultaneously.
█ Conclusion:
With its blend of advanced regression techniques, flexible deviation options, and a wide range of anchor types, this indicator offers a highly adaptable linear regression channeling system. Whether you're anchoring to time, price extremes, correlation, slope, or external events, the tool can be shaped to fit a variety of strategies. Combined with customizable signals and alerts, it may help highlight areas of confluence and support a more structured approach to identifying potential opportunities.
LinearRegressionLibrary "LinearRegression"
Calculates a variety of linear regression and deviation types, with optional emphasis weighting. Additionally, multiple of slope and Pearson’s R calculations.
calcSlope(_src, _len, _condition)
Calculates the slope of a linear regression over the specified length.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The length of the lookback period for the linear regression.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast for efficiency.
Returns: (float) The slope of the linear regression.
calcReg(_src, _len, _condition)
Calculates a basic linear regression, returning y1, y2, slope, and average.
Parameters:
_src (float) : (float) The source data series.
_len (int) : (int) The length of the lookback period.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) An array of 4 values: .
calcRegStandard(_src, _len, _emphasis, _condition)
Calculates an Standard linear regression with optional emphasis.
Parameters:
_src (float) : (series float) The source data series.
_len (int) : (int) The length of the lookback period.
_emphasis (float) : (float) The emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) .
calcRegRidge(_src, _len, lambda, _emphasis, _condition)
Calculates a ridge regression with optional emphasis.
Parameters:
_src (float) : (float) The source data series.
_len (int) : (int) The length of the lookback period.
lambda (float) : (float) The ridge regularization parameter.
_emphasis (float) : (float) The emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) .
calcRegLasso(_src, _len, lambda, _emphasis, _condition)
Calculates a Lasso regression with optional emphasis.
Parameters:
_src (float) : (float) The source data series.
_len (int) : (int) The length of the lookback period.
lambda (float) : (float) The Lasso regularization parameter.
_emphasis (float) : (float) The emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) .
calcElasticNetLinReg(_src, _len, lambda1, lambda2, _emphasis, _condition)
Calculates an Elastic Net regression with optional emphasis.
Parameters:
_src (float) : (float) The source data series.
_len (int) : (int) The length of the lookback period.
lambda1 (float) : (float) L1 regularization parameter (Lasso).
lambda2 (float) : (float) L2 regularization parameter (Ridge).
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) .
calcRegHuber(_src, _len, delta, iterations, _emphasis, _condition)
Calculates a Huber regression using Iteratively Reweighted Least Squares (IRLS).
Parameters:
_src (float) : (float) The source data series.
_len (int) : (int) The length of the lookback period.
delta (float) : (float) Huber threshold parameter.
iterations (int) : (int) Number of IRLS iterations.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) .
calcRegLAD(_src, _len, iterations, _emphasis, _condition)
Calculates a Least Absolute Deviations (LAD) regression via IRLS.
Parameters:
_src (float) : (float) The source data series.
_len (int) : (int) The length of the lookback period.
iterations (int) : (int) Number of IRLS iterations for LAD.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) .
calcRegBayesian(_src, _len, priorMean, priorSpan, sigma, _emphasis, _condition)
Calculates a Bayesian linear regression with optional emphasis.
Parameters:
_src (float) : (float) The source data series.
_len (int) : (int) The length of the lookback period.
priorMean (float) : (float) The prior mean for the slope.
priorSpan (float) : (float) The prior variance (or span) for the slope.
sigma (float) : (float) The assumed standard deviation of residuals.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: (float ) .
calcRFromLinReg(_src, _len, _slope, _average, _y1, _condition)
Calculates the Pearson correlation coefficient (R) based on linear regression parameters.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_average (float) : (float) The average value of the source data series.
_y1 (float) : (float) The starting point (y-intercept of the oldest bar) for the linear regression.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast for efficiency.
Returns: (float) The Pearson correlation coefficient (R) adjusted for the direction of the slope.
calcRFromSource(_src, _len, _condition)
Calculates the correlation coefficient (R) using a specified length and source data.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The length of the lookback period.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast for efficiency.
Returns: (float) The correlation coefficient (R).
calcSlopeLengthZero(_src, _len, _minLen, _step, _condition)
Identifies the length at which the slope is flattest (closest to zero).
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length to consider (minimum of 2).
_minLen (int) : (int) The minimum length to start from (cannot exceed the max length).
_step (int) : (int) The increment step for lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length at which the slope is flattest.
calcSlopeLengthHighest(_src, _len, _minLen, _step, _condition)
Identifies the length at which the slope is highest.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length (minimum of 2).
_minLen (int) : (int) The minimum length to start from.
_step (int) : (int) The step for incrementing lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length at which the slope is highest.
calcSlopeLengthLowest(_src, _len, _minLen, _step, _condition)
Identifies the length at which the slope is lowest.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length (minimum of 2).
_minLen (int) : (int) The minimum length to start from.
_step (int) : (int) The step for incrementing lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length at which the slope is lowest.
calcSlopeLengthAbsolute(_src, _len, _minLen, _step, _condition)
Identifies the length at which the absolute slope value is highest.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length (minimum of 2).
_minLen (int) : (int) The minimum length to start from.
_step (int) : (int) The step for incrementing lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length at which the absolute slope value is highest.
calcRLengthZero(_src, _len, _minLen, _step, _condition)
Identifies the length with the lowest absolute R value.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length (minimum of 2).
_minLen (int) : (int) The minimum length to start from.
_step (int) : (int) The step for incrementing lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length with the lowest absolute R value.
calcRLengthHighest(_src, _len, _minLen, _step, _condition)
Identifies the length with the highest R value.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length (minimum of 2).
_minLen (int) : (int) The minimum length to start from.
_step (int) : (int) The step for incrementing lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length with the highest R value.
calcRLengthLowest(_src, _len, _minLen, _step, _condition)
Identifies the length with the lowest R value.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length (minimum of 2).
_minLen (int) : (int) The minimum length to start from.
_step (int) : (int) The step for incrementing lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length with the lowest R value.
calcRLengthAbsolute(_src, _len, _minLen, _step, _condition)
Identifies the length with the highest absolute R value.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The maximum lookback length (minimum of 2).
_minLen (int) : (int) The minimum length to start from.
_step (int) : (int) The step for incrementing lengths.
_condition (bool) : (bool) Flag to enable calculation. Set to true to calculate on every bar; otherwise, set to barstate.islast.
Returns: (int) The length with the highest absolute R value.
calcDevReverse(_src, _len, _slope, _y1, _inputDev, _emphasis, _condition)
Calculates the regressive linear deviation in reverse order, with optional emphasis on recent data.
Parameters:
_src (float) : (float) The source data.
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_y1 (float) : (float) The y-intercept (oldest bar) of the linear regression.
_inputDev (float) : (float) The input deviation multiplier.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: A 2-element tuple: .
calcDevForward(_src, _len, _slope, _y1, _inputDev, _emphasis, _condition)
Calculates the progressive linear deviation in forward order (oldest to most recent bar), with optional emphasis.
Parameters:
_src (float) : (float) The source data array, where _src is oldest and _src is most recent.
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_y1 (float) : (float) The y-intercept of the linear regression (value at the most recent bar, adjusted by slope).
_inputDev (float) : (float) The input deviation multiplier.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: A 2-element tuple: .
calcDevBalanced(_src, _len, _slope, _y1, _inputDev, _emphasis, _condition)
Calculates the balanced linear deviation with optional emphasis on recent or older data.
Parameters:
_src (float) : (float) Source data array, where _src is the most recent and _src is the oldest.
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_y1 (float) : (float) The y-intercept of the linear regression (value at the oldest bar).
_inputDev (float) : (float) The input deviation multiplier.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: A 2-element tuple: .
calcDevMean(_src, _len, _slope, _y1, _inputDev, _emphasis, _condition)
Calculates the mean absolute deviation from a forward-applied linear trend (oldest to most recent), with optional emphasis.
Parameters:
_src (float) : (float) The source data array, where _src is the most recent and _src is the oldest.
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_y1 (float) : (float) The y-intercept (oldest bar) of the linear regression.
_inputDev (float) : (float) The input deviation multiplier.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: A 2-element tuple: .
calcDevMedian(_src, _len, _slope, _y1, _inputDev, _emphasis, _condition)
Calculates the median absolute deviation with optional emphasis on recent data.
Parameters:
_src (float) : (float) The source data array (index 0 = oldest, index _len - 1 = most recent).
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_y1 (float) : (float) The y-intercept (oldest bar) of the linear regression.
_inputDev (float) : (float) The deviation multiplier.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns:
calcDevPercent(_y1, _inputDev, _condition)
Calculates the percent deviation from a given value and a specified percentage.
Parameters:
_y1 (float) : (float) The base value from which to calculate deviation.
_inputDev (float) : (float) The deviation percentage.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: A 2-element tuple: .
calcDevFitted(_len, _slope, _y1, _emphasis, _condition)
Calculates the weighted fitted deviation based on high and low series data, showing max deviation, with optional emphasis.
Parameters:
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_y1 (float) : (float) The Y-intercept (oldest bar) of the linear regression.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: A 2-element tuple: .
calcDevATR(_src, _len, _slope, _y1, _inputDev, _emphasis, _condition)
Calculates an ATR-style deviation with optional emphasis on recent data.
Parameters:
_src (float) : (float) The source data (typically close).
_len (int) : (int) The length of the lookback period.
_slope (float) : (float) The slope of the linear regression.
_y1 (float) : (float) The Y-intercept (oldest bar) of the linear regression.
_inputDev (float) : (float) The input deviation multiplier.
_emphasis (float) : (float) Emphasis factor: 0 for equal weight; >0 emphasizes recent bars; <0 emphasizes older bars.
_condition (bool) : (bool) Flag to enable calculation (true = calculate).
Returns: A 2-element tuple: .
calcPricePositionPercent(_top, _bot, _src)
Calculates the percent position of a price within a linear regression channel. Top=100%, Bottom=0%.
Parameters:
_top (float) : (float) The top (positive) deviation, corresponding to 100%.
_bot (float) : (float) The bottom (negative) deviation, corresponding to 0%.
_src (float) : (float) The source price.
Returns: (float) The percent position within the channel.
plotLinReg(_len, _y1, _y2, _slope, _devTop, _devBot, _scaleTypeLog, _lineWidth, _extendLines, _channelStyle, _colorFill, _colUpLine, _colDnLine, _colUpFill, _colDnFill)
Plots the linear regression line and its deviations, with configurable styles and fill.
Parameters:
_len (int) : (int) The lookback period for the linear regression.
_y1 (float) : (float) The starting y-value of the regression line.
_y2 (float) : (float) The ending y-value of the regression line.
_slope (float) : (float) The slope of the regression line (used to determine line color).
_devTop (float) : (float) The top deviation to add to the line.
_devBot (float) : (float) The bottom deviation to subtract from the line.
_scaleTypeLog (bool) : (bool) Use a log scale if true; otherwise, linear scale.
_lineWidth (int) : (int) The width of the plotted lines.
_extendLines (string) : (string) How lines should extend (none, left, right, both).
_channelStyle (string) : (string) The style of the channel lines (solid, dashed, dotted).
_colorFill (bool) : (bool) Whether to fill the space between the top and bottom deviation lines.
_colUpLine (color) : (color) Line color when slope is positive.
_colDnLine (color) : (color) Line color when slope is negative.
_colUpFill (color) : (color) Fill color when slope is positive.
_colDnFill (color) : (color) Fill color when slope is negative.
Nef33-Volume Footprint ApproximationDescription of the "Volume Footprint Approximation" Indicator
Purpose
The "Volume Footprint Approximation" indicator is a tool designed to assist traders in analyzing market volume dynamics and anticipating potential trend changes in price. It is inspired by the concept of a volume footprint chart, which visualizes the distribution of trading volume across different price levels. However, since TradingView does not provide detailed intrabar data for all users, this indicator approximates the behavior of a footprint chart by using available volume and price data (open, close, volume) to classify volume as buy or sell, calculate volume delta, detect imbalances, and generate trend change signals.
The indicator is particularly useful for identifying areas of high buying or selling activity, imbalances between supply and demand, delta divergences, and potential reversal points in the market. It provides specific signals for bullish and bearish trend changes, making it suitable for traders looking to trade reversals or confirm trends.
How It Works
The indicator uses volume and price data from each candlestick to perform the following calculations:
Volume Classification:
Classifies the volume of each candlestick as "buy" or "sell" based on price movement:
If the closing price is higher than the opening price (close > open), the volume is classified as "buy."
If the closing price is lower than the opening price (close < open), the volume is classified as "sell."
If the closing price equals the opening price (close == open), it compares with the previous close to determine the direction:
If the current close is higher than the previous close, it is classified as "buy."
If the current close is lower than the previous close, it is classified as "sell."
If the current close equals the previous close, the classification from the previous bar is used.
Delta Calculation:
Calculates the volume delta as the difference between buy volume and sell volume (buyVolume - sellVolume).
A positive delta indicates more buy volume; a negative delta indicates more sell volume.
Imbalance Detection:
Identifies imbalances between buy and sell volume:
A buy imbalance occurs when buy volume exceeds sell volume by a defined percentage (default is 300%).
A sell imbalance occurs when sell volume exceeds buy volume by the same percentage.
Delta Divergence Detection:
Positive Delta Divergence: Occurs when the price is falling (for at least 2 bars) but the delta is increasing or becomes positive, indicating that buyers are entering despite the price decline.
Negative Delta Divergence: Occurs when the price is rising (for at least 2 bars) but the delta is decreasing or becomes negative, indicating that sellers are entering despite the price increase.
Trend Change Signals:
Bullish Signal (trendChangeBullish): Generated when the following conditions are met:
There is a positive delta divergence.
The delta has moved from a negative value (e.g., -500) to a positive value (e.g., +200) over the last 3 bars.
There is a buy imbalance.
The price is near a historical support level (approximated as the lowest low of the last 50 bars).
Bearish Signal (trendChangeBearish): Generated when the following conditions are met:
There is a negative delta divergence.
The delta has moved from a positive value (e.g., +500) to a negative value (e.g., -200) over the last 3 bars.
There is a sell imbalance.
The price is near a historical resistance level (approximated as the highest high of the last 50 bars).
Visual Elements
The indicator is displayed in a separate panel below the price chart (overlay=false) and includes the following elements:
Volume Histograms:
Buy Volume: Represented by a green histogram. Shows the volume classified as "buy."
Sell Volume: Represented by a red histogram. Shows the volume classified as "sell."
Note: The histograms overlap, and the last plotted histogram (red) takes visual precedence, meaning the sell volume may cover the buy volume if it is larger.
Delta Line:
Delta Volume: Represented by a blue line. Shows the difference between buy and sell volume.
A line above zero indicates more buy volume; a line below zero indicates more sell volume.
A dashed gray horizontal line marks the zero level for easier interpretation.
Imbalance Backgrounds:
Buy Imbalance: Light green background when buy volume exceeds sell volume by the defined percentage.
Sell Imbalance: Light red background when sell volume exceeds buy volume by the defined percentage.
Divergence Backgrounds:
Positive Delta Divergence: Lime green background when a positive delta divergence is detected.
Negative Delta Divergence: Fuchsia background when a negative delta divergence is detected.
Trend Change Signals:
Bullish Signal: Green label with the text "Bullish Trend Change" when the conditions for a bullish trend change are met.
Bearish Signal: Red label with the text "Bearish Trend Change" when the conditions for a bearish trend change are met.
Information Labels:
Below each bar, a label displays:
Total Vol: The total volume of the bar.
Delta: The delta volume value.
Alerts
The indicator generates the following alerts:
Positive Delta Divergence: "Positive Delta Divergence Detected! Price is falling, but delta is increasing."
Negative Delta Divergence: "Negative Delta Divergence Detected! Price is rising, but delta is decreasing."
Bullish Trend Change Signal: "Bullish Trend Change Signal! Positive Delta Divergence, Delta Rise, Buy Imbalance, and Near Support."
Bearish Trend Change Signal: "Bearish Trend Change Signal! Negative Delta Divergence, Delta Drop, Sell Imbalance, and Near Resistance."
These alerts can be configured in TradingView to receive real-time notifications.
Adjustable Parameters
The indicator allows customization of the following parameters:
Imbalance Threshold (%): The percentage required to detect an imbalance between buy and sell volume (default is 300%).
Lookback Period for Divergence: Number of bars to look back for detecting price and delta trends (default is 2 bars).
Support/Resistance Lookback Period: Number of bars to look back for identifying historical support and resistance levels (default is 50 bars).
Delta High Threshold (Bearish): Minimum delta value 2 bars ago for the bearish signal (default is +500).
Delta Low Threshold (Bearish): Maximum delta value in the current bar for the bearish signal (default is -200).
Delta Low Threshold (Bullish): Maximum delta value 2 bars ago for the bullish signal (default is -500).
Delta High Threshold (Bullish): Minimum delta value in the current bar for the bullish signal (default is +200).
Practical Use
The indicator is useful for the following purposes:
Identifying Trend Changes:
The trend change signals (trendChangeBullish and trendChangeBearish) indicate potential price reversals. For example, a bullish signal near a support level may be an opportunity to enter a long position.
Detecting Divergences:
Delta divergences (positive and negative) can anticipate trend changes by showing a disagreement between price movement and underlying buying/selling pressure.
Finding Key Levels:
Imbalances (green and red backgrounds) often coincide with support and resistance levels, helping to identify areas where the market might react.
Confirming Trends:
A consistently positive delta in an uptrend or a negative delta in a downtrend can confirm the strength of the trend.
Identifying Failed Auctions:
Although not detected automatically, you can manually identify failed auctions by observing a price move to new highs/lows with decreasing volume in the direction of the move.
Limitations
Intrabar Data: It does not use detailed intrabar data, making it less precise than a native footprint chart.
Approximations: Volume classification and support/resistance detection are approximations, which may lead to false signals.
Volume Dependency: It requires reliable volume data, so it may be less effective on assets with inaccurate volume data (e.g., some forex pairs).
False Signals: Divergences and imbalances do not always indicate a trend change, especially in strongly trending markets.
Recommendations
Combine with Other Indicators: Use tools like RSI, MACD, support/resistance levels, or candlestick patterns to confirm signals.
Trade on Higher Timeframes: Signals are more reliable on higher timeframes like 1-hour or 4-hour charts.
Perform Backtesting: Evaluate the indicator's accuracy on historical data to adjust parameters and improve effectiveness.
Adjust Parameters: Modify thresholds (e.g., imbalanceThreshold or supportResistanceLookback) based on the asset and timeframe you are trading.
Conclusion
The "Volume Footprint Approximation" indicator is a powerful tool for analyzing volume dynamics and anticipating price trend changes. By classifying volume, calculating delta, detecting imbalances and divergences, and generating trend change signals, it provides traders with valuable insights into market buying and selling pressure. While it has limitations due to the lack of intrabar data, it can be highly effective when used in combination with other technical analysis tools and on assets with reliable volume data.
Forexsom MA Crossover SignalsA Trend-Following Trading Indicator for TradingView
Overview
This indicator plots two moving averages (MA) on your chart and generates visual signals when they cross, helping traders identify potential trend reversals. It is designed to be simple yet effective for both beginners and experienced traders.
Key Features
✅ Dual Moving Averages – Plots a Fast MA (default: 9-period) and a Slow MA (default: 21-period)
✅ Customizable MA Types – Choose between EMA (Exponential Moving Average) or SMA (Simple Moving Average)
✅ Clear Buy/Sell Signals – Displays "BUY" (green label) when the Fast MA crosses above the Slow MA and "SELL" (red label) when it crosses below
✅ Alerts – Get notified when new signals appear (compatible with TradingView alerts)
✅ Clean Visuals – Easy-to-read moving averages with adjustable colors
How It Works
Bullish Signal (BUY) → Fast MA crosses above Slow MA (suggests uptrend)
Bearish Signal (SELL) → Fast MA crosses below Slow MA (suggests downtrend)
Best Used For
✔ Trend-following strategies (swing trading, day trading)
✔ Confirming trend reversals
✔ Filtering trade entries in combination with other indicators
Customization Options
Adjust Fast & Slow MA lengths
Switch between EMA or SMA for smoother or more responsive signals
Why Use This Indicator?
Simple & Effective – No clutter, just clear signals
Works on All Timeframes – From scalping (1M, 5M) to long-term trading (4H, Daily)
Alerts for Real-Time Trading – Never miss a signal
Highlight 8AM-2PMallows 8am to 2pm highlights dawg sooooo goood if u wanna use
$5 if u feel like paying u can just tip me
Custom 6H Candle HighlightHighlights a certain 6H candle on the chart. Input which 6H Candle in the settings for the indicator.
Trend Breakout IndicatorCombines the RSI and MACD to form buy and entry signals. RSI levels can be modified, but start at 25 for oversold and 70 for overbought as I'm creating this for penny stocks, so wanted a safer overbought level but change it to whatever you'd like. Default RSI goes back to 9 days, but also customizable along with the standard 12, 26, 9 levels.
Entry levels signal when the RSI goes below 25, MACD has a bullish crossover, and when the price breaks above the average VPVR for that resistance level.
Exit levels signal when the RSI goes above 70, the MACD has a bearish crossover, and the price increases by 9%. The latter can be modified or removed, I just have it there as I designed this for penny stocks and 9% is usually a really easy breakout to hit to still lock in decent prices as well as having it be options-trader friendly.
First script I've ever made so any feedback or suggestions to improve it (hopefully as well as teaching me HOW to improve it) is very much appreciated.