Table of Contents

Class RateOfChange

Namespace
FinanceSharp.Indicators
Assembly
FinanceSharp.dll
 This indicator computes the n-period rate of change in a value using the following:

(value_0 - value_n) / value_n

public class RateOfChange : WindowIndicator, IIndicator, IUpdatable
Inheritance
RateOfChange
Implements
Derived
Inherited Members
Extension Methods

Constructors

RateOfChange(int)

Creates a new RateOfChange indicator with the specified period

public RateOfChange(int period)

Parameters

period int

The period over which to perform to computation

RateOfChange(string, int)

Creates a new RateOfChange indicator with the specified period

public RateOfChange(string name, int period)

Parameters

name string

The name of this indicator

period int

The period over which to perform to computation

Properties

WarmUpPeriod

Required period, in data points, for the indicator to be ready and fully initialized.

public override int WarmUpPeriod { get; }

Property Value

int

Methods

Forward(IReadOnlyWindow<long>, IReadOnlyWindow<DoubleArray>, long, DoubleArray)

Computes the next value for this indicator from the given state.

protected override DoubleArray Forward(IReadOnlyWindow<long> timeWindow, IReadOnlyWindow<DoubleArray> window, long time, DoubleArray input)

Parameters

timeWindow IReadOnlyWindow<long>
window IReadOnlyWindow<DoubleArray>

The window of data held in this indicator

time long
input DoubleArray

The input value to this indicator on this time step

Returns

DoubleArray

A new value for this indicator