Learn R Programming

TTR (version 0.13-1)

KST: Know Sure Thing

Description

The Know Sure Thing (KST) is a smooth, summed, rate of change indicator. Developed by Martin Pring.

Usage

KST(price, n = c(10, 15, 20, 30), ma1 = list("SMA", n=10), ma2 = ma1, ma3 = ma1, 
         ma4 = list("SMA", n=15), ma.sig = list("SMA", n=10), wts = 1:4)

Arguments

price
Price series to use.
n
A vector of the number of periods to use in the ROC calculations.
ma1
A list whose first component is a string containing the moving average function name; additional parameters may also be specified as named components. There must be a ma (not including ma.sig) for each
ma2
See ma1.
ma3
See ma1.
ma4
See ma1.
ma.sig
A list whose first component is a string containing the signal moving average function name; additional parameters may also be specified as named components.
wts
A vector the same length as n, of the weight for each period (need not sum to one).

Value

  • A vector containing the Know Sure Thing values.

Details

For each day (week, month, etc.), the KST calculates the ROC over several periods. Those ROCs are smoothed using the given moving averages, then multiplied by their respective weighting values. The resulting values are summed for each day (month, week, etc.).

References

The following site(s) were used to code/document this indicator: http://www.pring.com/index.html http://www.pring.com/movieweb/daily_kst.htm http://www.pring.com/articles/article28.htm http://www.pring.com/movieweb/KST_MCM.htm

See Also

See EMA, SMA, etc. for moving average options; and note Warning section. See ROC for the rate-of-change function. See oscillator for other oscillators.

Examples

Run this code
data(ttrc)
  kst <- KST(ttrc[,"Close"])

Run the code above in your browser using DataLab