OPEN-SOURCE SCRIPT
Telah dikemas kini Key Levels By Spartan - Compression Safe

Key Levels Suite - Compression Safe
A confluence-level indicator that won't compress your chart. It plots HTF opens/highs/lows, day levels, moving averages, and volume profile POC/VA, but only draws what's close enough to price to matter, so distant levels never stretch the y-axis and squash your recent candles.
How it avoids compression: every level is checked against its distance from price before drawing. Close levels get a solid line and a full label with price and percent distance. Levels a bit further out still get a dashed line with just a name tag, faded down. Anything beyond that isn't drawn at all — it literally cannot affect auto-scale. Both distance thresholds are adjustable.
Overlapping levels: when two levels land on the same price (say a daily high and a weekly high coincide), most scripts either stack duplicate labels or hide one. This script merges them into a single label listing every contributing name with the price shown once, while each source keeps its own line and color.
Modules (each toggled independently):
HTF levels — daily through yearly, open/high/low/mid, current and previous period
Three configurable moving averages (EMA, SMA, WMA, HMA)
Volume profile POC/VAH/VAL for your chosen timeframe, current and previous period
Day levels — open/high/low/mid, previous day at reduced opacity
HTF and previous-period values are non-repainting: current period updates live, previous period is locked from its final confirmed close.
Settings cover line width, label size, extension length, what shows in labels, same-price merge tolerance, and which modules are active.
A confluence-level indicator that won't compress your chart. It plots HTF opens/highs/lows, day levels, moving averages, and volume profile POC/VA, but only draws what's close enough to price to matter, so distant levels never stretch the y-axis and squash your recent candles.
How it avoids compression: every level is checked against its distance from price before drawing. Close levels get a solid line and a full label with price and percent distance. Levels a bit further out still get a dashed line with just a name tag, faded down. Anything beyond that isn't drawn at all — it literally cannot affect auto-scale. Both distance thresholds are adjustable.
Overlapping levels: when two levels land on the same price (say a daily high and a weekly high coincide), most scripts either stack duplicate labels or hide one. This script merges them into a single label listing every contributing name with the price shown once, while each source keeps its own line and color.
Modules (each toggled independently):
HTF levels — daily through yearly, open/high/low/mid, current and previous period
Three configurable moving averages (EMA, SMA, WMA, HMA)
Volume profile POC/VAH/VAL for your chosen timeframe, current and previous period
Day levels — open/high/low/mid, previous day at reduced opacity
HTF and previous-period values are non-repainting: current period updates live, previous period is locked from its final confirmed close.
Settings cover line width, label size, extension length, what shows in labels, same-price merge tolerance, and which modules are active.
Nota Keluaran
Update: Hide Mitigated LevelsAdded an option to hide a level once price has traded through it. This only applies to levels that are fixed once set: current-period opens, and everything from a completed previous period (previous O/H/L/Mid across all timeframes, previous volume profile POC/VAH/VAL). Current-period highs/lows/mids and moving averages are excluded, since those update every bar and can't be meaningfully "mitigated."
Nota Keluaran
fixed a rare crash when only one level is queuedSkrip sumber terbuka
Dalam semangat TradingView sebenar, pencipta skrip ini telah menjadikannya sumber terbuka, jadi pedagang boleh menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupuan anda boleh menggunakan secara percuma, ingat bahawa penerbitan semula kod ini tertakluk kepada Peraturan Dalaman.
Penafian
Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.
Skrip sumber terbuka
Dalam semangat TradingView sebenar, pencipta skrip ini telah menjadikannya sumber terbuka, jadi pedagang boleh menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupuan anda boleh menggunakan secara percuma, ingat bahawa penerbitan semula kod ini tertakluk kepada Peraturan Dalaman.
Penafian
Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.