mrangeFun {qAnalyst} | R Documentation |
Internal function to calculate moving range vector
Description
mrangeFun
returns the moving ranges vector of specified interval from an input vector x.
Usage
mrangeFun(x, sg = 1)
Arguments
x |
individual values vector |
sg |
interval width, default 1 |
Details
NA elements are present in the first interval elements of the returned vector as moving range is not defined there.
Value
A numeric vector of moving ranges.
Note
Internal function
Author(s)
Giorgio Spedicato
References
internal function
See Also
Examples
#simple example
a=c(1,3,5,2,6,2,6,8,2)
print(mrangeFun(a,2))
[Package qAnalyst version 0.6.4 Index]