OPEN-SOURCE SCRIPT
Support_V1

Credit: Concept by TradingLion · Pine Script v6 implementation
What it does
Plots horizontal support/resistance lines only at volatility-qualified pivot highs and lows — pivots where price moved at least ADR × Multiplier from the previous pivot. Shallow, noise-level swings are ignored. Nearby levels within Merge Within % are automatically collapsed into one. Only the most recent Max Pivots levels stay visible.
Settings
Setting What it controls
Max Pivots Max lines on chart at any time
Breakout Threshold ADR or fixed % used for breakout arrow signals
Merge Within % Collapses two levels that are closer than this % apart
Breakout % Threshold when using Percent mode for breakout signals
ADR Lookback Bars used to compute Average Daily Range
ADR Multiplier Scales the ADR — higher = only larger moves qualify as pivots
Extend Bars Right How far the line projects to the right of the current bar
How to use
Paste into TradingView Pine Editor → Add to chart
Start with defaults (ADR Lookback 20, Multiplier 1, Max Pivots 2)
Raise ADR Multiplier (e.g. 2) on volatile stocks to filter out noise
Raise Merge Within % (e.g. 5–10) in tight consolidations to keep one clean level
Extend Bars Right controls how far ahead the line projects — set to match your typical hold period in bars
What it does
Plots horizontal support/resistance lines only at volatility-qualified pivot highs and lows — pivots where price moved at least ADR × Multiplier from the previous pivot. Shallow, noise-level swings are ignored. Nearby levels within Merge Within % are automatically collapsed into one. Only the most recent Max Pivots levels stay visible.
Settings
Setting What it controls
Max Pivots Max lines on chart at any time
Breakout Threshold ADR or fixed % used for breakout arrow signals
Merge Within % Collapses two levels that are closer than this % apart
Breakout % Threshold when using Percent mode for breakout signals
ADR Lookback Bars used to compute Average Daily Range
ADR Multiplier Scales the ADR — higher = only larger moves qualify as pivots
Extend Bars Right How far the line projects to the right of the current bar
How to use
Paste into TradingView Pine Editor → Add to chart
Start with defaults (ADR Lookback 20, Multiplier 1, Max Pivots 2)
Raise ADR Multiplier (e.g. 2) on volatile stocks to filter out noise
Raise Merge Within % (e.g. 5–10) in tight consolidations to keep one clean level
Extend Bars Right controls how far ahead the line projects — set to match your typical hold period in bars
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。