| Library: | finance |
| See also: | kpss rvlm lo robwhittle roblm lobrob gph neweywest |
| Quantlet: | kpssnum | |
| Description: | Calculates the KPSS statistics for I(0) processes against long-memory alternatives. We consider two tests, denoted by KPSS_mu and KPSS_t, based on a regression on a constant mu, and on a constant and a time trend t, respectively. The quantlet returns the value of the estimated statistic for two the types of the test, i.e., const or trend and the critical values for a 95 percent confidence interval for I(0) (const, trend). |
| Usage: | (kp, critvalue) = kpssnum(y,T) | |
| Input: | ||
| y | vector | |
| T | scalar, truncation lag for the autocorrelation consistent variance estimator | |
| Output: | ||
| kp | vector | |
| critvalue | vector | |
;Non-stationarity test on the series dmus58.dat.
library("times")
x = read("dmus58.dat") ; 25477 obs: log FX rates
x = x[1:1000]
kpssnum(x,0) ;
Values of the test statistics and its critical values.