OPEN-SOURCE SCRIPT
更新済

Volume Divergence Scanner

2 225
Overview
The indicator combines two independent signal types: Volume Spike (abnormal volume with RSI confirmation) and Divergence (RSI divergence near price extremes). Both must align within a time window to produce a BUY or SELL signal.

Settings
General

Min Bars Between BUY - Minimum bars between any two BUY signals
Min Bars Between SELL - Minimum bars between any two SELL signals

Volume Spike

Enable Volume Spike Signals - Toggle the volume spike component on/off
RSI Length - Period for RSI calculation
Volume MA Length - Short-term volume moving average period
Volume MA Long Length - Long-term volume moving average period (baseline for spike detection)
Buy Multiplier - Volume must exceed long MA by this factor to trigger a buy spike
Sell Multiplier - Volume must exceed long MA by this factor to trigger a sell spike
RSI Buy Level - RSI must be below this level for a buy spike to fire
RSI Sell Level - RSI must be above this level for a sell spike to fire
Min Bars Between BUY - Minimum bars between volume spike buy signals
Min Bars Between SELL - Minimum bars between volume spike sell signals

Divergence

Enable Divergence - Toggle the divergence component on/off
Lookback Bars - Window for detecting local price and RSI extremes
RSI Buy Level - RSI must be below this level for a divergence buy
RSI Sell Level - RSI must be above this level for a divergence sell
Buy Proximity to Low - Price must be within this multiplier of the local low (e.g. 1.02 = within 2%)
Sell Proximity to High - Price must be within this multiplier of the local high (e.g. 0.98 = within 2%)
Min Bars Between BUY - Minimum bars between divergence buy signals
Min Bars Between SELL - Minimum bars between divergence sell signals
VOL+D Confirmation Window - Maximum bars allowed between a Volume Spike and Divergence signal for them to confirm each other

Alerts

Alert: BUY - Enable Trading View alert on BUY signal
Alert: SELL - Enable TradingView alert on SELL signal

Signal Logic
When both components are enabled a BUY fires when either:
  • Volume Spike BUY occurred and a Divergence BUY happened within the last confirmWindow bars
  • Divergence BUY occurred and a Volume Spike BUY happened within the last confirmWindow bars


A SELL fires by the same logic in reverse.
  • When only Volume Spike is enabled, signals fire on volume spikes alone, without divergence confirmation.
  • When only Divergence is enabled, signals fire on RSI divergence alone, without volume confirmation.


Tuning Tips
Too few signals:
  • Increase VOL+D Confirmation Window
  • Lower Buy Multiplier / Sell Multiplier
  • Widen Buy Proximity to Low (e.g. 1.05) and Sell Proximity to High (e.g. 0.95)
  • Disable one component to see which fires more frequently


Too many signals:
  • Increase Min Bars Between BUY/SELL
  • Raise Buy Multiplier / Sell Multiplier
  • Tighten Buy Proximity to Low (e.g. 1.01) and Sell Proximity to High (e.g. 0.99)
  • Decrease VOL+D Confirmation Window


Adapting to different assets or timeframes:
  • Higher timeframes (4h, 1D) generally need higher multipliers and longer MA periods
  • More volatile assets may need looser RSI levels and proximity values
  • Start with default settings and adjust one parameter at a time
リリースノート
VDS Settings Update

The settings have been reorganized and simplified for a cleaner configuration experience.

Structure
  • Removed the General section.
  • Introduced Fine Tuning for settings that affect the overall VDS behavior.
  • Moved RSI Length, Volume MA Length, Volume MA Long Length, Confirmation Window, and Overall Signal Spacing to Fine Tuning.
  • Alerts remain in a separate section.


Volume Spike
  • Renamed Buy/Sell Multiplier → Buy/Sell Spike Threshold
  • Combined separate BUY/SELL spacing settings into Volume Signal Spacing


Divergence
  • Renamed Buy Proximity to Low → Buy Low Distance
  • Renamed Sell Proximity to High → Sell High Distance
  • Distance is now entered directly as a percentage. For example, 2% means price can be up to 2% away from the local low/high.
  • Combined separate BUY/SELL spacing settings into Divergence Signal Spacing


Alerts
  • BUY and SELL alerts remain unchanged.


Logic
  • Signal logic remains unchanged apart from the new shared spacing controls and percentage-based distance inputs.

免責事項

これらの情報および投稿は、TradingViewが提供または承認する金融、投資、取引、またはその他の種類の助言もしくは推奨であることを意図したものではなく、またこれらに該当するものでもありません。詳細は利用規約をご覧ください。