[R-SIG-Finance] Differencing / Detrending in "vars"-Package

Adams, Zeno Zeno.Adams at ebs.edu
Tue Nov 9 15:48:55 CET 2010


Gero,

>> Now the question: Does inclusion of the trend coefficient free me
from worrying about nonstationarity?

No, if the data has a stochastic trend then the inclusion of a
deterministic trend does not make the series stationary. This is exactly
the mistake that many researchers made prior to the influential
Nelson/Plosser paper from 1982 (Nelson, C.R., and Plosser C.R. (1982),
Trends and random walks in macroeconmic time series : Some evidence and
implications, Journal of Monetary Economics,139-162). From my experience
the case that economic or financial data becomes stationary after
removing a deterministic trend (i.e. the series are "trend-stationary")
is rare. In most cases, level data is made stationary by taking first
(log-) differences.

Zeno

-----Original Message-----
From: r-sig-finance-bounces at stat.math.ethz.ch
[mailto:r-sig-finance-bounces at stat.math.ethz.ch] On Behalf Of Gero
Schwenk
Sent: Dienstag, 9. November 2010 14:47
To: r-sig-finance at stat.math.ethz.ch
Subject: [R-SIG-Finance] Differencing / Detrending in "vars"-Package

Hello together!
I've got a question regarding the use of the "vars"-package. As far as I

know, VAR-models require stationary time series as input, which can 
generally be reached by repeatedly differencing the series and tested 
using unit-root tests.

Now the VAR-function in the "vars"-package allows to include a trend 
coefficient to the model, as seen in the example taken from Cowpertwait,

Metcalfe, "Introductory Time Series with R", Springer:

library(vars)
US.var <- VAR(cbind(GNP, M1), p = 3, type = "trend")
summary(US.var)

The output, which is shown below, reports all roots of the 
characteristic polynomial being smaller than one, indicating an 
integrative, nonstationary process. Now the question: Does inclusion of 
the trend coefficient free me from worrying about nonstationarity? 
(Obviously, a stationary series should contain no deterministic trend.)
I Would be very happy for hints...
Cheers and thanks,
Gero

####

 > summary(US.var)

VAR Estimation Results:
=========================
Endogenous variables: GNP, M1
Deterministic variables: trend
Sample size: 133
Log Likelihood: -1003.311
Roots of the characteristic polynomial:
0.999 0.9109 0.6363 0.5036 0.3491 0.03296
Call:
VAR(y = cbind(GNP, M1), p = 3, type = "trend")


Estimation results for equation GNP:
====================================
GNP = GNP.l1 + M1.l1 + GNP.l2 + M1.l2 + GNP.l3 + M1.l3 + trend

Estimate Std. Error t value Pr(>|t|)
GNP.l1 1.075374 0.088430 12.161 <2e-16 ***
M1.l1 1.036148 0.410287 2.525 0.0128 *
GNP.l2 -0.006781 0.132817 -0.051 0.9594
M1.l2 -0.300379 0.754331 -0.398 0.6912
GNP.l3 -0.127237 0.085086 -1.495 0.1373
M1.l3 -0.563697 0.445689 -1.265 0.2083
trend 1.035030 0.435195 2.378 0.0189 *
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1


Residual standard error: 23.31 on 126 degrees of freedom
Multiple R-Squared: 0.9999, Adjusted R-squared: 0.9999
F-statistic: 2.398e+05 on 7 and 126 DF, p-value: < 2.2e-16


Estimation results for equation M1:
===================================
M1 = GNP.l1 + M1.l1 + GNP.l2 + M1.l2 + GNP.l3 + M1.l3 + trend

Estimate Std. Error t value Pr(>|t|)
GNP.l1 -0.04391 0.01911 -2.298 0.02319 *
M1.l1 1.59231 0.08865 17.961 < 2e-16 ***
GNP.l2 0.06165 0.02870 2.148 0.03362 *
M1.l2 -0.48914 0.16299 -3.001 0.00325 **
GNP.l3 -0.01755 0.01839 -0.954 0.34170
M1.l3 -0.10411 0.09630 -1.081 0.28174
trend 0.01160 0.09404 0.123 0.90204
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1


Residual standard error: 5.036 on 126 degrees of freedom
Multiple R-Squared: 0.9999, Adjusted R-squared: 0.9999
F-statistic: 1.899e+05 on 7 and 126 DF, p-value: < 2.2e-16



Covariance matrix of residuals:
GNP M1
GNP 543.11 12.21
M1 12.21 25.36

Correlation matrix of residuals:
GNP M1
GNP 1.0000 0.1041
M1 0.1041 1.0000

_______________________________________________
R-SIG-Finance at stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-sig-finance
-- Subscriber-posting only. If you want to post, subscribe first.
-- Also note that this is not the r-help list where general R questions
should go.

EBS European Business School gemeinnuetzige GmbH, Universitaet fuer Wirtschaft und Recht i.Gr. - Amtsgericht Wiesbaden HRB 19951 - Umsatzsteuer-ID DE 113891213 Geschaeftsfuehrung: Prof. Dr. Christopher Jahns,  President; Prof. Dr. Rolf Tilmes, Dean Business School; Sabine Fuchs, CMO; Prof. Dr. Dr. Gerrick Frhr. v. Hoyningen-Huene, Dean Law School; Verwaltungsrat: Dr. Hellmut K. Albrecht, Vorsitzender


More information about the R-SIG-Finance mailing list