OPEN-SOURCE SCRIPT
STRX - Balance Range

STRX - Balance Range is a price-structure indicator designed to identify and track balanced trading ranges directly on the chart.
It detects periods of compression by comparing the recent price box width to ATR-based volatility, then validates the structure using persistence, edge interaction, and price position inside the range.
The script draws historical range boxes, can optionally connect consecutive ranges, and includes a compact statistics table showing the last closed range, the average of the last 10 ranges, and the average of the last 100 ranges.
This makes it useful for traders who want to study how current balance conditions compare with recent and broader market structure.
How it works:
A reference range is built from the highest high and lowest low of the previous lookback window.
The range is accepted only when its width remains compressed relative to ATR and the current price continues to behave inside that structure.
Additional filters help reduce random consolidations by requiring repeated interaction with the range boundaries and a minimum confirmation period.
How to use it:
Use the boxes to locate areas where price is rotating in balance rather than expanding directionally.
Compare the latest closed range with the 10-range and 100-range averages to judge whether current balance conditions are relatively small, typical, or expanded.
The tool is designed for structure reading and contextual analysis, not as a standalone buy/sell signal generator.
Inputs overview:
Range Length controls how many bars are used to define the reference box.
ATR Length and ATR Multiplier control how strict the volatility compression filter is.
Center Distance, Edge Touches, and Confirmation Bars refine the quality of detected ranges.
Visual options allow you to show or hide historical boxes, range markers, connection lines, and the statistics table.
Notes:
The statistics table uses closed historical ranges, so the values remain stable and easier to compare.
This indicator is intended for standard chart types and discretionary structure analysis.
It does not guarantee future performance and should be used together with your own risk management and market context reading.
It detects periods of compression by comparing the recent price box width to ATR-based volatility, then validates the structure using persistence, edge interaction, and price position inside the range.
The script draws historical range boxes, can optionally connect consecutive ranges, and includes a compact statistics table showing the last closed range, the average of the last 10 ranges, and the average of the last 100 ranges.
This makes it useful for traders who want to study how current balance conditions compare with recent and broader market structure.
How it works:
A reference range is built from the highest high and lowest low of the previous lookback window.
The range is accepted only when its width remains compressed relative to ATR and the current price continues to behave inside that structure.
Additional filters help reduce random consolidations by requiring repeated interaction with the range boundaries and a minimum confirmation period.
How to use it:
Use the boxes to locate areas where price is rotating in balance rather than expanding directionally.
Compare the latest closed range with the 10-range and 100-range averages to judge whether current balance conditions are relatively small, typical, or expanded.
The tool is designed for structure reading and contextual analysis, not as a standalone buy/sell signal generator.
Inputs overview:
Range Length controls how many bars are used to define the reference box.
ATR Length and ATR Multiplier control how strict the volatility compression filter is.
Center Distance, Edge Touches, and Confirmation Bars refine the quality of detected ranges.
Visual options allow you to show or hide historical boxes, range markers, connection lines, and the statistics table.
Notes:
The statistics table uses closed historical ranges, so the values remain stable and easier to compare.
This indicator is intended for standard chart types and discretionary structure analysis.
It does not guarantee future performance and should be used together with your own risk management and market context reading.
오픈 소스 스크립트
트레이딩뷰의 진정한 정신에 따라, 이 스크립트의 작성자는 이를 오픈소스로 공개하여 트레이더들이 기능을 검토하고 검증할 수 있도록 했습니다. 작성자에게 찬사를 보냅니다! 이 코드는 무료로 사용할 수 있지만, 코드를 재게시하는 경우 하우스 룰이 적용된다는 점을 기억하세요.
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.
오픈 소스 스크립트
트레이딩뷰의 진정한 정신에 따라, 이 스크립트의 작성자는 이를 오픈소스로 공개하여 트레이더들이 기능을 검토하고 검증할 수 있도록 했습니다. 작성자에게 찬사를 보냅니다! 이 코드는 무료로 사용할 수 있지만, 코드를 재게시하는 경우 하우스 룰이 적용된다는 점을 기억하세요.
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.