# OnBalanceVolume (OBV)

#### Description <a href="#description_80" id="description_80"></a>

This indicator displays the buy or sell pressure. For each day with a positive close, the volume is added cumulatively, and it is subtracted for days with a close that is smaller than the open.

#### Interpretation <a href="#interpretation_37" id="interpretation_37"></a>

Granville theorized that volume precedes price. OBV rises when volume on up days outpaces volume on down days. OBV falls when volume on down days is stronger. A rising OBV reflects positive volume pressure that can lead to higher prices. Conversely, falling OBV reflects negative volume pressure that can foreshadow lower prices. Granville noted in his research that OBV would often move before price. Expect prices to move higher if OBV is rising while prices are either flat or moving down. Expect prices to move lower if OBV is falling while prices are either flat or moving up.

The absolute value of OBV is not important. Chartists should instead focus on the characteristics of the OBV line. First define the trend for OBV. Second, determine if the current trend matches the trend for the underlying security. Third, look for potential support or resistance levels. Once broken, the trend for OBV will change and these breaks can be used to generate signals. Also notice that OBV is based on closing prices. Therefore, closing prices should be considered when looking for divergences or support/resistance breaks. And finally, volume spikes can sometimes throw off the indicator by causing a sharp move that will require a settling period. (Source: Stockcharts.com)

#### Usage <a href="#usage_80" id="usage_80"></a>

```csharp
OBV()
OBV(IDataSeries inSeries)
OBV()[int barsAgo]
OBV(IDataSeries inSeries)[int barsAgo]
```

#### Return value <a href="#return-value_77" id="return-value_77"></a>

**double**

When using this method with an index (e.g. **OBV**()\[**int** barsAgo] ), the value of the indicator will be issued for the referenced bar.

#### Parameter <a href="#parameter_7" id="parameter_7"></a>

inSeries Input data series for the indicator

#### Visualization <a href="#visualization_75" id="visualization_75"></a>

![OnBalanceVolume (OBV)](https://agenatrader.github.io/AgenaIndicator-documentation/media/OBV.jpg)

#### Example <a href="#example_76" id="example_76"></a>

```csharp
//Output the value for the On Balance Volume (OBV)
Print("The current value for the OBV is " + OBV()[0]);
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://indicators.agenatrader.com/standard-indicators/onbalancevolume-obv.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
