Indicators··7 min read

Round Number and Quarter Level Grid

4 references, link-verified · 1 primaryEditor of record: Shane CantyStandards review editorial standard · audit log

A grid overlay displaying round price levels, whole numbers like 100.00, 101.00, and quarter subdivisions (0.25, 0.50, 0.75 increments), which traders use as visual landmarks for psychological support and resistance zones. Useful for traders across equities, cryptocurrencies, futures and forex who recognize round numbers as magnet prices where clusters of orders tend to accumulate.

//@version=6
indicator("Round Number & Quarter Level Grid", overlay=true, max_lines_count=400)

// Grid Configuration
show_quarter_levels = input(true, "Show Quarter Levels (0.25, 0.50, 0.75)", group="Grid")
manual_interval = input(1.0, "Round Number Interval", minval=0.01, step=0.01, group="Grid")
auto_adjust = input(true, "Auto-Adjust for Price Scale", group="Grid")

// Styling
color_round_numbers = input(color.new(color.gray, 70), "Round Number Color", group="Styling")
color_quarters = input(color.new(color.blue, 80), "Quarter Level Color", group="Styling")
width = input(1, "Line Width", minval=1, maxval=3, group="Styling")

// Calculate appropriate grid spacing based on current price range
calculate_interval() =>
    price_range = high - low
    
    if auto_adjust
        if price_range > 1000
            10.0
        else if price_range > 100
            1.0
        else if price_range > 10
            0.1
        else
            0.01
    else
        manual_interval

current_interval = calculate_interval()

// Find the lowest round number below the current low
base_level = math.floor(low / current_interval) * current_interval

// Draw grid on last bar only to avoid continuous repainting
if barstate.islast
    // Determine how many levels are needed to cover visible range
    levels_needed = math.ceil((high - base_level) / current_interval) + 1
    max_draw = math.min(levels_needed, 60)  // Cap to prevent excessive lines
    
    for i = 0 to max_draw
        current_level = base_level + i * current_interval
        
        // Only draw within reasonable range
        if current_level >= low - current_interval and current_level <= high + current_interval
            // Draw round number line
            line.new(bar_index - 100, current_level, bar_index + 200, current_level,
                     extend=extend.both, color=color_round_numbers, width=width,
                     style=line.style_dashed)
            
            // Draw quarter level lines if enabled
            if show_quarter_levels
                for q = 1 to 3
                    quarter_level = current_level + (current_interval * q / 4.0)
                    if quarter_level >= low - current_interval and quarter_level <= high + current_interval
                        line.new(bar_index - 100, quarter_level, bar_index + 200, quarter_level,
                                 extend=extend.both, color=color_quarters, width=width,
                                 style=line.style_dotted)

How the code works

The indicator establishes a grid of horizontal reference lines at psychologically significant price points. The calculate_interval() function adapts the grid spacing based on the current price range visible on the chart, if the range exceeds 1000, it uses 10.0-point increments; between 100 and 1000, it uses 1.0; between 10 and 100, it uses 0.1; and for smaller ranges, 0.01. This prevents either over-crowding (too many lines) or too few guideposts.

The base_level uses math.floor() to find the lowest round number at or below the visible low price. The loop then iterates upward in increments of current_interval, drawing dashed lines at each whole round number. For each round level, if show_quarter_levels is enabled, the code adds three dotted lines subdividing the space at 0.25, 0.50, and 0.75 of the interval.

The condition if barstate.islast ensures drawing happens only on the last bar to avoid recomputation across historical bars, which would be inefficient and cause unnecessary redraws. The extend=extend.both parameter extends each line horizontally to left and right edges of the chart for continuous visibility.

Reading it on a chart

On a chart, traders see a dashed grid of major levels (round numbers) and, optionally, a finer dotted grid of quarter levels between them. Round-number lines may appear at 100.00, 101.00, etc., depending on auto-scaling. Quarter lines subdivide the gaps: for a 1.0 interval, quarters appear at 0.25, 0.50, and 0.75 offsets. Colors are customizable; round numbers are typically darker or more prominent; quarters are lighter or muted to avoid visual clutter.

Traders often observe that price action respects or bounces off round numbers, especially whole dollars, 50-pip levels in forex, or major contract price ticks in futures. The quarter levels serve as intermediate zones where price may consolidate, reverse, or accelerate through. A trader might note that price rejected a round number twice in the last five candles, suggesting that level as a potential resistance; quarter levels offer a finer granularity for profit-taking targets or support probes.

The auto-adjust feature scales the grid intelligently: zooming out to a daily chart shows fewer, larger-spaced lines; zooming in to a 5-minute chart automatically tightens the grid for local precision. Manual interval input lets traders override auto-scaling, for example, forcing a 2.0 interval on a stock that clusters at even multiples of 2.

Limitations

Round-number levels lack predictive power on their own; they are purely geometric. Price reaches a round number frequently not because of inherent order but because humans and algorithmic systems tend to use them as order-placement thresholds. This is convention, not a market mechanic, and their relevance varies sharply across instruments and time scales. On a 15-minute crypto chart, a round dollar level may be irrelevant; on a weekly equity chart, it may act as a magnet. No study is cited here because the phenomenon is practitioner observation, not rigorously quantified.

The indicator does not forecast reversals or identify entry/exit points. Price may drift past a round level with no hesitation, particularly during strong trends. Quarter levels are artificial subdivisions and carry no regulatory or structural significance; they are guides for visual segmentation, not evidence of support or resistance.

The auto-scaling logic is heuristic. A stock ranging 200 points uses a 1.0 interval under the current threshold, which may be too granular for some timeframes and too coarse for others; manual adjustment may be necessary. Lines redraw only on the last bar, so if the chart scrolls or price moves far beyond existing lines, the grid may appear sparse until the next bar closes.

Excessive line counts can slow chart performance on older systems or with very small intervals. The code caps drawing at 60 levels to mitigate this, but users working with extremely large price ranges combined with tiny manual intervals may experience lag.


Key definitions

Round number: A whole dollar amount (or major unit for the instrument) such as 100.00, 500.00, or 1000.00; used as a psychological price target or order-clustering point in trading.

Quarter level: A subdivision at 0.25, 0.50, or 0.75 of a round-number interval, offering intermediate reference points between whole numbers.

Support and resistance: Price levels where buying or selling pressure historically emerges; a round number is sometimes treated as a support or resistance zone by traders, though this is conventional rather than mechanical.

Psychological support/resistance: Price levels that attract trader attention or order placement due to their round, memorable, or aesthetically significant values, not due to any economic mechanism.

Grid: A set of evenly spaced horizontal reference lines overlaid on a price chart to aid visual orientation.

Auto-scaling: A feature that adjusts the grid interval automatically based on the current price range, to maintain legible spacing at any zoom level.

References


Educational research on historical data only. Not investment advice, not a signal, and never a performance promise. Past results do not predict future performance. Every reference is link-verified before publication and every paper is re-audited weekly against the library's editorial standard.

Last reviewed by the PropLedger research pipeline: 2026-08-30. Educational research on historical data, not financial advice.

Educational research on historical data only. Not investment advice, not a signal, and never a performance promise. Past results do not predict future performance. Every reference is link-verified before publication and every paper is re-audited weekly against the library's editorial standard. Found an error? Email support@prop-ledger.org and the paper is corrected or withdrawn.