> 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.

# OnFundamentalData()

## Definition

An event driven method which is called for every change in fundamental data for the underlying instrument.

This method is NOT called on historical data (backtest).

## Method Return Value

This method does not return a value.

## Syntax

You must override the method in your strategy or indicator with the following syntax.

**protected override void OnFundamentalData(FundamentalDataEventArgs fundamentalDataUpdate)**

The NinjaScript code wizards can automatically generate the method syntax for you when creating a new script.

## Parameters

| Parameter                 | Description                                                                                                                                                        |
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **fundamentalDataUpdate** | [FundamentalDataEventArgs](/developer/desktop-sdk/references/common/onfundamentaldata/fundamentaldataeventargs) representing the recent change in fundamental data |

## Examples

```csharp
protected override void OnFundamentalData(FundamentalDataEventArgs fundamentalDataUpdate)
{
    // Print some data to the Output window
    if (fundamentalDataUpdate.FundamentalDataType == FundamentalDataType.AverageDailyVolume)
        Print("The current ADV is " + fundamentalDataUpdate.LongValue);
}
```

1. With [multi-time frame and instrument strategies](/developer/desktop-sdk/guides/educational-resources/multi-time-frame-instruments), OnFundamentalData() will be called for all unique instruments in your strategy. Use the [BarsInProgress](/developer/desktop-sdk/references/common/adddataseries/barsinprogress) to filter the OnFundamentalData() method for a specific instrument.
2. Do not leave an unused OnFundamentalData() method declared in your NinjaScript object. This will unnecessarily attach a data stream to your script which uses unnecessary CPU cycles.