Financial Time Series Toolbox    
tsaccel

Acceleration between periods

Syntax

Arguments

data
Data series
nperiods
(Optional) Number of periods. Default = 12.
datatype
(Optional) Indicates whether data contains the data itself or the momentum of the data:
0 = data contains the data itself (default).
1 = data contains the momentum of the data.
tsobj
Name of an existing financial time series object

Description

acc = tsaccel(data, nperiods, datatype) calculates the acceleration of a data series, essentially the difference of the current momentum with the momentum some number of periods ago. If nperiods is specified, tsaccel calculates the acceleration of a data series data with time distance of nperiods periods.

accts = tsaccel(tsobj, nperiods, datatype) calculates the acceleration of the data series in the financial time series object tsobj, essentially the difference of the current momentum with the momentum some number of periods ago. Each data series in tsobj is treated individually. accts is a financial time series object with similar dates and data series names as tsobj.

Examples

Compute the acceleration for Disney stock and plot the results:

See Also

tsmom

Reference

Kaufman, P. J., The New Commodity Trading Systems and Methods, New York: John Wiley & Sons, 1987.


  toweekly tsmom