Skip to content
Wildflower
Join free
Coding strategies in Pine Script

Free Trading School · Level 7 · Course 7.4

Reading the strategy tester report

Lesson 14 of 16 in Coding strategies in Pine ScriptModule 3: The strategy tester

Advanced · Coding strategies in Pine Script

Reading the strategy tester report

Wildflower Trading School · Lesson 7.4.3.5

Wildflower

Your strategy now places test trades, with a real size and real costs. Today we read what it tells you. By the end of this lesson, you'll know where to find the main numbers, the equity curve and the list of trades. You'll also see how each one links back to Level 4.

1 of 8

What you'll learn

  • Find your way round the tester. Metrics shows totals and the equity curve.
  • Read the main numbers. Look at net P&L, max drawdown, win rate and profit factor.
  • Check a number by hand. Work it out from the List of trades, and check the Size column.
  • Set the date range first. Choose it before you look, and watch for too few trades.

Exercise

  1. Open the Strategy Tester for your EMA cross strategy on a 5-minute MES1! chart.
  2. Write down Total P&L, Max drawdown, Profitable trades and Profit factor.
  3. Then check the profit factor by hand from the List of trades.

Next: Coding mistakes to look for.

Quick check

  1. 1. Where do you see each test trade on its own row?

  2. 2. Winning trades made $500 and losing trades lost $400. Profit factor?

  3. 3. When should you choose the Date range?

0 of 3 answered.

Finished this lesson?

Tick it off and keep your place

Make a free account and we'll remember where you are, so “Coding mistakes to look for” is waiting next time.

Read the full notes

TradingView's Strategy Tester shows a strategy's totals and equity curve under Metrics, every test trade under List of trades, and the strategy's Properties tab shows the settings used; check key numbers by hand and set the date range before you look.

  • The has tabs including Metrics (totals and the ) and List of trades. The strategy's Properties tab shows the settings used. The layout changes from time to time; newer TradingView pages call it the Strategy Report.
  • Made-up example: Total P&L −$64.50 (, after the costs you set), $310, Profitable trades 17/40 (42.5%, the ), 0.93 ($860 ÷ $924.50).
  • Check a number by hand from the List of trades. Check the Size column, and find a few trades on the chart.
  • Set the Date range before looking at results: see Cherry-picking. 40 trades is a small : see How many trades is enough.
  • Level 4 links: Profit factor, Gross and net results, Maximum drawdown and what it means for you, Reading an equity curve and Reading backtest results.

Worked example

Made-up numbers

Check the profit factor by hand

Made-up numbers · 17 winning trades made $860.00 · 23 losing trades lost $924.50

  1. Total P&L: $860.00 − $924.50 = −$64.50
  2. Profit factor: $860.00 ÷ $924.50 = 0.93
  3. Below 1: the test lost more than it made

The report does Level 4 maths for you; checking one number shows you can trust what it means.

Your turn

Drill

Made-up example · equity curve peaks at +$180, then falls to −$45 before it recovers

Trading is risky. You can lose money. Test results are hypothetical, and a good test doesn't mean future profits. This lesson explains how Pine Script works. It isn't advice.