Description Usage Arguments Details Value Author(s)
View source: R/ConvenienceFunctions.R
Substract a linear trend from a vector
1 |
x |
Vector or time series to be detrended |
returntrend |
When FALSE the detrended vector is returned, when TRUE a 2 element list is returned with both the trend and the detrended vector |
The linear trend is calculated as lm(x~1:length(x))
The detrended vector. When returntrend = TRUE
a 2 element
list is returned with the trend and the detrended vector.
Tom Cox <tom.cox@uantwerp.be>
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.