Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_grangercausality.wasp
Title produced by softwareBivariate Granger Causality
Date of computationTue, 08 Dec 2009 09:57:17 -0700
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2009/Dec/08/t1260291491fgkrff7qu1iw151.htm/, Retrieved Sat, 27 Apr 2024 19:25:40 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=64733, Retrieved Sat, 27 Apr 2024 19:25:40 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact152
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-     [Bivariate Granger Causality] [] [2009-12-07 08:54:13] [b98453cac15ba1066b407e146608df68]
-   PD  [Bivariate Granger Causality] [WS 10 Granger Xt-...] [2009-12-08 16:52:54] [83058a88a37d754675a5cd22dab372fc]
- R  D      [Bivariate Granger Causality] [WS 10 Granger Xt-...] [2009-12-08 16:57:17] [eba9f01697e64705b70041e6f338cb22] [Current]
- R P         [Bivariate Granger Causality] [WS 10 Granger Xt-...] [2009-12-08 18:41:10] [83058a88a37d754675a5cd22dab372fc]
-   P           [Bivariate Granger Causality] [WS 10 Granger Xt-...] [2009-12-08 19:19:32] [83058a88a37d754675a5cd22dab372fc]
- R               [Bivariate Granger Causality] [WS 10 Granger Xt-...] [2009-12-08 19:54:17] [83058a88a37d754675a5cd22dab372fc]
Feedback Forum

Post a new message
Dataseries X:
87.28
87.28
87.09
86.92
87.59
90.72
90.69
90.30
89.55
88.94
88.41
87.82
87.07
86.82
86.40
86.02
85.66
85.32
85.00
84.67
83.94
82.83
81.95
81.19
80.48
78.86
69.47
68.77
70.06
73.95
75.80
77.79
81.57
83.07
84.34
85.10
85.25
84.26
83.63
86.44
85.30
84.10
83.36
82.48
81.58
80.47
79.34
82.13
81.69
80.70
79.88
79.16
78.38
77.42
76.47
75.46
74.48
78.27
80.70
79.91
78.75
77.78
81.14
81.08
80.03
78.91
78.01
76.90
75.97
81.93
80.27
78.67
77.42
76.16
74.70
76.39
76.04
74.65
73.29
71.79
74.39
74.91
74.54
73.08
72.75
71.32
70.38
70.35
70.01
69.36
67.77
69.26
69.80
68.38
67.62
68.39
66.95
65.21
66.64
63.45
60.66
62.34
60.32
58.64
60.46
58.59
61.87
61.85
67.44
77.06
91.74
93.15
94.15
93.11
91.51
89.96
88.16
86.98
88.03
86.24
84.65
83.23
81.70
80.25
78.80
77.51
76.20
75.04
74.00
75.49
77.14
76.15
76.27
78.19
76.49
77.31
76.65
74.99
73.51
72.07
70.59
71.96
76.29
74.86
74.93
71.90
71.01
77.47
75.78
76.60
76.07
74.57
73.02
72.65
73.16
71.53
69.78
67.98
69.96
72.16
70.47
68.86
67.37
65.87
72.16
71.34
69.93
68.44
67.16
66.01
67.25
70.91
69.75
68.59
67.48
66.31
64.81
66.58
65.97
64.70
64.70
60.94
59.08
58.42
57.77
57.11
53.31
49.96
49.40
48.84
48.30
47.74
47.24
46.76
46.29
48.90
49.23
48.53
48.03
54.34
53.79
53.24
52.96
52.17
51.70
58.55
78.20
77.03
76.19
77.15
75.87
95.47
109.67
112.28
112.01
107.93
105.96
105.06
102.98
102.20
105.23
101.85
99.89
96.23
94.76
91.51
91.63
91.54
85.23
87.83
87.38
84.44
85.19
84.03
86.73
102.52
104.45
106.98
107.02
99.26
94.45
113.44
157.33
147.38
171.89
171.95
132.71
126.02
121.18
115.45
110.48
117.85
117.63
124.65
109.59
111.27
99.78
98.21
99.20
97.97
89.55
87.91
93.34
94.42
93.20
90.29
91.46
89.98
88.35
88.41
82.44
79.89
75.69
75.66
84.50
96.73
87.48
82.39
83.48
79.31
78.16
72.77
72.45
68.46
67.62
68.76
70.07
68.55
65.30
58.96
59.17
62.37
66.28
55.62
55.23
55.85
56.75
50.89
53.88
52.95
55.08
53.61
58.78
61.85
55.91
53.32
46.41
44.57
50.00
50.00
53.36
46.23
50.45
49.07
45.85
48.45
49.96
46.53
50.51
47.58
48.05
46.84
47.67
49.16
55.54
55.82
58.22
56.19
57.77
63.19
54.76
55.74
62.54
61.39
69.60
79.23
80.00
93.68
107.63
100.18
97.30
90.45
80.64
80.58
75.82
85.59
89.35
89.42
104.73
95.32
89.27
90.44
86.97
79.98
81.22
87.35
83.64
82.22
Dataseries Y:
299.90
339.20
374.20
393.50
389.20
381.70
375.20
369.00
357.40
352.10
346.50
342.90
340.30
328.30
322.90
314.30
308.90
294.00
285.60
281.20
280.30
278.80
274.50
270.40
263.40
259.90
258.00
262.70
284.70
311.30
322.10
327.00
331.30
333.30
321.40
327.00
320.00
314.70
316.70
314.40
321.30
318.20
307.20
301.30
287.50
277.70
274.40
258.80
253.30
251.00
248.40
249.50
246.10
244.50
243.60
244.00
240.80
249.80
248.00
259.40
260.50
260.80
261.30
259.50
256.60
257.90
256.50
254.20
253.30
253.80
255.50
257.10
257.30
253.20
252.80
252.00
250.70
252.20
250.00
251.00
253.40
251.20
255.60
261.10
258.90
259.90
261.20
264.70
267.10
266.40
267.70
268.60
267.50
268.50
268.50
270.50
270.90
270.10
269.30
269.80
270.10
264.90
263.70
264.80
263.70
255.90
276.20
360.10
380.50
373.70
369.80
366.60
359.30
345.80
326.20
324.50
328.10
327.50
324.40
316.50
310.90
301.50
291.70
290.40
287.40
277.70
281.60
288.00
276.00
272.90
283.00
283.30
276.80
284.50
282.70
281.20
287.40
283.10
284.00
285.50
289.20
292.50
296.40
305.20
303.90
311.50
316.30
316.70
322.50
317.10
309.80
303.80
290.30
293.70
291.70
296.50
289.10
288.50
293.80
297.70
305.40
302.70
302.50
303.00
294.50
294.10
294.50
297.10
289.40
292.40
287.90
286.60
280.50
272.40
269.20
270.60
267.30
262.50
266.80
268.80
263.10
261.20
266.00
262.50
265.20
261.30
253.70
249.20
239.10
236.40
235.20
245.20
246.20
247.70
251.40
253.30
254.80
250.00
249.30
241.50
243.30
248.00
253.00
252.90
251.50
251.60
253.50
259.80
334.10
448.00
445.80
445.00
448.20
438.20
439.80
423.40
410.80
408.40
406.70
405.90
402.70
405.10
399.60
386.50
381.40
375.20
357.70
359.00
355.00
352.70
344.40
343.80
338.00
339.00
333.30
334.40
328.30
330.70
330.00
331.60
351.20
389.40
410.90
442.80
462.80
466.90
461.70
439.20
430.30
416.10
402.50
397.30
403.30
395.90
387.80
378.60
377.10
370.40
362.00
350.30
348.20
344.60
343.50
342.80
347.60
346.60
349.50
342.10
342.00
342.80
339.30
348.20
333.70
334.70
354.00
367.70
363.30
358.40
353.10
343.10
344.60
344.40
333.90
331.70
324.30
321.20
322.40
321.70
320.50
312.80
309.70
315.60
309.70
304.60
302.50
301.50
298.80
291.30
293.60
294.60
285.90
297.60
301.10
293.80
297.70
292.90
292.10
287.20
288.20
283.80
299.90
292.40
293.30
300.80
293.70
293.10
294.40
292.10
291.90
282.50
277.90
287.50
289.20
285.60
293.20
290.80
283.10
275.00
287.80
287.80
287.40
284.00
277.80
277.60
304.90
294.00
300.90
324.00
332.90
341.60
333.40
348.20
344.70
344.70
329.30
323.50
323.20
317.40
330.10
329.20
334.90
315.80
315.40
319.60
317.30
313.80
315.80
311.30




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135

\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input & view raw input (R code)  \tabularnewline
Raw Output & view raw output of R engine  \tabularnewline
Computing time & 2 seconds \tabularnewline
R Server & 'Gwilym Jenkins' @ 72.249.127.135 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=64733&T=0

[TABLE]
[ROW][C]Summary of computational transaction[/C][/ROW]
[ROW][C]Raw Input[/C][C]view raw input (R code) [/C][/ROW]
[ROW][C]Raw Output[/C][C]view raw output of R engine [/C][/ROW]
[ROW][C]Computing time[/C][C]2 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'Gwilym Jenkins' @ 72.249.127.135[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=64733&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=64733&T=0

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135







Granger Causality Test: Y = f(X)
ModelRes.DFDiff. DFFp-value
Complete model339
Reduced model345-62.556974230962090.0195467595995095

\begin{tabular}{lllllllll}
\hline
Granger Causality Test: Y = f(X) \tabularnewline
Model & Res.DF & Diff. DF & F & p-value \tabularnewline
Complete model & 339 &  &  &  \tabularnewline
Reduced model & 345 & -6 & 2.55697423096209 & 0.0195467595995095 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=64733&T=1

[TABLE]
[ROW][C]Granger Causality Test: Y = f(X)[/C][/ROW]
[ROW][C]Model[/C][C]Res.DF[/C][C]Diff. DF[/C][C]F[/C][C]p-value[/C][/ROW]
[ROW][C]Complete model[/C][C]339[/C][C][/C][C][/C][C][/C][/ROW]
[ROW][C]Reduced model[/C][C]345[/C][C]-6[/C][C]2.55697423096209[/C][C]0.0195467595995095[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=64733&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=64733&T=1

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Granger Causality Test: Y = f(X)
ModelRes.DFDiff. DFFp-value
Complete model339
Reduced model345-62.556974230962090.0195467595995095







Granger Causality Test: X = f(Y)
ModelRes.DFDiff. DFFp-value
Complete model339
Reduced model345-67.261889123953932.60977389422051e-07

\begin{tabular}{lllllllll}
\hline
Granger Causality Test: X = f(Y) \tabularnewline
Model & Res.DF & Diff. DF & F & p-value \tabularnewline
Complete model & 339 &  &  &  \tabularnewline
Reduced model & 345 & -6 & 7.26188912395393 & 2.60977389422051e-07 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=64733&T=2

[TABLE]
[ROW][C]Granger Causality Test: X = f(Y)[/C][/ROW]
[ROW][C]Model[/C][C]Res.DF[/C][C]Diff. DF[/C][C]F[/C][C]p-value[/C][/ROW]
[ROW][C]Complete model[/C][C]339[/C][C][/C][C][/C][C][/C][/ROW]
[ROW][C]Reduced model[/C][C]345[/C][C]-6[/C][C]7.26188912395393[/C][C]2.60977389422051e-07[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=64733&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=64733&T=2

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Granger Causality Test: X = f(Y)
ModelRes.DFDiff. DFFp-value
Complete model339
Reduced model345-67.261889123953932.60977389422051e-07



Parameters (Session):
Parameters (R input):
par1 = 1 ; par2 = 0 ; par3 = 0 ; par4 = 12 ; par5 = 1 ; par6 = 0 ; par7 = 0 ; par8 = 3 ;
R code (references can be found in the software module):
library(lmtest)
par1 <- as.numeric(par1)
par2 <- as.numeric(par2)
par3 <- as.numeric(par3)
par4 <- as.numeric(par4)
par5 <- as.numeric(par5)
par6 <- as.numeric(par6)
par7 <- as.numeric(par7)
par8 <- 6
ox <- x
oy <- y
if (par1 == 0) {
x <- log(x)
} else {
x <- (x ^ par1 - 1) / par1
}
if (par5 == 0) {
y <- log(y)
} else {
y <- (y ^ par5 - 1) / par5
}
if (par2 > 0) x <- diff(x,lag=1,difference=par2)
if (par6 > 0) y <- diff(y,lag=1,difference=par6)
if (par3 > 0) x <- diff(x,lag=par4,difference=par3)
if (par7 > 0) y <- diff(y,lag=par4,difference=par7)
x
y
(gyx <- grangertest(y ~ x, order=par8))
(gxy <- grangertest(x ~ y, order=par8))
bitmap(file='test1.png')
op <- par(mfrow=c(2,1))
(r <- ccf(ox,oy,main='Cross Correlation Function (raw data)',ylab='CCF',xlab='Lag (k)'))
(r <- ccf(x,y,main='Cross Correlation Function (transformed and differenced)',ylab='CCF',xlab='Lag (k)'))
par(op)
dev.off()
bitmap(file='test2.png')
op <- par(mfrow=c(2,1))
acf(ox,lag.max=round(length(x)/2),main='ACF of x (raw)')
acf(x,lag.max=round(length(x)/2),main='ACF of x (transformed and differenced)')
par(op)
dev.off()
bitmap(file='test3.png')
op <- par(mfrow=c(2,1))
acf(oy,lag.max=round(length(y)/2),main='ACF of y (raw)')
acf(y,lag.max=round(length(y)/2),main='ACF of y (transformed and differenced)')
par(op)
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Granger Causality Test: Y = f(X)',5,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Model',header=TRUE)
a<-table.element(a,'Res.DF',header=TRUE)
a<-table.element(a,'Diff. DF',header=TRUE)
a<-table.element(a,'F',header=TRUE)
a<-table.element(a,'p-value',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Complete model',header=TRUE)
a<-table.element(a,gyx$Res.Df[1])
a<-table.element(a,'')
a<-table.element(a,'')
a<-table.element(a,'')
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Reduced model',header=TRUE)
a<-table.element(a,gyx$Res.Df[2])
a<-table.element(a,gyx$Df[2])
a<-table.element(a,gyx$F[2])
a<-table.element(a,gyx$Pr[2])
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable1.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Granger Causality Test: X = f(Y)',5,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Model',header=TRUE)
a<-table.element(a,'Res.DF',header=TRUE)
a<-table.element(a,'Diff. DF',header=TRUE)
a<-table.element(a,'F',header=TRUE)
a<-table.element(a,'p-value',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Complete model',header=TRUE)
a<-table.element(a,gxy$Res.Df[1])
a<-table.element(a,'')
a<-table.element(a,'')
a<-table.element(a,'')
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Reduced model',header=TRUE)
a<-table.element(a,gxy$Res.Df[2])
a<-table.element(a,gxy$Df[2])
a<-table.element(a,gxy$F[2])
a<-table.element(a,gxy$Pr[2])
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable2.tab')