> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.ninjatrader.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.ninjatrader.com/_mcp/server.

# Displacement

## Definition

An offset value that shifts the visually displayed value of an indicator.

## Property Value

An **int** value that represents the number of bars ago to offset with.

## Syntax

`Displacement`

## Examples

```csharp
protected override void OnStateChange()
{
    if (State == State.SetDefaults)
    {
        Displacement = 2; // Plots the indicator value from 2 bars ago on the current bar
        AddPlot(Brushes.Orange, "SMA");
    }
}
```