Stochastic momentum index - FXB.ta.SMI

The FXB.ta.SMI class calculates the Stochastic momentum index. It is a bar-based calculation, and requires candle data as an input. Parameters are as follows:

Parameter

Description

kPeriod

Period for the %K values (scanning bar high and lows)

kSmoothing

First smoothing period

kDoubleSmoothing

Second smoothing period

maType

Type of moving average for the smoothing. Defaults to a simple moving average (sma / 0).

dPeriod

Period for the %D signal values

maTypeD

Type of moving average for the %D signal values. Defaults to a simple moving average (sma / 0).

The primary output - GetValue() etc - is the %K values. The signal output - GetSignalValue() etc - contains the %D values.