logo
Developers

How to use Leverage in PineScript

Script from: TradingViewLongTerm

New Zealand Dollar/U.S. Dollar (NZDUSD)

+ How to use Leverage in PineScript

@ DailyTradeSearcher backtest

1.86

Profit Factor

67.79 %

Total ROI

32

Australian Dollar/U.S. Dollar (AUDUSD)

+ How to use Leverage in PineScript

@ DailyTradeSearcher backtest

1.66

Profit Factor

39.20 %

Total ROI

32

Procter & Gamble Company (The) (PG)

+ How to use Leverage in PineScript

@ 15 min

1.39

Profit Factor

188.44 %

Total ROI

225

E-MINI DOW (5$) FUTURES (YM1!)

+ How to use Leverage in PineScript

@ 1 hTradeSearcher backtest

1.25

Profit Factor

54.07 %

Total ROI

187

New Zealand Dollar/U.S. Dollar (NZDUSD)

+ How to use Leverage in PineScript

@ 5 minTradeSearcher backtest

1.25

Profit Factor

3.71 %

Total ROI

156

Mondelez International, Inc. (MDLZ)

+ How to use Leverage in PineScript

@ 2 h

1.24

Profit Factor

487.93 %

Total ROI

355

Australian Dollar/U.S. Dollar (AUDUSD)

+ How to use Leverage in PineScript

@ 1 hTradeSearcher backtest

1.23

Profit Factor

15.22 %

Total ROI

152

Sanofi (SAN)

+ How to use Leverage in PineScript

@ 1 h

1.21

Profit Factor

325.17 %

Total ROI

532

British Pound/U.S. Dollar (GBPUSD)

+ How to use Leverage in PineScript

@ DailyTradeSearcher backtest

1.19

Profit Factor

10.18 %

Total ROI

30

Pepsico, Inc. (PEP)

+ How to use Leverage in PineScript

@ 15 min

1.19

Profit Factor

99.98 %

Total ROI

217

Gold Futures (GC1!)

+ How to use Leverage in PineScript

@ 5 minTradeSearcher backtest

1.19

Profit Factor

36.72 %

Total ROI

173

Euro Fx/U.S. Dollar (EURUSD)

+ How to use Leverage in PineScript

@ 4 hTradeSearcher backtest

1.16

Profit Factor

19.65 %

Total ROI

168

Create your account for free to see all 21+ backtests

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

Active Trades

Create your account to see on which symbols How to use Leverage in PineScript is currently trading on.

How to use Leverage in PineScript 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 long-term by holding period.

21
Backtests run
1.2
Avg profit factor
+71%
Avg net profit
+21%
Avg annualized return
38%
Avg max drawdown
0.18
Avg Sharpe ratio

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

Performance by asset class

MarketBacktestsAvg profit factorAvg net profitAvg max drawdownAvg Sharpe
Stocks7241.2+148%62%0.13
Forex661.3+20%18%0.15

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