logo
Developers

Trading range display with Box

Script from: TradingViewSwingTrend following

This script displays the trading range, coloring it based on profitability. It’s a reference tool and not for actual trading. To visualize current trades, use process_orders_on_close=true, calc_on_every_tick=true, max_boxes_count=500. Avoid switching strategies within the same test period to ensure accurate range display. It involves repainting and is primarily for visual testing by copying from line 22 onwards in the script.

Premium users only

Premium users can access all backtests with a profit factor above 3

@ Daily

4.01

Profit Factor

25.48 %

Total ROI

18

Bloom Energy Corporation (BE)

+ Trading range display with Box

@ 4 h

2.18

Profit Factor

3,688.71 %

Total ROI

116

PAX Gold / TetherUS (PAXGUSDT)

+ Trading range display with Box

@ Daily

2.18

Profit Factor

78.23 %

Total ROI

60

Sandisk Corporation (SNDK)

+ Trading range display with Box

@ 2 h

2.16

Profit Factor

1,500.60 %

Total ROI

40

Spotify Technology S.A. (SPOT)

+ Trading range display with Box

@ 4 h

1.85

Profit Factor

541.34 %

Total ROI

129

Goldman Sachs Group, Inc. (The) (GS)

+ Trading range display with Box

@ 4 h

1.81

Profit Factor

1,134.35 %

Total ROI

381

IonQ, Inc. (IONQ)

+ Trading range display with Box

@ 4 h

1.62

Profit Factor

861.49 %

Total ROI

81

ALX Oncology Holdings Inc. (ALXO)

+ Trading range display with Box

@ 4 h

1.56

Profit Factor

9.24 %

Total ROI

42

Gold Futures (GC1!)

+ Trading range display with Box

@ 1 hTradeSearcher backtest

1.51

Profit Factor

273.13 %

Total ROI

578

Connexa Sports Technologies Inc. (CNXA)

+ Trading range display with Box

@ Daily

1.51

Profit Factor

11.84 %

Total ROI

22

ChargePoint Holdings, Inc. (CHPT)

+ Trading range display with Box

@ Daily

1.50

Profit Factor

7.15 %

Total ROI

22

AST SpaceMobile, Inc. (ASTS)

+ Trading range display with Box

@ 4 h

1.49

Profit Factor

1,282.50 %

Total ROI

91

Create your account for free to see all 70+ backtests

Access filters, details, best timeframes, explore 100K+ backtests and more

Active Trades

Create your account to see on which symbols Trading range display with Box is currently trading on.

Trading range display with Box backtest statistics

Aggregated across every validated backtest TradeSearcher has run on this strategy. Figures update automatically as new backtests are added — they are not edited by hand. Classified as swing by holding period.

70
Backtests run
1.3
Avg profit factor
+392%
Avg net profit
+25%
Avg annualized return
51%
Avg max drawdown
0.13
Avg Sharpe ratio

On average, backtests of this strategy beat a buy-and-hold baseline by 328% over the same window.

Performance by asset class

MarketBacktestsAvg profit factorAvg net profitAvg max drawdownAvg Sharpe
Crypto881.2+636%69%0.14
Stocks1,2951.3+265%46%0.10

Backtests use the validated-universe filter: non-repainting scripts, over 15 trades, non-excluded. Per-market rows appear only when at least one backtest exists for that asset class.

Explore the best Trading & TradingView strategies

Stop trading blindly. Explore quality-gated backtests and improve your trading skills with data.

Start for free