search for: wavestrap

Displaying 1 result from an estimated 1 matches for "wavestrap".

2009 Feb 24
0
Wavelet Bootstrap Size Simulation
...ta)/(length(x)+1) Rn <- rep(0, length(x)) coeff <- Rn for (i in 1:length(x)){ coeff[i] <- fitphi(data,x,i) } for (j in 1:length(x)){ Rn[j]<-(24/j)*length(data)*sum((coeff[1:j])^2) } max(Rn) } #The function used to find the wavelet bootstrap replicate of the original series wavestrap <- function (y, wf = "d8", J = log(length(y), 2) - 1, infl = sqrt(1.1)){ y.dwt <- dwt(y, wf, n.levels = J) resample.dwt <- y.dwt for (i in 1:(length(y.dwt)-1)) { resample.dwt[[i]] <- sample(y.dwt[[i]]*infl, replace = TRUE) } idwt(resample.dwt) }...