7

I'm using R to calculate the KPSS to check the stationarity.

The library that I'm using is tseries and the function is kpss.test

I have done a simple test using cars (a default matrix on R). The code is:

> k <- kpss.test(cars$dist, null="Trend")
Warning message:
In kpss.test(cars$dist, null = "Trend") :
  p-value greater than printed p-value
> k    
        KPSS Test for Trend Stationarity

data:  cars$dist 
KPSS Trend = 0.0859, Truncation lag parameter = 1, p-value = 0.1

> k$statistic
KPSS Trend 
0.08585069 

> k$parameter
Truncation lag parameter 
                       1 
> k$p.value
[1] 0.1

> k$method
[1] "KPSS Test for Trend Stationarity"

> k$data.name
[1] "cars$dist"

Those are all the results that kpss returns.

My question is: How to interpret them to understand if it is stationary?

Thank you in advance!

Ferdi
  • 4,882
  • 7
  • 42
  • 62
Dail
  • 2,147
  • 12
  • 40
  • 54

1 Answers1

11

You specified a null hypothesis of trend stationarity. That is the data follow a straight line time trend with stationary errors. The p-value is 0.1, so the null hypothesis is not rejected at the usual 5% level.

Rob Hyndman
  • 51,928
  • 23
  • 126
  • 178
  • I could translate your answer as: IF p-value is ABOVE 0.05 the trend is stationary otherwise NOT, correct? – Dail Jul 19 '11 at 08:32
  • 2
    A trend cannot be stationary. The null hypothesis is a time trend with stationary errors, as I explained. – Rob Hyndman Jul 19 '11 at 10:15
  • yes, excuse me: I meant a time trend with stationary errors. by the way, if the p-value is ABOVE 0.05 it means that is mean reverting (Stationary) right? – Dail Jul 19 '11 at 10:32
  • Assuming you are using the 5% level, then a p-value above 0.05 means you have no evidence that it is not trend stationary. That is not the same as saying that it is trend stationary. – Rob Hyndman Jul 20 '11 at 00:28
  • perfect! I understand.... BELOW it i have evidence that it "maybe" trend stationary. – Dail Jul 20 '11 at 07:40
  • If the null hypot. is: trend stationarity and the p-value <0.05, than the null is rejected, i.e. the process is not trend stationary. – Pantera May 01 '13 at 23:01
  • What is the difference between trend stationary and level stationary?? – Summer-Jade Gleek'away Dec 01 '14 at 11:18
  • 2
    Trend stationary means "stationary around the trend", i.e. the trend needn't be stationary, but the de-trended data is. Level stationary means that the data is like white noise. – SiKiHe May 22 '15 at 07:24