Market Breadth v2

Market Breadth ETH is a market-structure and participation indicator that overlays market breadth data directly onto the price chart.
Instead of showing breadth (advance/decline, volume participation) in a separate pane, this script translates breadth into price-scaled levels and lines, allowing you to see:
Whether an uptrend or downtrend is broadly supported or narrow and fragile
Where weak trends leave structural “footprints” behind
When price is moving with or against underlying market participation
In short, it helps answer:
“Is this move real, or is it running on borrowed strength?”
Why market breadth matters
Market breadth measures how many stocks are participating in a move.
Strong markets rise with many stocks advancing together
Weak markets often rise with only a few large stocks, while the rest lag or decline
Price alone does not reveal this difference.
Breadth does.
This script’s purpose is to merge breadth and price into one visual framework so you can judge trend quality, not just direction.
Core components and how they work
1. Breadth data inputs (the foundation)
The script pulls three market-wide data series:
Advance/Decline (ADVDEC) – net advancing minus declining stocks
Advance/Decline Volume (ADVDECV) – volume-weighted participation
Total Volume (TVOL) – context (not directly used in logic)
These values represent market participation, not price.
They are restricted to regular trading hours (RTH) so overnight noise does not distort the signal.
2. The advance line (participation context)
The script builds a cumulative advance/decline volume line:
Volume is only accumulated during RTH
The cumulative value is log-scaled
Why log scaling?
Breadth volume can grow extremely large and volatile.
Log scaling compresses it into a usable range while preserving trend information.
This advance line is not plotted directly, but it is used to:
Measure recent breadth highs and lows
Define whether participation is expanding or contracting
3. Daily breadth range (strength vs weakness)
Each day, the script tracks:
The high and low of the advance line
Stores the last 3 completed days
From this it derives:
A recent breadth high
A recent breadth low
A midpoint
These are used to classify participation as:
Strong
Neutral
Weak
This classification feeds into the trend background color, which acts as a quick health gauge for the market.
4. Anchors and scaling (how breadth becomes an overlay)
This is the most important design concept.
Breadth values cannot normally be plotted on a price chart because:
They exist in a completely different numerical scale
This script solves that by anchoring and scaling breadth to price using two reference points:
Prior session close
Current session open
Using these anchors, the script:
Normalizes breadth relative to its recent maximum
Scales it proportionally into price space
The result is the Derived Breadth Line.
5. The Derived Breadth Line (the heart of the indicator)
The Derived Breadth Line is a price-level representation of market participation.
How to read it:
Its position relative to price matters
Its color matters
Its interaction with price matters
Think of it as:
“Where price should be if participation were perfectly aligned.”
Interpretation:
Price above the breadth line → price may be outrunning participation
Price near or below the breadth line → participation is supporting the move
6. Breadth line color (strength signal)
The breadth line changes color based on internal conditions:
Green → strong participation, supportive breadth
Yellow → mixed or transitional conditions
Red → weak participation, internal selling pressure
The color reflects breadth health, not price direction.
A rising price with a yellow or red breadth line is often a warning sign.
7. Smoothing and “sync”
The script calculates a smoothed version (ALMA) of the breadth line.
When:
The raw breadth line and its smoothed version are close
The market is considered “in sync”.
Signals are emphasized when this condition is met because:
It filters noise
It indicates consistent participation behavior
8. Imbalance shading (pressure visualization)
The script compares:
What price movement implies
What breadth movement actually shows
When breadth underperforms price, the area around the breadth line is shaded.
Darker shading = stronger imbalance.
This visually highlights hidden selling pressure that price alone does not show.
9. Extended daily lines (trend strength memory)
This is one of the most powerful features.
What these lines are:
At each session close, the script draws a horizontal line at the derived breadth level
The line extends forward in time
The line remains active until price trades through it
What they represent:
These lines are breadth-based structural memory.
They show:
Where prior participation conditions were “left behind”
Whether price has resolved those conditions or not
Weak vs strong trends (key concept)
Strong trends
Do not leave many unresolved lines behind
Price continues forward without revisiting them
Weak trends
Leave red lines overhead during uptrends
These lines represent weak participation that was never repaired
They often act as future resistance or reversal zones
An uptrend with many red breadth lines above price is structurally fragile.
10. Line distance imbalance (pressure stacking)
The script sums:
Unresolved lines above price
Unresolved lines below price
Only within a user-defined range
It plots:
Positive distance (overhead pressure)
Negative distance (support below)
Net balance
This gives you a quantitative sense of:
Whether pressure is stacked above or below price
Whether the market has “room to run” or is boxed in
When this indicator is most useful
This script is especially effective for:
Index trading (ES, NQ, SPX, etc.)
Trend quality assessment
Identifying weak rallies
Context for intraday and swing trades
Risk management (when not to chase)
It is not a signal-only indicator.
It is a context and structure tool.
How to use it in practice
Practical workflow:
Check the breadth line color
Green supports continuation
Yellow = caution
Red = risk
Compare price vs breadth line
Price far above line → fragile
Price near line → healthier
Look at extended lines
Many red lines overhead → weak trend
Few or none → stronger trend
Watch imbalance shading
Growing negative shading → internal pressure
Combine with your entries
Use this to filter trades
Avoid chasing moves with weak breadth
Summary
Market Breadth ETH turns invisible market participation into visible price structure.
It helps you:
Judge trend strength, not just direction
See where weak trends leave unfinished business
Understand when price is being supported — or quietly undermined
Think of it as a market quality lens that sits on top of your chart.
If you want, I can also:
Write a short TradingView publish description
Create example trade scenarios
Add a “how not to use it” section
สคริปต์แบบเฉพาะผู้ได้รับเชิญเท่านั้น
เฉพาะผู้ใช้งานที่ผู้เขียนอนุมัตเท่านั้นจึงจะสามารถเข้าถึงสคริปต์นี้ได้ คุณจะต้องขอและได้รับอนุญาตก่อนใช้งาน ซึ่งโดยทั่วไปจะได้รับอนุญาตหลังจากชำระเงินแล้ว สำหรับรายละเอียดเพิ่มเติม โปรดทำตามคำแนะนำของผู้เขียนด้านล่าง หรือติดต่อ bryndclegg โดยตรง
TradingView ไม่แนะนำให้จ่ายเงินหรือใช้สคริปต์ เว้นแต่คุณจะเชื่อถือผู้เขียนและเข้าใจวิธีการทำงานของสคริปต์นั้นอย่างถ่องแท้ คุณยังสามารถหาทางเลือกแบบโอเพนซอร์สฟรีได้ใน สคริปต์ชุมชนของเรา
คำแนะนำของผู้เขียน
คำจำกัดสิทธิ์ความรับผิดชอบ
สคริปต์แบบเฉพาะผู้ได้รับเชิญเท่านั้น
เฉพาะผู้ใช้งานที่ผู้เขียนอนุมัตเท่านั้นจึงจะสามารถเข้าถึงสคริปต์นี้ได้ คุณจะต้องขอและได้รับอนุญาตก่อนใช้งาน ซึ่งโดยทั่วไปจะได้รับอนุญาตหลังจากชำระเงินแล้ว สำหรับรายละเอียดเพิ่มเติม โปรดทำตามคำแนะนำของผู้เขียนด้านล่าง หรือติดต่อ bryndclegg โดยตรง
TradingView ไม่แนะนำให้จ่ายเงินหรือใช้สคริปต์ เว้นแต่คุณจะเชื่อถือผู้เขียนและเข้าใจวิธีการทำงานของสคริปต์นั้นอย่างถ่องแท้ คุณยังสามารถหาทางเลือกแบบโอเพนซอร์สฟรีได้ใน สคริปต์ชุมชนของเรา