OPEN-SOURCE SCRIPT

Horizontal ATR Lines

98
Disclaimer:
This script was generated using OpenAI’s ChatGPT. I take no responsibility for the correctness, performance, or financial impact of this indicator. Use it at your own risk and discretion.

This indicator draws horizontal ATR-based levels from the last closed candle on a user-selected timeframe. It is designed for traders who want to visualize realistic volatility zones for setting dynamic support/resistance, take-profit, or stop-loss levels.

What it does:

Calculates the Average True Range (ATR) using a customizable period and timeframe.

Plots four horizontal lines:

+1 ATR and –1 ATR from the last closed candle’s close

+X ATR and –X ATR, where X is a second custom multiplier

Each level includes a compact label showing:

The price of the level

The percentage distance from the close price

Use cases:

Identify realistic intraday or swing price movement boundaries

Build volatility-aware take-profit and stop-loss zones

Visually track market compression or expansion in context

Customization:

ATR period and timeframe

Two independent ATR multipliers

Custom color settings for each group of levels

Declinazione di responsabilità

Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.