# Percentage Price Oscillator (PPO)

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

The Percentage Price Oscillator displays the percentage difference between two moving averages. It is classed as a momentum indicator and is similar to the MACD in its construction.

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

The PPO can be used for divergence analysis. The divergences have the advantage of having a higher percentual hit rate. On the downside, they often appear too early and thus are hard for newer traders to assess properly.

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

```csharp
PPO(int fast, int slow, int smooth)
PPO(IDataSeries inSeries, int fast, int slow, int smooth)
PPO(int fast, int slow, int smooth)[int barsAgo]
PPO(IDataSeries inSeries, int fast, int slow, int smooth)[int barsAgo]

//For the smoothed value
PPO(int fast, int slow, int smooth).Smoothed[int barsAgo]
PPO(IDataSeries inSeries, int fast, int slow, int smooth).Smoothed[int barsAgo]
```

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

**double**

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

#### Parameters <a href="#parameters_72" id="parameters_72"></a>

inSeries Input data series for the indicator

fast Number of bars for the calculation of the fast EMA

slow Number of bars for the calculation of the slow EMA

smooth Number of bars for the calculation of the EMA signal line

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

![Percentage Price Oscillator (PPO)](https://agenatrader.github.io/AgenaIndicator-documentation/media/PPO.jpg)

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

```csharp
//Output for the PPO
Print("The current value for the PPO is " + PPO(12, 26, 9)[0]);

//Output for the value of the PPO smoothed
Print("The current value for the PPO is " + PPO(12, 26, 9).Smoothed[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/percentage-price-oscillator-ppo.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.
