Description Usage Arguments Value
Given a numeric series x
, compute its n
-offset forward
difference y
, such that y[i] = x[i+n] - x[i]
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | ForwardDifference(x, ...)
## S3 method for class 'numeric'
ForwardDifference(x, n = 1, order = 1, samplingRate = n,
...)
## S3 method for class 'data.frame'
ForwardDifference(x, n = 1, order = 1, ...)
## S3 method for class 'list'
ForwardDifference(x, n = 1, order = 1, ...)
## S3 method for class 'list'
CentralDifference(x, n = 1, order = 1, ...)
|
x |
A numeric vector or a data frame of numeric vectors. |
... |
Placeholder for future methods. |
n |
An atomic numeric, the number of samples forward from the current
sample used in the forward difference. Default is |
order |
An atomic numeric, the number of times the forward-difference
operator is applied to |
samplingRate |
An atomic numeric, the sampling rate of |
The forward difference of x
if x
is numeric, or of
each column of x
if x
is a data frame.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.