---
title: 'Why does my indicator fail or draw nothing?'
description: "Point at or click the status on the indicator's legend row (such as Code error or Nothing to draw) to see the cause and a Fix line. Then open the script editor: its Console lists the errors, and Kata can fix it."
category: scripting
kind: faq
keywords:
  [
    indicator not working,
    script error,
    draws nothing,
    nothing to draw,
    cant draw lines,
    code error,
    compile my indicator,
    cant add my custom script,
    fix my script,
    no trades in backtest,
    is nan,
    console,
  ]
updatedAt: '2026-11-27'
popularity: 5
---

# Why does my indicator fail or draw nothing?

**The indicator's legend row tells you why: point at its status to see the cause and how to fix it.**

1. On the chart, find the indicator's row in the legend at the top left. A failing indicator shows a short status there, such as **Code error** or **Nothing to draw**.
2. Point at or click the status. A card explains the cause, often with a **Fix:** line, and offers **Copy details** and, for some indicators, **Open in editor**.
3. In the script editor, the **Console** under the code lists the errors and warnings.

Common causes:

- **Code error:** the script does not build. The Console shows what to fix.
- **Nothing to draw:** an output has no value on any bar of this chart (it is NaN everywhere), so nothing is drawn for it. Check the formula behind that output.
- **No trades in a backtest:** the strategy placed no trade on the bars tested. Check its entry rule.

To get help, ask Kata in the editor to fix the script, or press **Copy for LLM** in the Console to hand your code and its errors to another AI assistant. See [Can AI write or fix an indicator for me?](/learn/faq/scripting/ai-writes-indicators) and the wrun docs' [common errors](/wrun/faq/common-errors).
