OPEN-SOURCE SCRIPT
Cập nhật OBV Strength Relative to Volume (Lakhs View)

OBV Strength Relative to Volume (Lakhs View)
Description:
to provide a compact yet powerful insight into volume momentum and price conviction. It's tailored for traders and analysts in markets like India, where high-volume stocks are often better interpreted in lakhs.
💡 Key Features:
OBV Calculation: Cumulative OBV is computed based on price movement direction and volume contribution.
OBV Strength (%): Measures the percentage strength of OBV relative to total volume over a user-defined period. It reflects how strongly volume is contributing to price movements.
Lakhs View: Both OBV and Volume are scaled to lakhs for cleaner readability and practical analysis in high-volume securities.
Historical Table Display:
Displays date-wise OBV, Volume, and OBV Strength for the last N candles (customizable).
Automatically updates every 5 bars or on each bar for real-time analysis.
Color-coded cells for quick visual recognition.
⚙️ Inputs:
OBV Strength Period: Number of bars used to calculate OBV strength (default = 5).
Number of Days in Table: Number of recent bars shown in the on-chart table (default = 5).
📈 Plots:
OBV (Lakhs) – Aqua line.
Volume (Lakhs) – Orange columns.
OBV Strength (%) – Green line indicating momentum strength based on volume.
📍 Ideal Use:
Use this indicator to:
Spot divergences between OBV and price.
Assess the strength of volume behind a trend.
Track consistency and spikes in volume-backed price moves.
Quickly scan recent trends with a clear numerical and visual table.
Description:
to provide a compact yet powerful insight into volume momentum and price conviction. It's tailored for traders and analysts in markets like India, where high-volume stocks are often better interpreted in lakhs.
💡 Key Features:
OBV Calculation: Cumulative OBV is computed based on price movement direction and volume contribution.
OBV Strength (%): Measures the percentage strength of OBV relative to total volume over a user-defined period. It reflects how strongly volume is contributing to price movements.
Lakhs View: Both OBV and Volume are scaled to lakhs for cleaner readability and practical analysis in high-volume securities.
Historical Table Display:
Displays date-wise OBV, Volume, and OBV Strength for the last N candles (customizable).
Automatically updates every 5 bars or on each bar for real-time analysis.
Color-coded cells for quick visual recognition.
⚙️ Inputs:
OBV Strength Period: Number of bars used to calculate OBV strength (default = 5).
Number of Days in Table: Number of recent bars shown in the on-chart table (default = 5).
📈 Plots:
OBV (Lakhs) – Aqua line.
Volume (Lakhs) – Orange columns.
OBV Strength (%) – Green line indicating momentum strength based on volume.
📍 Ideal Use:
Use this indicator to:
Spot divergences between OBV and price.
Assess the strength of volume behind a trend.
Track consistency and spikes in volume-backed price moves.
Quickly scan recent trends with a clear numerical and visual table.
Phát hành các Ghi chú
### 📊 **Indicator Summary: OBV Strength Relative to Volume (Lakhs View)****Purpose:**
This indicator visually combines *On-Balance Volume (OBV)*, *Volume*, and *OBV Strength (%)* to analyze how strongly volume is supporting current price movements. It helps identify early signs of trend continuation or reversal based on volume behavior.
---
### ⚙️ **Key Components**
1. **OBV (On-Balance Volume)**
* Cumulative measure of buying/selling pressure.
* Increases when price closes higher than the previous day; decreases when it closes lower.
* Displayed in **lakhs** for readability.
2. **Volume (Lakhs)**
* Daily traded volume, also converted to lakhs.
* Plotted as **green/red columns** depending on whether volume increased or decreased from the previous day.
3. **OBV Strength (%)**
* Shows how much OBV has changed compared to total traded volume over the selected lookback period.
* Positive = strong buying volume; Negative = strong selling volume.
* Expressed as a percentage.
4. **Price Movement (High–Low)**
* Indicates the intraday price range (difference between daily high and low).
* Reflects actual volatility and market activity for the day.
5. **Projected Price**
* A calculated **forecasted price level** based on OBV Strength.
* Estimates where price could move if the current volume momentum continues.
* Positive OBV Strength → projected price above current close.
* Negative OBV Strength → projected price below current close.
---
### 🧮 **Table Display**
A dynamic table (bottom-right) shows recent data for quick analysis:
| Date | OBV (L) | Volume (L) | OBV Strength % | Price Range | Projected Price |
| ----------- | ----------- | -------------- | -------------- | ------------- | ---------------------- |
| Latest date | Current OBV | Today’s volume | Strength value | High–Low diff | Estimated price target |
* **Green/Red coloring** instantly indicates whether OBV or Volume increased/decreased from the previous day.
* Table updates automatically with each new bar.
---
### 🧠 **Practical Use**
* Detect **volume-led breakouts** before price confirms.
* Identify **divergences** between price and OBV (hidden accumulation/distribution).
* Assess whether current moves are **supported by genuine volume** or weak participation.
* Use projected price to gauge **potential upside/downside** momentum continuation.
Phát hành các Ghi chú
## 📊 **OBV Strength vs Volume (Adaptive Volatility Model)**
### — by Manav Prakash
This indicator combines **On-Balance Volume (OBV)**, **price volatility**, and **volume dynamics** to estimate **market strength** and a **projected price range**.
It presents both **fixed** and **adaptive** projections, along with a compact visual table summarizing the last few days.
---
### 🧮 **1. OBV and OBV Strength (%)**
* **OBV** measures cumulative buying/selling pressure:
* It adds volume when price closes higher.
* It subtracts volume when price closes lower.
* **OBV Strength (%)** expresses how strong the net buying/selling has been over a recent window (default 5 days).
[
\text{OBV Strength} = \frac{\Delta OBV}{\text{Total Volume in Period}} \times 100
]
* Positive → Buying strength
* Negative → Selling pressure
---
### 📈 **2. Price Factor & Projected Price**
The **projected price** uses OBV strength to estimate how much price might move if the current buying/selling momentum continues.
It’s based on the idea that *price follows volume*, so stronger OBV strength suggests higher projected movement.
Two projections are shown:
#### a. **Fixed Projection**
* Uses a constant **Base Price Factor** (default 0.1 = 10% sensitivity).
* Formula:
[
\text{Projected Price (Fixed)} = \text{Close} \times \left(1 + \frac{\text{OBV Strength}}{100} \times 0.1 \right)
]
This assumes price reacts uniformly to OBV changes, regardless of volatility.
#### b. **Adaptive Projection**
* Uses an **adaptive price factor**, which changes with volatility (ATR%).
* When volatility is **low**, price factor increases — suggesting price reacts **more sharply** to OBV shifts.
* When volatility is **high**, price factor decreases — price movement becomes **less sensitive**.
* Formula:
[
\text{Projected Price (Adaptive)} = \text{Close} \times \left(1 + \frac{\text{OBV Strength}}{100} \times \text{Adaptive Factor} \right)
]
The adaptive factor varies typically between **0.05 and 0.25**, dynamically adjusting market sensitivity.
---
### 📊 **3. Table Display**
The lower table summarizes key daily data:
| Column | Meaning |
| ------------- | ---------------------------------------------------- |
| Date | The date of each bar shown |
| OBV (L) | On-Balance Volume in Lakhs |
| Vol (L) | Daily traded volume in Lakhs |
| Strength % | OBV momentum (positive = buying, negative = selling) |
| Day Range % | Intraday high–low range as % of low |
| Fixed Proj | Projected price using fixed factor |
| Adaptive Proj | Projected price using adaptive factor |
**Colors:**
* Green background → Increase from previous day
* Red background → Decrease
* Orange → High volatility (large intraday range)
---
### ⚙️ **4. Practical Interpretation**
* **Rising OBV with increasing volume** → bullish accumulation.
* **Projected Price (Adaptive)** higher than current price → upside potential.
* **Projected Price (Adaptive)** falling below current price → downside risk.
* **Large difference (>4%) between projected and actual price** → possible trading signal (either overbought or oversold zone).
---
### 🧠 **5. Use Case**
This model is designed for:
* Traders analyzing **volume-led breakouts**.
* Investors wanting to detect **early accumulation or distribution**.
* Quant analysts experimenting with **adaptive volatility models** in momentum prediction.
---
### 💡 **In essence:**
> The “Adaptive OBV Strength” indicator doesn’t just show what happened —
> it **estimates what could happen next**, by blending **volume momentum** and **volatility behavior** into a simple visual projection.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội Quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội Quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.