View source: R/sie.auto.pacf.R
sie.auto.pacf | R Documentation |
sie.auto.pacf() generates the PACF from 1 to lag automatically.
sie.auto.pacf(ts, c, lag, type, or = 4, m = 500)
ts |
ts is the data set which is a time series data typically |
c |
c indicates the number of basis used to estimate (For wavelet, the number of basis is 2^c.If Cspli is chosen, the real number of basis is c-2+or) |
lag |
lag b is the lag for auto-regressive model |
type |
type indicates which type of basis is used (There are 31 types in this package) |
or |
indicates the order of spline and only used in Cspli type, default is 4 which indicates cubic spline |
m |
m indicates the number of points of coefficients to estimate |
A list contains the PACF in each lag
set.seed(137) time.series = c() n = 1024 v = 25 w = rnorm(n, 0, 1) / v x_ini = runif(1,0,1) for(i in 1:n){ if(i == 1){ time.series[i] = 0.2 + 0.6*cos(2*pi*(i/n))*x_ini + w[i] # } else{ time.series[i] = 0.2 + 0.6*cos(2*pi*(i/n))*time.series[i-1] + w[i] } } sie.auto.pacf(time.series, 5, 1, "Legen")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.