BullBear with Volume-Percentile TP - Strategy [presentTrading] Happy New Year, everyone! I hope we have a fantastic year ahead.
It's been a while since I published an open script, but it's time to return.
This strategy introduces an indicator called Bull Bear Power, combined with an advanced take-profit system, which is the main innovative and educational aspect of this script. I hope all of you find some useful insights here. Welcome to engage in meaningful exchanges. This is a versatile tool suitable for both novice and experienced traders.
█ Introduction and How it is Different
Unlike traditional strategies that rely solely on price or volume indicators, this approach combines Bull Bear Power (BBP) with volume percentile analysis to identify optimal entry and exit points. It features a dynamic take-profit mechanism based on ATR (Average True Range) multipliers adjusted by volume and percentile factors, ensuring adaptability to diverse market conditions. This multifaceted strategy not only improves signal accuracy but also optimizes risk management, distinguishing it from conventional trading methods.
BTCUSD 6hr performance
Disable the visualization of Bull Bear Power (BBP) to clearly view the Z-Score.
█ Strategy, How it Works: Detailed Explanation
The BBP Strategy with Volume-Percentile TP utilizes several interconnected components to analyze market data and generate trading signals. Here's an overview with essential equations:
🔶 Core Indicators and Calculations
1. Exponential Moving Average (EMA):
- **Purpose:** Smoothens price data to identify trends.
- **Formula:**
EMA_t = (Close_t * (2 / (lengthInput + 1))) + (EMA_(t-1) * (1 - (2 / (lengthInput + 1))))
- Usage: Baseline for Bull and Bear Power.
2. Bull and Bear Power:
- Bull Power: `BullPower = High_t - EMA_t`
- Bear Power: `BearPower = Low_t - EMA_t`
- BBP:** `BBP = BullPower + BearPower`
- Interpretation: Positive BBP indicates bullish strength, negative indicates bearish.
3. Z-Score Calculation:
- Purpose: Normalizes BBP to assess deviation from the mean.
- Formula:
Z-Score = (BBP_t - bbp_mean) / bbp_std
- Components:
- `bbp_mean` = SMA of BBP over `zLength` periods.
- `bbp_std` = Standard deviation of BBP over `zLength` periods.
- Usage: Identifies overbought or oversold conditions based on thresholds.
🔶 Volume Analysis
1. Volume Moving Average (`vol_sma`):
vol_sma = (Volume_1 + Volume_2 + ... + Volume_vol_period) / vol_period
2. Volume Multiplier (`vol_mult`):
vol_mult = Current Volume / vol_sma
- Thresholds:
- High Volume: `vol_mult > 2.0`
- Medium Volume: `1.5 < vol_mult ≤ 2.0`
- Low Volume: `1.0 < vol_mult ≤ 1.5`
🔶 Percentile Analysis
1. Percentile Calculation (`calcPercentile`):
Percentile = (Number of values ≤ Current Value / perc_period) * 100
2. Thresholds:
- High Percentile: >90%
- Medium Percentile: >80%
- Low Percentile: >70%
🔶 Dynamic Take-Profit Mechanism
1. ATR-Based Targets:
TP1 Price = Entry Price ± (ATR * atrMult1 * TP_Factor)
TP2 Price = Entry Price ± (ATR * atrMult2 * TP_Factor)
TP3 Price = Entry Price ± (ATR * atrMult3 * TP_Factor)
- ATR Calculation:
ATR_t = (True Range_1 + True Range_2 + ... + True Range_baseAtrLength) / baseAtrLength
2. Adjustment Factors:
TP_Factor = (vol_score + price_score) / 2
- **vol_score** and **price_score** are based on current volume and price percentiles.
Local performance
🔶 Entry and Exit Logic
1. Long Entry: If Z-Score crosses above 1.618, then Enter Long.
2. Short Entry: If Z-Score crosses below -1.618, then Enter Short.
3. Exiting Positions:
If Long and Z-Score crosses below 0:
Exit Long
If Short and Z-Score crosses above 0:
Exit Short
4. Take-Profit Execution:
- Set multiple exit orders at dynamically calculated TP levels based on ATR and adjusted by `TP_Factor`.
█ Trade Direction
The strategy determines trade direction using the Z-Score from the BBP indicator:
- Long Positions:
- Condition: Z-Score crosses above 1.618.
- Short Positions:
- Condition: Z-Score crosses below -1.618.
- Exiting Trades:
- Long Exit: Z-Score drops below 0.
- Short Exit: Z-Score rises above 0.
This approach aligns trades with prevailing market trends, increasing the likelihood of successful outcomes.
█ Usage
Implementing the BBP Strategy with Volume-Percentile TP in TradingView involves:
1. Adding the Strategy:
- Copy the Pine Script code.
- Paste it into TradingView's Pine Editor.
- Save and apply the strategy to your chart.
2. Configuring Settings:
- Adjust parameters like EMA length, Z-Score thresholds, ATR multipliers, volume periods, and percentile settings to match your trading preferences and asset behavior.
3. Backtesting:
- Use TradingView’s backtesting tools to evaluate historical performance.
- Analyze metrics such as profit factor, drawdown, and win rate.
4. Optimization:
- Fine-tune parameters based on backtesting results.
- Test across different assets and timeframes to enhance adaptability.
5. Deployment:
- Apply the strategy in a live trading environment.
- Continuously monitor and adjust settings as market conditions change.
█ Default Settings
The BBP Strategy with Volume-Percentile TP includes default parameters designed for balanced performance across various markets. Understanding these settings and their impact is essential for optimizing strategy performance:
Bull Bear Power Settings:
- EMA Length (`lengthInput`): 21
- **Effect:** Balances sensitivity and trend identification; shorter lengths respond quicker but may generate false signals.
- Z-Score Length (`zLength`): 252
- **Effect:** Long period for stable mean and standard deviation, reducing false signals but less responsive to recent changes.
- Z-Score Threshold (`zThreshold`): 1.618
- **Effect:** Higher threshold filters out weaker signals, focusing on significant market moves.
Take Profit Settings:
- Use Take Profit (`useTP`): Enabled (`true`)
- **Effect:** Activates dynamic profit-taking, enhancing profitability and risk management.
- ATR Period (`baseAtrLength`): 20
- **Effect:** Shorter period for sensitive volatility measurement, allowing tighter profit targets.
- ATR Multipliers:
- **Effect:** Define conservative to aggressive profit targets based on volatility.
- Position Sizes:
- **Effect:** Diversifies profit-taking across multiple levels, balancing risk and reward.
Volume Analysis Settings:
- Volume MA Period (`vol_period`): 100
- **Effect:** Longer period for stable volume average, reducing the impact of short-term spikes.
- Volume Multipliers:
- **Effect:** Determines volume conditions affecting take-profit adjustments.
- Volume Factors:
- **Effect:** Adjusts ATR multipliers based on volume strength.
Percentile Analysis Settings:
- Percentile Period (`perc_period`): 100
- **Effect:** Balances historical context with responsiveness to recent data.
- Percentile Thresholds:
- **Effect:** Defines price and volume percentile levels influencing take-profit adjustments.
- Percentile Factors:
- **Effect:** Modulates ATR multipliers based on price percentile strength.
Impact on Performance:
- EMA Length: Shorter EMAs increase sensitivity but may cause more false signals; longer EMAs provide stability but react slower to market changes.
- Z-Score Parameters:*Longer Z-Score periods create more stable signals, while higher thresholds reduce trade frequency but increase signal reliability.
- ATR Multipliers and Position Sizes: Higher multipliers allow for larger profit targets with increased risk, while diversified position sizes help in securing profits at multiple levels.
- Volume and Percentile Settings: These adjustments ensure that take-profit targets adapt to current market conditions, enhancing flexibility and performance across different volatility environments.
- Commission and Slippage: Accurate settings prevent overestimation of profitability and ensure the strategy remains viable after accounting for trading costs.
Conclusion
The BBP Strategy with Volume-Percentile TP offers a robust framework by combining BBP indicators with volume and percentile analyses. Its dynamic take-profit mechanism, tailored through ATR adjustments, ensures that traders can effectively capture profits while managing risks in varying market conditions.
成交量
Trend Heuristics (+Signals)Trend Heuristics - Enhanced Rolling VWAP with Smart Signals
This indicator is an enhanced version of the Rolling VWAP (RVWAP) concept, originally based on PineCoders' ConditionalAverages library. It combines volume-weighted average price analysis with advanced signal detection for both sweeps and breakouts.
Core Features
1. Rolling VWAP System
- Implements a dynamic rolling VWAP that adapts to different timeframes
- Includes standard deviation bands for volatility measurement
- Offers flexible time period settings (fixed or auto-adjusting)
- Provides customizable visual elements including bands and fills
2. Dual Signal System
Sweep Signals
Detects high-probability reversal points with these conditions:
- Bullish Sweep:
- Opens above upper band
- Tests below upper band (low)
- Closes above upper band
- Shows stronger lower wick
- Closes above previous high
- Has favorable close position (upper 50% of candle)
- Bearish Sweep:
- Opens below lower band
- Tests above lower band (high)
- Closes below lower band
- Shows stronger upper wick
- Closes below previous low
- Has favorable close position (lower 50% of candle)
Breakout Signals
Identifies potential trend changes with these conditions:
- Bullish Breakout:
- Opens below VWAP
- Closes above upper band
- Indicates strong momentum shift upward
- Bearish Breakout:
- Opens above VWAP
- Closes below lower band
- Indicates strong momentum shift downward
Technical Details
Base Components
- Built upon PineCoders' ConditionalAverages library
- Incorporates custom alert system via CustomAlertLib
- Uses standard deviation for band calculations
Customization Options
- Adjustable standard deviation multiplier
- Flexible time period settings
- Independent controls for sweep and breakout signals
- Customizable visual elements (colors, sizes, positions)
- Custom alert message formatting
Use Cases
1. Trend Following:
- Use VWAP as dynamic support/resistance
- Monitor breakout signals for trend changes
2. Mean Reversion:
- Use sweep signals for counter-trend opportunities
- Standard deviation bands for range identification
3. Volume Analysis:
- VWAP provides volume-weighted price levels
- Helps identify significant price levels
Notes
- Best performed on liquid instruments with consistent volume
- Most effective on timeframes from 1hours to 4 hours and 1D, anything greater isn't very good
- Recommended to use in conjunction with other technical analysis tools
- Signals can be filtered based on higher timeframe trends
Credits
- Original Rolling VWAP concept by PineCoders
Buyside & Sellside Liquidity and FOMO & PANİK]LuxAlgo'nun Buy-Side ve Sell-Side Likidite İndikatörüne Gelişmiş Özellikler Ekledik
Buy-Side ve Sell-Side Likidite (Likidite Avı) göstergeleri, piyasa yapıcıların (market maker) manipülasyonlarını anlamak ve yüksek hacimli bölgelerdeki fiyat hareketlerini analiz etmek için önemli bir araçtır. LuxAlgo'nun bu göstergesi, kullanıcıların piyasanın likidite akışını daha iyi değerlendirmesini sağlar. Ancak, bu güçlü aracın işlevselliğini daha da geliştirmek için bazı stratejik iyileştirmeler ve eklemeler yaptık.
---
İndikatöre Eklediğimiz Özellikler
1. Likidite Eşiği ve Zaman Dilimlerine Göre Analiz
Kullanıcı, kısa, orta ve uzun dönem periyotlar belirleyerek farklı zaman dilimlerinde likidite hareketlerini analiz edebilir.
Likidite Eşiği (%) parametresi sayesinde fiyat değişim oranlarına göre long (alım) ve short (satım) seviyeleri tespit edilir.
Her dönem için hacim eşik kontrolleri uygulanarak sadece yüksek hacimli hareketler dikkate alınır.
2. Long ve Short Likidite Bölgelerinin Tespiti
Buy-Side (Long) Likidite Bölgeleri: Fiyatın altındaki long giriş seviyeleri belirlenir ve fiyat bu seviyeye ulaştığında tepki sinyalleri oluşturulur.
Sell-Side (Short) Likidite Bölgeleri: Fiyatın üstündeki short giriş seviyeleri tespit edilir ve seviyeler grafik üzerinde görselleştirilir.
Bu bölgeler, likidite tuzaklarının olabileceği yerlerde market maker manipülasyonlarını tespit etmek için kullanılır.
3. Yüksek Hacimli Mumların Renklendirilmesi
Hacim analiziyle, yüksek hacimli mumlar farklı renklerle işaretlenerek fiyat hareketlerinin dinamiği daha net bir şekilde gözlemlenir.
Örneğin, hacim eşik seviyelerini aşan mumlar beyaz, sarı veya mavi gibi belirgin renklerle vurgulanır.
4. Wick ve Hacim Bazlı Long/Short Tuzaklarının Analizi
Mum gölgelerinin (wick) uzunluk oranları, ATR (Ortalama Gerçek Aralık) ve hacim değişimi baz alınarak long trap ve short trap tuzakları tespit edilir.
Bu tuzaklar grafik üzerinde belirgin şekilde işaretlenir ve kullanıcıya FOMO (kaçırma korkusu) ve Panik gibi piyasa psikolojisi sinyalleriyle desteklenir.
5. Likidite Bölgelerine Yakınlık ve Alarm Sistemleri
Fiyatın belirlenen likidite bölgelerine ne kadar yakın olduğunu ölçen algoritma ekledik. Bu sayede:
Üst likidite bölgesine %2’den az bir mesafede olan fiyat hareketleri analiz edilir.
Orta likidite bölgesi ve alt likidite bölgesine yakınlık için de aynı metodoloji kullanılır.
Alarm sistemi ile long trap veya short trap oluştuğunda kullanıcı uyarılır.
---
FOMO ve Panik Algoritması
Bu güncellemeler, yatırımcı psikolojisini analiz etmek için ek parametreler içerir:
FOMO (Fear of Missing Out):
RSI seviyesinin yüksek olduğu, fiyatın üst veya orta likidite bölgelerine yakınlaştığı ve ani fiyat/hacim artışlarının görüldüğü durumlarda bir FOMO sinyali oluşturulur.
Bu sinyal, yatırımcının bilinçsiz alım yapmaktan kaçınmasını sağlar.
Panik:
RSI seviyesi düşük, fiyatın alt veya orta likidite bölgesine yakın olduğu ve ani düşüşlerin görüldüğü durumlarda panik sinyali tetiklenir.
Bu, yatırımcıların aceleyle satış yapmalarını önleyecek şekilde tasarlanmıştır.
---
Geliştirmelerin Yararları
1. Manipülasyonların Önlenmesi:
Likidite bölgelerine göre fiyat hareketleri analiz edilerek market maker’ın manipülasyonlarına karşı yatırımcıların korunması hedeflenir.
2. Tepki Seviyeleri ile Daha Güçlü Strateji:
Long ve short likidite bölgelerinin görselleştirilmesi, alım-satım stratejilerinde daha güvenilir sinyaller sağlar.
3. Psikolojik Bariyerleri Anlama:
FOMO ve Panik sinyalleriyle yatırımcı davranışlarının piyasa üzerindeki etkisi daha iyi analiz edilir.
4. Hacim ve Volatilite Bazlı Gelişmiş Filtreleme:
Hacim ve volatilite analizleri, yanlış sinyalleri minimuma indirir.
---
Sonuç
Bu güncellemelerle, LuxAlgo'nun orijinal Buy-Side & Sell-Side Likidite göstergesi daha güçlü bir araç haline getirildi. Kullanıcılar, piyasa yapıcıların hedefleyebileceği önemli seviyeleri tespit ederek daha bilinçli işlemler yapabilir. Hacim, likidite, RSI ve psikolojik bariyerler gibi birden fazla değişkeni bir araya getiren bu sistem, özellikle kripto para piyasasında daha sağlam bir analiz sağlar.
Shendeng - VWAP + Money Flow + RSI + Sto RSIBlue Waves:
1.bw1 and bw2: Calculated using the Exponential Moving Average (EMA) and Simple Moving Average (SMA) of the price, respectively. They are used to capture short-term and medium-term price trends.
2.VWAP (Volume Weighted Average Price): Provides an average price level, commonly used to identify support and resistance levels.
Money Flow:
1.By calculating the money flow over specific periods, it helps in determining the buying and selling strength in the market.
2.Positive Money Flow (Green): Indicates stronger buying power.Negative Money Flow (Red): Indicates stronger selling power.
Relative Strength Index (RSI) and Its Derived Indicators:
1.rsiMod: A smoothed Relative Strength Index based on the Stochastic indicator, used to determine overbought and oversold conditions.
2.stcRsiMod: Another RSI-derived indicator based on the Stochastic indicator, further smoothed to reduce noise.
Overbought/Oversold Levels and Triggers:
1.Over Bought Level 1: Default value is 60.
2.Over Sold Level 1: Default value is -60.
3.Trigger 1 and Trigger 2: Thresholds used to generate specific signals.
Meaning of Small Circle Labels:
1.Green Small Circle (Buy Signal)
2.Red Small Circle (Sell Signal)
Color Meanings:
1.Blue Waves (Lt Blue Wave and Blue Wave):
Lt Blue Wave: Light blue, used to display short-term price fluctuation trends.
Blue Wave: Dark blue, displays medium-term price trends.
2.VWAP (Volume Weighted Average Price):
Color: Light yellow, semi-transparent, used to highlight the average price level.
3.Money Flow:
Positive Money Flow: Green, indicates stronger buying power.
Negative Money Flow: Red, indicates stronger selling power.
4.RSI and Sto RSI:
RSI: Purple, used to display the Relative Strength Index.
Sto RSI: Changes color based on the relationship between rsiMod and stcRsiMod. Green when rsiMod > stcRsiMod, and red otherwise.
5.Overbought/Oversold Levels and Triggers:
Over Bought Level 1 (OB 1 Solid) and Over Sold Level 1 (OS 1 Solid): White semi-transparent lines, used to mark key overbought and oversold areas.
Trigger 1 and Trigger 2: White semi-transparent small circles, used to mark specific trigger levels.
Usage Scenarios:
1.Identifying Trend Reversal Points: By observing the crossover points of bw1 and bw2, traders can identify potential reversal points for short-term and medium-term trends.
2.Assessing Overbought and Oversold Conditions: When the indicator enters overbought or oversold regions, combined with other signals (such as crossovers), traders can determine the possibility of a reversal.
3.Money Flow Analysis: By observing changes in money flow, traders can understand the buying and selling strength in the market, enabling more informed trading decisions.
4.Assisting Decision-Making: Small circle labels provide clear buy and sell signals, helping traders make quick decisions in complex market environments.
蓝色波动线(Blue Waves):
1.bw1 和 bw2:通过对价格的指数移动平均(EMA)和简单移动平均(SMA)计算得出,用于捕捉价格的短期和中期趋势。
2.VWAP(成交量加权平均价):提供一个价格的平均水平,常用于识别支撑和阻力位。
资金流动(Money Flow):
1.通过计算特定周期内的资金流动,帮助判断市场的买卖力量。
2.正资金流(绿色)表示买方力量较强,负资金流(红色)表示卖方力量较强。
相对强弱指数(RSI)及其衍生指标:
1.rsiMod:基于随机指标(Stochastic)的平滑相对强弱指数,用于判断超买和超卖状态。
2.stcRsiMod:另一种基于随机指标的RSI衍生指标,进一步平滑以减少噪音。
超买/超卖水平和触发器:
1.Over Bought Level 1(超买水平1):默认值为60。
2.Over Sold Level 1(超卖水平1):默认值为-60。
3.Trigger 1 和 Trigger 2:用于生成特定信号的阈值。
小圆点标签的含义:
1.绿色小圆点(Buy 信号)
2.红色小圆点(SELL 信号)
颜色含义:
1.蓝色波动线(Lt Blue Wave 和 Blue Wave):
Lt Blue Wave:浅蓝色,用于显示较短期的价格波动趋势。
Blue Wave:深蓝色,显示中期价格趋势。
2.VWAP(成交量加权平均价):
颜色:浅黄色,半透明,用于突出显示平均价格水平。
3.资金流动(Money Flow):
正资金流:绿色,表示买方力量较强。
负资金流:红色,表示卖方力量较强。
4.RSI 和 Sto RSI:
RSI:紫色,用于显示相对强弱指数。
Sto RSI:根据 rsiMod 和 stcRsiMod 的关系变化颜色,rsiMod > stcRsiMod 时为绿色,反之为红色。
5.超买/超卖水平和触发器:
超买水平1(OB 1 Solid)和超卖水平1(OS 1 Solid):白色半透明线条,用于标记关键的超买和超卖区域。
触发器1 和触发器2:白色半透明小圆点,用于标记特定的触发器水平。
使用场景:
1.识别趋势转折点:通过观察 bw1 和 bw2 的交叉点,交易者可以识别短期和中期趋势的潜在转折点。
2.判断超买和超卖状态:当指标进入超买或超卖区域时,结合其他信号(如交叉点),交易者可以判断是否存在反转的可能性。
3.资金流动分析:通过观察资金流动的变化,交易者可以了解市场的买卖力量,从而做出更明智的交易决策。
4.辅助决策:小圆点标签提供了明确的买入和卖出信号,帮助交易者在复杂的市场环境中快速做出决策。
whales/ballenas/鯨魚/baleias/киты/balene/ by Ger Whale Sniper y Whale jumping out of the Ocean son dos indicadores por separados ambos creados por Blackcat 1402, yo los integre en un solo indicador. Sirve para detectar compras de ballenas.
Volume Price Action Trend## Description
An advanced technical analysis indicator that combines volume, price action, and trend analysis with dynamic parameter adjustment based on market volatility. This indicator helps identify high-probability trade setups using multiple confirmation factors.
## Features
- Dynamic parameter adjustment based on market conditions
- Volume-weighted price action analysis
- Trend strength measurement
- Visual signals for entry/exit points
- EMA-based trend confirmation
## Inputs
- ATR Period: Dynamically adjusts between 10-21 based on volatility
- EMA Period: Adapts between 14-34 based on price volatility
- Volume Period: Self-adjusts based on ATR changes
## Signals
- Green triangles: Long entry opportunities
- Red triangles: Short entry opportunities
- Blue line: Dynamic EMA trend line
- Colored candles: Volume-confirmed price action
## Usage
1. Add to chart for automatic trend analysis
2. Monitor trend strength value for momentum confirmation
3. Use green/red triangles for potential entry points
4. Consider EMA line for stop placement
5. Watch volume confirmation for trade validation
## Notes
- Best used on timeframes 10 minutes and above
- Combine with other indicators for confirmation
- Trend strength above 1.0 indicates strong trend
- Higher volatility automatically adjusts for faster response
- Lower volatility increases periods for noise reduction
EMA 200 Strategy with Signals SCLAPING STRATEGY (FLIPPING)Use 1MTF it's only for scalping can also be used in higher TF test it and use it
Institutional Analysis NASDAQ100 & US30Script para operar NAS100 & US30 con relación 3 a 1 usando análisis institucional
thinkCNE - VolumeWorks the same as Relative volume - colour volume bars based on average volume.
i.e. if volume is 2x higher than the 10 day average, the volume bar is coloured blue.
thinkCNE - VolumeWorks the same as Relative volume - colour volume bars based on average volume.
i.e. if volume is 2x higher than the 10 day average, the volume bar is coloured blue.
Volume Standard Deviation Alert GusPurpose
The script detects and alerts traders when the volume of a trading asset significantly exceeds a calculated threshold based on the standard deviation of volume over a specified lookback period. It optionally filters these alerts based on whether the price action is bullish or bearish.
Key Components
Inputs
lookback (default: 20)
The number of bars to consider when calculating the moving average and standard deviation of volume.
stdDevFactor (default: 2.0)
The multiplier for the standard deviation to determine the threshold for a volume spike.
alertOnClose (default: true)
Determines whether alerts should only be triggered after the bar has closed.
checkBullBear (default: false)
Enables filtering of alerts based on the bullishness or bearishness of the bar.
Calculations
volSMA
The simple moving average (SMA) of the volume over the lookback period.
volStd
The standard deviation of the volume over the lookback period.
threshold
The alert threshold is calculated as:
Threshold
=
volSMA
+
(
stdDevFactor
×
volStd
)
Threshold=volSMA+(stdDevFactor×volStd)
isBullish & isBearish
Determines whether the current bar is bullish (close > open) or bearish (close < open).
volumeSpikeCondition
A condition that triggers when the current volume exceeds the calculated threshold.
bullishCondition & bearishCondition
Refines the spike condition by requiring the bar to be bullish or bearish when checkBullBear is enabled.
finalCondition
The ultimate alert condition based on the user’s preference for bullish/bearish filtering.
finalTrigger
Ensures the alert only triggers at bar close if alertOnClose is set to true.
Visualization
Plots the SMA of the volume (volSMA) and the threshold line (threshold), helping traders visually understand the conditions.
Histograms the current volume and colors the bars:
Red: Volume exceeds the threshold.
Blue: Volume is below the threshold.
Alerts
The script generates an alert message when the finalTrigger condition is met:
"Bullish Volume Spike!" if the bar is bullish.
"Bearish Volume Spike!" if the bar is bearish.
"High Volume Spike!" if no bull/bear filter is applied.
Alerts are sent using alert() with the message and set to trigger once per bar close.
Usage
Traders can use this script to identify unusual volume activity, which often precedes significant price movements.
Customizability allows traders to tune the lookback period, standard deviation multiplier, and whether to filter for bullish/bearish spikes.
Visual and audible cues help in identifying important market events in real time.
This indicator is particularly useful for spotting market breakouts or breakdowns driven by high trading activity.
Mean Reversion with Volume ProfileScript Name: Mean Reversion with Volume Profile
Short Name: MRVP
Author: piligrimius82
Version: 1.0
Date: 01/05/2025
1. Overview
The Mean Reversion with Volume Profile (MRVP) indicator is a powerful tool designed to identify potential trading opportunities based on the principle of mean reversion, enhanced with insights from volume profile analysis. This indicator combines several popular technical indicators, including Bollinger Bands, Relative Strength Index (RSI), Moving Average Convergence Divergence (MACD), and Stochastic Oscillator, along with a custom-calculated Volume Profile to pinpoint high-probability reversal zones.
Mean reversion is a theory suggesting that prices and returns eventually move back towards the mean or average. This indicator helps traders identify when an asset's price has deviated significantly from its average and may be poised for a reversal. The inclusion of Volume Profile adds another layer of confirmation, providing insights into significant price levels based on trading volume.
2. Key Features
Multiple Indicator Integration: Combines Bollinger Bands, RSI, MACD, and Stochastic Oscillator for comprehensive overbought/oversold analysis.
Advanced Volume Profile Calculation: Calculates and displays the Point of Control (POC) based on historical volume data, highlighting significant price levels.
Customizable Parameters: Offers adjustable settings for all indicators, allowing traders to fine-tune the indicator to their specific trading style and market conditions.
Visual Alerts: Provides optional background color changes to visually highlight potential buy and sell zones.
Alert Conditions: Includes built-in alert conditions for mean reversion buy and sell signals, enabling traders to receive notifications when potential opportunities arise.
Optimized for higher time frames: It is recommended that this script be used on a 4-hour time frame or higher.
3. How it Works
The MRVP indicator identifies potential mean reversion opportunities by analyzing price action in conjunction with volume data.
3.1. Mean Reversion Signals:
Overbought Conditions: When the price moves above the upper Bollinger Band, the RSI exceeds the overbought threshold (default 70), and the Stochastic Oscillator is also in the overbought zone (default 80), a potential sell signal is generated.
Oversold Conditions: When the price moves below the lower Bollinger Band, the RSI falls below the oversold threshold (default 30), and the Stochastic Oscillator is in the oversold zone (default 20), a potential buy signal is generated.
3.2. Volume Profile (Point of Control - POC):
The indicator calculates the Volume Profile over a user-defined lookback period.
It determines the Point of Control (POC), which is the price level with the highest traded volume within that period.
The POC is plotted as a prominent visual marker on the chart, representing a significant level of support or resistance.
3.3. Combined Analysis:
The indicator encourages traders to look for confluence between mean reversion signals (from Bollinger Bands, RSI, and Stochastic) and the POC.
For example, a price rejection at a high volume node near the upper Bollinger Band could signal a strong mean reversion opportunity.
The MACD indicator is used to further confirm the trend's momentum.
4. Input Parameters
The following parameters can be customized within the indicator settings:
4.1. Bollinger Bands:
bbLength (default: 20): The length (number of periods) used for calculating the Bollinger Bands.
bbStdDev (default: 2.0): The standard deviation multiplier used to determine the width of the bands.
4.2. Relative Strength Index (RSI):
rsiLength (default: 14): The length (number of periods) used for calculating the RSI.
rsiOverbought (default: 70): The RSI level considered overbought.
rsiOversold (default: 30): The RSI level considered oversold.
4.3. Moving Average Convergence Divergence (MACD):
macdFastLength (default: 12): The length of the fast-moving average.
macdSlowLength (default: 26): The length of the slow-moving average.
macdSignalLength (default: 9): The length of the signal line.
4.4. Stochastic Oscillator:
stochLength (default: 14): The length (number of periods) used for calculating the Stochastic Oscillator.
stochK (default: 3): The smoothing period for the %K line.
stochD (default: 3): The smoothing period for the %D line.
stochOverbought (default: 80): The Stochastic level considered overbought.
stochOversold (default: 20): The Stochastic level considered oversold.
4.5. Volume Profile:
vpLength (default: 200): The lookback period (number of bars) used for calculating the Volume Profile. It is recommended to use higher values, especially on higher timeframes.
5. How to Use
Add to Chart: Add the "Mean Reversion with Volume Profile (MRVP)" indicator to your TradingView chart.
Customize Inputs (Optional): Adjust the input parameters to your preferred settings.
Observe Signals: Watch for potential buy (oversold) and sell (overbought) signals generated by the combination of indicators.
Consider the POC: Pay attention to the Point of Control (POC) plotted on the chart. Price reactions near the POC can provide valuable trading insights.
Confirm with Other Analysis: Use the MRVP indicator in conjunction with other technical analysis techniques and your overall trading strategy.
6. Important Considerations
No Guarantee of Profit: Like any trading indicator, the MRVP indicator does not guarantee profits and should not be used as the sole basis for trading decisions.
Backtesting and Optimization: It is highly recommended to backtest the indicator with different parameter settings on historical data to evaluate its performance and optimize it for specific assets and timeframes.
Risk Management: Always implement proper risk management techniques, such as setting stop-loss orders, to limit potential losses.
Market Conditions: The effectiveness of mean reversion strategies can vary depending on market conditions. They tend to perform better in range-bound markets and may be less effective in strongly trending markets.
Higher Timeframes: Due to the nature of Volume Profile calculations, using this indicator on higher timeframes (e.g., 4-hour, daily) is generally recommended for more reliable signals.
7. Disclaimer
This indicator is for educational and informational purposes only and should not be considered financial advice. Trading involves risk, and past performance is not indicative of future results. 1 Always conduct your own 2 thorough research and due diligence before making any trading decisions.
MAYURGAJJAR999@GMAIL.COM//@version=6
indicator("VWAP + Supertrend (Merged)", overlay=true, timeframe="", timeframe_gaps=true)
// VWAP Settings
hideonDWM = input(false, title="Hide VWAP on 1D or Above", group="VWAP Settings", display=display.data_window)
var anchor = input.string(defval="Session", title="Anchor Period", options= , group="VWAP Settings")
src = input(title="Source", defval=hlc3, group="VWAP Settings", display=display.data_window)
offset = input.int(0, title="Offset", group="VWAP Settings", minval=0, display=display.data_window)
BANDS_GROUP = "Bands Settings"
calcModeInput = input.string("Standard Deviation", "Bands Calculation Mode", options= , group=BANDS_GROUP, tooltip="Determines the units used to calculate the distance of the bands.")
showBand_1 = input(true, title="", group=BANDS_GROUP, inline="band_1")
bandMult_1 = input.float(1.0, title="Bands Multiplier #1", group=BANDS_GROUP, inline="band_1", step=0.5, minval=0)
showBand_2 = input(false, title="", group=BANDS_GROUP, inline="band_2")
bandMult_2 = input.float(2.0, title="Bands Multiplier #2", group=BANDS_GROUP, inline="band_2", step=0.5, minval=0)
showBand_3 = input(false, title="", group=BANDS_GROUP, inline="band_3")
bandMult_3 = input.float(3.0, title="Bands Multiplier #3", group=BANDS_GROUP, inline="band_3", step=0.5, minval=0)
cumVolume = ta.cum(volume)
if barstate.islast and cumVolume == 0
runtime.error("No volume is provided by the data vendor.")
new_earnings = request.earnings(syminfo.tickerid, earnings.actual, barmerge.gaps_on, barmerge.lookahead_on, ignore_invalid_symbol=true)
new_dividends = request.dividends(syminfo.tickerid, dividends.gross, barmerge.gaps_on, barmerge.lookahead_on, ignore_invalid_symbol=true)
new_split = request.splits(syminfo.tickerid, splits.denominator, barmerge.gaps_on, barmerge.lookahead_on, ignore_invalid_symbol=true)
isNewPeriod = switch anchor
"Earnings" => not na(new_earnings)
"Dividends" => not na(new_dividends)
"Splits" => not na(new_split)
"Session" => timeframe.change("D")
"Week" => timeframe.change("W")
"Month" => timeframe.change("M")
"Quarter" => timeframe.change("3M")
"Year" => timeframe.change("12M")
"Decade" => timeframe.change("12M") and year % 10 == 0
"Century" => timeframe.change("12M") and year % 100 == 0
=> false
isEsdAnchor = anchor == "Earnings" or anchor == "Dividends" or anchor == "Splits"
if na(src ) and not isEsdAnchor
isNewPeriod := true
float vwapValue = na
float upperBandValue1 = na
float lowerBandValue1 = na
float upperBandValue2 = na
float lowerBandValue2 = na
float upperBandValue3 = na
float lowerBandValue3 = na
if not (hideonDWM and timeframe.isdwm)
= ta.vwap(src, isNewPeriod, 1)
vwapValue := _vwap
stdevAbs = _stdevUpper - _vwap
bandBasis = calcModeInput == "Standard Deviation" ? stdevAbs : _vwap * 0.01
upperBandValue1 := _vwap + bandBasis * bandMult_1
lowerBandValue1 := _vwap - bandBasis * bandMult_1
upperBandValue2 := _vwap + bandBasis * bandMult_2
lowerBandValue2 := _vwap - bandBasis * bandMult_2
upperBandValue3 := _vwap + bandBasis * bandMult_3
lowerBandValue3 := _vwap - bandBasis * bandMult_3
plot(vwapValue, title="VWAP", color=#2962FF, offset=offset)
upperBand_1 = plot(upperBandValue1, title="Upper Band #1", color=color.green, offset=offset, display=showBand_1 ? display.all : display.none)
lowerBand_1 = plot(lowerBandValue1, title="Lower Band #1", color=color.green, offset=offset, display=showBand_1 ? display.all : display.none)
fill(upperBand_1, lowerBand_1, title="Bands Fill #1", color=color.new(color.green, 95), display=showBand_1 ? display.all : display.none)
// Supertrend Settings
atrPeriod = input.int(10, "ATR Length", minval=1)
factor = input.float(3.0, "Factor", minval=0.01, step=0.01)
= ta.supertrend(factor, atrPeriod)
supertrend := barstate.isfirst ? na : supertrend
upTrend = plot(direction < 0 ? supertrend : na, "Up Trend", color=color.green, style=plot.style_linebr)
downTrend = plot(direction < 0 ? na : supertrend, "Down Trend", color=color.red, style=plot.style_linebr)
bodyMiddle = plot(barstate.isfirst ? na : (open + close) / 2, "Body Middle", display=display.none)
fill(bodyMiddle, upTrend, color.new(color.green, 90), fillgaps=false)
fill(bodyMiddle, downTrend, color.new(color.red, 90), fillgaps=false)
// Alerts for Supertrend
alertcondition(direction > direction, title='Downtrend to Uptrend', message='Supertrend switched from Downtrend to Uptrend.')
alertcondition(direction < direction, title='Uptrend to Downtrend', message='Supertrend switched from Uptrend to Downtrend.')
alertcondition(direction != direction, title='Trend Change', message='Supertrend switched direction.')
Volume 2x Average This script helps traders identify stocks or instruments experiencing unusually high trading volume compared to their average volume over a user-defined period. The key features include:
1. Volume 2x Average Filter:
Highlights bars where the current volume is greater than twice the average volume for the selected period.
2. Dynamic Average Period:
Allows users to specify the period for calculating the average volume (e.g., 1 day, 5 days, etc.).
3. Color-Coded Bars:
• Green Bars: Indicate bullish candlesticks where the closing price is higher than the
opening price.
• Red Bars: Indicate bearish candlesticks where the closing price is lower than the
opening price.
4. Optional Bar Visibility:
Users can toggle the visibility of the highlighted volume bars, providing flexibility for clean chart analysis.
5. Average Volume Line:
Plots the average volume as a blue line for reference.
Use Case:
This script is ideal for traders looking to identify potential breakouts, reversals, or key market movements driven by significant volume spikes. By dynamically adjusting the average period and toggling bar visibility, users can tailor the script to fit various trading strategies and timeframes.
Inputs:
1. Show 2x Volume Bars:
• Toggle to enable or disable the display of the highlighted volume bars.
2. Average Volume Period:
• Specify the number of periods (e.g., 1 for 1 day, 5 for 5 days) to calculate the average
volume.
Disclaimer:
This script is for educational purposes only and does not constitute financial advice. Use it alongside your analysis and trading strategy.
Last Earnings AVWAP
Indicator to automatically anchor a VWAP on last earnings. By anchoring to earnings events, this indicator helps traders identify significant price levels where institutional activity may cluster after fundamental catalysts.
Key features:
Automatically resets and recalculates VWAP from each earnings release
Detects high-volume breakouts using customizable volume threshold (default 1.5x average volume)
Includes visual alerts for potential breakout opportunities
Uses rolling volume analysis over 6 bars to filter out noise
Trading considerations:
The indicator can help identify institutional participation levels post-earnings, particularly useful for:
Tracking price acceptance above/below key earnings-anchored levels
Identifying potential support/resistance zones based on post-earnings price discovery
Filtering meaningful breakouts through volume confirmation
Distribution & Follow-Through Day MarkerMarks D or F on candles based on IBD rule.
Distribution day: The loss must be at least -0.2%; the volume is higher than prior trading day.
Follow through day: The gain must be at least 1.2%; the volume is higher than prior trading day.
Dashed DMI by Cryptos RocketThe Directional Movement Index (DMI) is a well-known indicator in technical analysis, created by J. Welles Wilder. It is designed to identify the strength of a trend in a given market, providing traders with insights into both the direction and momentum of price movements. This script is a custom implementation of the DMI that plots the ADX (Average Directional Index), +DI (Positive Directional Indicator), and -DI (Negative Directional Indicator).
Dashed DMI Key Features:
1. Directional Movement Indicators:
- The ADX line, shown in orange, helps determine the strength of the trend without indicating its direction. Values above 25 suggest a strong trend, while values below 20 indicate a weak trend.
- The +DI line, shown in green, measures the strength of upward movement in the price. It identifies if the market is experiencing a strong uptrend.
- The -DI line, shown in red, measures the strength of downward price movement. It signals when there is a strong downtrend.
2. Customizable Dashed Line:
- The script includes a customizable dashed line, which represents a critical level on the chart that traders can use as a reference. The dashed line is adjustable through the script’s settings, allowing the trader to set a desired level, color, style, and thickness. The default level is set to 30, a common threshold in trend-following systems, but users can change it according to their preferences.
- The dashed line’s transparency and visibility can be toggled using the input settings, making it adaptable to different trading strategies or visual preferences.
3. Alerts:
- The script provides customizable alert conditions based on the relationship between the ADX, +DI, and -DI lines with the dashed line. These alerts include:
- When ADX crosses above or below the dashed line, signaling a shift in trend strength.
- When +DI or -DI cross the dashed line, indicating a change in the trend's directionality (bullish or bearish).
- Alerts for crossovers (when one line crosses another) and crossunders (when one line falls below another), which provide key entry or exit signals for traders.
4. Customizable Visual Parameters:
- The script is designed with flexibility in mind. The user can modify the line styles, thickness, and colors. The ADX is plotted in orange with a thickness of 2, the +DI is plotted in green, and the -DI is plotted in red. These lines’ thicknesses can be customized, ensuring that they remain visible regardless of the timeframe or chart zoom level.
- The script also provides options to adjust the dashed line’s color and style (solid, dotted, or dashed), enabling a fully customized charting experience that suits individual preferences.
Understanding the Components of the DMI
1. ADX (Average Directional Index):
The ADX is a smoothed version of the difference between the +DI and -DI lines, used to measure the strength of a trend. It does not provide any directional indication but simply quantifies whether the trend is strong or weak.
- Strength Indicators: A rising ADX indicates a strengthening trend, while a falling ADX signals weakening trend strength. Traders often consider an ADX reading above 25 as an indication of a strong trend, either up or down, and readings below 20 as suggesting a lack of trend or a sideways market.
- The ADX is plotted in the script using an orange color, making it easy for traders to distinguish it from the directional lines.
2. +DI (Positive Directional Indicator):
The +DI line measures the strength of upward price movement. It rises when the market’s upward movement is stronger than its downward movement.
- A rising +DI is a signal that the market is moving in a bullish direction. When +DI crosses above the -DI, it can indicate the start of an uptrend.
- The +DI is plotted in green, representing bullish momentum.
3. -DI (Negative Directional Indicator):
The -DI line tracks the strength of downward price movement. It rises when the market’s downward movement is stronger than its upward movement.
- A rising -DI suggests bearish momentum, and when the -DI crosses above the +DI, it can signal the beginning of a downtrend.
- The -DI is plotted in red, symbolizing bearish momentum.
Customizable Inputs and Settings
This DMI script allows traders to adjust several parameters based on their preferences:
- ADX Smoothing (lensig): This setting controls the smoothing of the ADX line, with values ranging from 1 to 50. A larger smoothing value can help reduce noise in the ADX and make trends clearer, while a smaller value reacts more quickly to price changes.
- DI Length (len): This input controls the period used for calculating the +DI and -DI lines. A shorter period results in a more sensitive indicator, whereas a longer period produces smoother, more stable signals.
- Dashed Line Settings: Traders can choose to show or hide the dashed line and can adjust its level, color, thickness, and style. This customization allows traders to adapt the indicator to their specific strategies and charting preferences.
Alerts and Signals
With the alert conditions set up in the script, traders can receive notifications when critical events occur, such as:
- ADX Crossing Above/Below the Dashed Line: This is typically a signal of an emerging trend.
- +DI and -DI Crossovers and Crossunders: These are valuable signals for identifying potential entry and exit points in trending markets.
Conclusion
This custom DMI Pine Script provides traders with a powerful tool to analyze market trends in real-time. By visualizing the ADX, +DI, and -DI indicators with customizable inputs, this script enables traders to gauge the strength and direction of a trend and make informed decisions about their trading strategies. The ability to set alerts based on specific conditions adds another layer of automation, ensuring that traders never miss an important signal. The script’s flexibility allows it to be adapted for various trading styles and market conditions, making it an invaluable addition to any trader’s toolkit.
Previous Candle Sweep IndicatorThis script identifies candlesticks where the current candle's high is higher than the previous candle's high, and the current candle's low is lower than the previous candle's low. If both conditions are met, the candle's body is highlighted in blue on the chart, allowing traders to quickly spot these patterns.
Features:
Highlights candles with both higher highs and lower lows.
Uses clear visual cues (blue body) for easy identification.
Ideal for traders looking to identify specific volatility patterns or reversals.
Multi-Timeframe VWAP Strategy [JARUTIR]Multi-Timeframe VWAP with Price Above VWAP Marker
This indicator allows you to view the Volume-Weighted Average Price (VWAP) across multiple timeframes on a single chart. The VWAP is a popular technical analysis tool used by traders to determine the average price of an asset weighted by volume. It helps identify the overall market trend and is especially useful for intraday trading.
Key Features :
Multiple Timeframes: Choose from 1-minute, 5-minute, 15-minute, 30-minute, 1-hour, and 1-day VWAPs. You can enable or disable the VWAP for any timeframe based on your preference.
Customizable: Easily toggle on/off the VWAP for each timeframe via checkboxes in the settings.
Price Above VWAP Marker: A clear green up arrow is displayed above the price bar whenever the price is above the current VWAP, helping you quickly spot potential bullish signals.
Flexible & Easy to Use: Adjust the settings for any timeframe and see the VWAPs on your chart without clutter. Whether you are trading in the short term or analyzing longer-term trends, this tool provides you with the flexibility you need.
How to Use :
VWAP as Trend Indicator: The VWAP is commonly used to identify whether the price is trending above or below the average price for the session. Price above the VWAP generally signals bullish momentum, while price below the VWAP can indicate bearish pressure.
Price Above VWAP Marker: The green up arrow is your signal for when the price is above the VWAP, which can be used as a potential entry point for long trades.
Customize Timeframes: Whether you're focusing on ultra-short-term movements (like 1-min or 5-min) or need a broader view (like 1-hour or 1-day), this indicator lets you tailor the analysis to your preferred time horizon.
Ideal For :
Intraday Traders looking for quick signals on different timeframes.
Swing Traders who want to track the overall market trend with multiple VWAP levels.
Scalpers needing to monitor fast price movements alongside volume-weighted averages
High Volume Levels with 9 EMAThe script looks back 30 candles and determine highest volume candle in last 30 candles.
High and Low of these candles acts as support and resistance.
Typically price is rising above 9 ema and breaks out of high of the volume candle is bullish.
Similarly, if price is below 9ema and breaking the low of volume candle its bearish.
MSTR Bitcoin Holdings Overlay (MSTR BTC Treasury)This TradingView overlay displays MicroStrategy's (MSTR) Bitcoin holdings as a simple line chart on a separate axis. The data used in this script is based on publicly available information about MSTR's Bitcoin acquisitions up to January 2, 2025.
Key Points:
- All data points (timestamps and Bitcoin holdings) included in this script represent actual historical records available up to January 2, 2025.
- No future projections or speculative estimates are included.
This script is static and does not fetch or update data dynamically. If there are new Bitcoin acquisitions or updates after January 2, 2025, they will not appear on the chart unless manually added.
Transparency and Accuracy:
- The script uses an array-based structure to map exact timestamps to corresponding Bitcoin holdings.
Each timestamp aligns with known dates when MSTR disclosed its Bitcoin purchases.