MSDN Library

Volume Oscillator Formula

The volume oscillator formula measures the difference between a short period moving average of volume and a long period moving average of volume. A positive value indicates a strong trend, and a negative value indicates a weak trend.

Chart.DataManipulator.FinancialFormula(
    FinancialFormula.VolumeOscillator,
    "PeriodShort,PeriodLong,UsePercentage",
    "Volume",
    "VO")

This formula takes three optional parameters.

PeriodShort

Period for calculating the short period moving average. The default value is 5.

PeriodLong

Period for calculating the long period moving average. The default value is 10.

UsePercentage

Whether to output the difference in percentage. When set to false, the formula outputs the difference as a point. The default value is true.

This formula takes one input Y value.

Volume

Volume for which the volume oscillator indicator is calculated.

This formula outputs one Y value.

VO

Volume oscillator indicator.

The Line chart type is a convenient chart type to display the formula output.

The following example takes input from Series1's Y value for volume (Series1:Y) and outputs the volume oscillator indicator on Series2 (Series2:Y). It uses a short period of 10 days and a long period of 30 days.

Chart1.DataManipulator.FinancialFormula (FinancialFormula.VolumeOscillator, "10,30,true", "Series1:Y", "Series3:Y");
Show:
© 2016 Microsoft