Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_cross.wasp
Title produced by softwareCross Correlation Function
Date of computationTue, 02 Dec 2008 12:53:33 -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/2008/Dec/02/t1228247799uqb4lr1iohghhb9.htm/, Retrieved Sun, 19 May 2024 11:39:03 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=28300, Retrieved Sun, 19 May 2024 11:39:03 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact155
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
F       [Cross Correlation Function] [law of averages q7] [2008-12-02 19:53:33] [2a6ed4ba8662f0ce2b179e623f45ffb0] [Current]
Feedback Forum
2008-12-06 14:00:00 [Thomas Plasschaert] [reply
Met de cross correlatiefunctie kan men nagaan in hoeverre Y te verklaren valt door het verleden van X. X = totale productie van intermediaire goederen en Y= totale productie investeringsgoederen. rho(Y[t],X[t+k]) geeft de correlatie aan tussen het verleden van X en het heden van Y wanneer k kleiner is dan 0. (is er sprake van een leading indicator?) Wanneer k groter is dan 0 geeft het de correlatie weer tussen de toekomstige x en het heden van Y (is er sprake van een lagging indicator)?
2008-12-09 23:03:43 [Peter Van Doninck] [reply
Met de cross correlatiefunctie kunnen we verbanden op een dynamische manier onderzoeken. Op basis waarvan kan ik bijvoorbeeld Yt voorspellen. Er is geen trendmatig verloop, en er kan ook niet gedifferentieerd worden! De conclusie van de student dat het maken van voorspellingen niet interessant is, klopt hier wel. De cross correlaties zijn hier laag, en ze verschillen niet significant van de nul hypothese.

Post a new message
Dataseries X:
61,5
88,5
93,3
89,2
101,3
97
102,2
100,3
78,2
105,9
119,9
108
77
93,1
109,5
100,4
99
113,9
102,1
101,6
84
110,7
111,6
110,7
73,1
87,5
109,6
99,3
92,1
109,3
94,5
91,4
82,9
103,3
96
104,8
65,8
78,7
100,3
85
94,5
97,9
91,9
87,2
84,4
99,2
105,4
110,9
69,8
86,8
106,7
88,8
96,9
108,1
93,7
94,8
79,8
95,6
107,9
104,9
61,9
85,7
92,4
86,4
99,3
95,5
97
102,1
77,8
105,5
113,2
108,8
66,9
89,3
93,6
92
99,5
98,6
94,6
96,7
75,3
102,5
115,1
104,7
71,4
Dataseries Y:
200,7
146,5
143,6
141,5
137,5
138,7
135,5
136,4
112,1
109
123,8
151,2
139,2
115,7
147,6
126,1
122,8
137,3
142
137,4
89,4
108
117,7
127,3
121
104,1
119,5
116,7
96,1
125
118,8
114,9
79,3
90,5
87,8
109,4
88,9
97,4
112
86,8
82,9
105,2
89,1
85,5
87,1
85,2
88,2
104
96,4
82,3
114,1
88,9
93,6
101,8
96,6
93,7
68,4
68,7
81,2
85,1
75,4
71,6
83
72,3
90,2
89
84,9
90,9
46,6
55,4
88,7
76
76,9
72,1
90
92,3
78
93,9
84,5
80,4
60,5
75,3
91,5
105,2
92,7




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24

\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 & 'Sir Ronald Aylmer Fisher' @ 193.190.124.24 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=28300&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]'Sir Ronald Aylmer Fisher' @ 193.190.124.24[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=28300&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=28300&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'Sir Ronald Aylmer Fisher' @ 193.190.124.24







Cross Correlation Function
ParameterValue
Box-Cox transformation parameter (lambda) of X series1
Degree of non-seasonal differencing (d) of X series0
Degree of seasonal differencing (D) of X series0
Seasonal Period (s)1
Box-Cox transformation parameter (lambda) of Y series1
Degree of non-seasonal differencing (d) of Y series0
Degree of seasonal differencing (D) of Y series0
krho(Y[t],X[t+k])
-16-0.0128301267046171
-15-0.0220114287378523
-14-0.0710498587567868
-130.0880623725545588
-120.153546826847918
-11-0.153152701554895
-10-0.0938171894281922
-90.113675640571929
-80.286599463527252
-70.0858840939931304
-60.0121257561794287
-50.0368880588534752
-40.057734095620019
-30.0234474199311871
-2-0.0162830548976681
-10.183215849813638
00.162614483412634
1-0.108481999647707
20.00410282562437349
30.212337836696389
40.357800830211363
50.183368237774607
60.0890592368467169
70.0876790264376933
80.0661223625022612
90.138446271429550
100.0807604775438559
110.218524344681294
120.136828513736307
13-0.107170822439777
140.029210893765009
150.163493612304624
160.24990846793829

\begin{tabular}{lllllllll}
\hline
Cross Correlation Function \tabularnewline
Parameter & Value \tabularnewline
Box-Cox transformation parameter (lambda) of X series & 1 \tabularnewline
Degree of non-seasonal differencing (d) of X series & 0 \tabularnewline
Degree of seasonal differencing (D) of X series & 0 \tabularnewline
Seasonal Period (s) & 1 \tabularnewline
Box-Cox transformation parameter (lambda) of Y series & 1 \tabularnewline
Degree of non-seasonal differencing (d) of Y series & 0 \tabularnewline
Degree of seasonal differencing (D) of Y series & 0 \tabularnewline
k & rho(Y[t],X[t+k]) \tabularnewline
-16 & -0.0128301267046171 \tabularnewline
-15 & -0.0220114287378523 \tabularnewline
-14 & -0.0710498587567868 \tabularnewline
-13 & 0.0880623725545588 \tabularnewline
-12 & 0.153546826847918 \tabularnewline
-11 & -0.153152701554895 \tabularnewline
-10 & -0.0938171894281922 \tabularnewline
-9 & 0.113675640571929 \tabularnewline
-8 & 0.286599463527252 \tabularnewline
-7 & 0.0858840939931304 \tabularnewline
-6 & 0.0121257561794287 \tabularnewline
-5 & 0.0368880588534752 \tabularnewline
-4 & 0.057734095620019 \tabularnewline
-3 & 0.0234474199311871 \tabularnewline
-2 & -0.0162830548976681 \tabularnewline
-1 & 0.183215849813638 \tabularnewline
0 & 0.162614483412634 \tabularnewline
1 & -0.108481999647707 \tabularnewline
2 & 0.00410282562437349 \tabularnewline
3 & 0.212337836696389 \tabularnewline
4 & 0.357800830211363 \tabularnewline
5 & 0.183368237774607 \tabularnewline
6 & 0.0890592368467169 \tabularnewline
7 & 0.0876790264376933 \tabularnewline
8 & 0.0661223625022612 \tabularnewline
9 & 0.138446271429550 \tabularnewline
10 & 0.0807604775438559 \tabularnewline
11 & 0.218524344681294 \tabularnewline
12 & 0.136828513736307 \tabularnewline
13 & -0.107170822439777 \tabularnewline
14 & 0.029210893765009 \tabularnewline
15 & 0.163493612304624 \tabularnewline
16 & 0.24990846793829 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=28300&T=1

[TABLE]
[ROW][C]Cross Correlation Function[/C][/ROW]
[ROW][C]Parameter[/C][C]Value[/C][/ROW]
[ROW][C]Box-Cox transformation parameter (lambda) of X series[/C][C]1[/C][/ROW]
[ROW][C]Degree of non-seasonal differencing (d) of X series[/C][C]0[/C][/ROW]
[ROW][C]Degree of seasonal differencing (D) of X series[/C][C]0[/C][/ROW]
[ROW][C]Seasonal Period (s)[/C][C]1[/C][/ROW]
[ROW][C]Box-Cox transformation parameter (lambda) of Y series[/C][C]1[/C][/ROW]
[ROW][C]Degree of non-seasonal differencing (d) of Y series[/C][C]0[/C][/ROW]
[ROW][C]Degree of seasonal differencing (D) of Y series[/C][C]0[/C][/ROW]
[ROW][C]k[/C][C]rho(Y[t],X[t+k])[/C][/ROW]
[ROW][C]-16[/C][C]-0.0128301267046171[/C][/ROW]
[ROW][C]-15[/C][C]-0.0220114287378523[/C][/ROW]
[ROW][C]-14[/C][C]-0.0710498587567868[/C][/ROW]
[ROW][C]-13[/C][C]0.0880623725545588[/C][/ROW]
[ROW][C]-12[/C][C]0.153546826847918[/C][/ROW]
[ROW][C]-11[/C][C]-0.153152701554895[/C][/ROW]
[ROW][C]-10[/C][C]-0.0938171894281922[/C][/ROW]
[ROW][C]-9[/C][C]0.113675640571929[/C][/ROW]
[ROW][C]-8[/C][C]0.286599463527252[/C][/ROW]
[ROW][C]-7[/C][C]0.0858840939931304[/C][/ROW]
[ROW][C]-6[/C][C]0.0121257561794287[/C][/ROW]
[ROW][C]-5[/C][C]0.0368880588534752[/C][/ROW]
[ROW][C]-4[/C][C]0.057734095620019[/C][/ROW]
[ROW][C]-3[/C][C]0.0234474199311871[/C][/ROW]
[ROW][C]-2[/C][C]-0.0162830548976681[/C][/ROW]
[ROW][C]-1[/C][C]0.183215849813638[/C][/ROW]
[ROW][C]0[/C][C]0.162614483412634[/C][/ROW]
[ROW][C]1[/C][C]-0.108481999647707[/C][/ROW]
[ROW][C]2[/C][C]0.00410282562437349[/C][/ROW]
[ROW][C]3[/C][C]0.212337836696389[/C][/ROW]
[ROW][C]4[/C][C]0.357800830211363[/C][/ROW]
[ROW][C]5[/C][C]0.183368237774607[/C][/ROW]
[ROW][C]6[/C][C]0.0890592368467169[/C][/ROW]
[ROW][C]7[/C][C]0.0876790264376933[/C][/ROW]
[ROW][C]8[/C][C]0.0661223625022612[/C][/ROW]
[ROW][C]9[/C][C]0.138446271429550[/C][/ROW]
[ROW][C]10[/C][C]0.0807604775438559[/C][/ROW]
[ROW][C]11[/C][C]0.218524344681294[/C][/ROW]
[ROW][C]12[/C][C]0.136828513736307[/C][/ROW]
[ROW][C]13[/C][C]-0.107170822439777[/C][/ROW]
[ROW][C]14[/C][C]0.029210893765009[/C][/ROW]
[ROW][C]15[/C][C]0.163493612304624[/C][/ROW]
[ROW][C]16[/C][C]0.24990846793829[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=28300&T=1

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

As an alternative you can also use a QR Code:  

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

Cross Correlation Function
ParameterValue
Box-Cox transformation parameter (lambda) of X series1
Degree of non-seasonal differencing (d) of X series0
Degree of seasonal differencing (D) of X series0
Seasonal Period (s)1
Box-Cox transformation parameter (lambda) of Y series1
Degree of non-seasonal differencing (d) of Y series0
Degree of seasonal differencing (D) of Y series0
krho(Y[t],X[t+k])
-16-0.0128301267046171
-15-0.0220114287378523
-14-0.0710498587567868
-130.0880623725545588
-120.153546826847918
-11-0.153152701554895
-10-0.0938171894281922
-90.113675640571929
-80.286599463527252
-70.0858840939931304
-60.0121257561794287
-50.0368880588534752
-40.057734095620019
-30.0234474199311871
-2-0.0162830548976681
-10.183215849813638
00.162614483412634
1-0.108481999647707
20.00410282562437349
30.212337836696389
40.357800830211363
50.183368237774607
60.0890592368467169
70.0876790264376933
80.0661223625022612
90.138446271429550
100.0807604775438559
110.218524344681294
120.136828513736307
13-0.107170822439777
140.029210893765009
150.163493612304624
160.24990846793829



Parameters (Session):
par1 = 1 ; par2 = 0 ; par3 = 0 ; par4 = 1 ; par5 = 1 ; par6 = 0 ; par7 = 0 ;
Parameters (R input):
par1 = 1 ; par2 = 0 ; par3 = 0 ; par4 = 1 ; par5 = 1 ; par6 = 0 ; par7 = 0 ;
R code (references can be found in the software module):
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)
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
bitmap(file='test1.png')
(r <- ccf(x,y,main='Cross Correlation Function',ylab='CCF',xlab='Lag (k)'))
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Cross Correlation Function',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Parameter',header=TRUE)
a<-table.element(a,'Value',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Box-Cox transformation parameter (lambda) of X series',header=TRUE)
a<-table.element(a,par1)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Degree of non-seasonal differencing (d) of X series',header=TRUE)
a<-table.element(a,par2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Degree of seasonal differencing (D) of X series',header=TRUE)
a<-table.element(a,par3)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Seasonal Period (s)',header=TRUE)
a<-table.element(a,par4)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Box-Cox transformation parameter (lambda) of Y series',header=TRUE)
a<-table.element(a,par5)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Degree of non-seasonal differencing (d) of Y series',header=TRUE)
a<-table.element(a,par6)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Degree of seasonal differencing (D) of Y series',header=TRUE)
a<-table.element(a,par7)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'k',header=TRUE)
a<-table.element(a,'rho(Y[t],X[t+k])',header=TRUE)
a<-table.row.end(a)
mylength <- length(r$acf)
myhalf <- floor((mylength-1)/2)
for (i in 1:mylength) {
a<-table.row.start(a)
a<-table.element(a,i-myhalf-1,header=TRUE)
a<-table.element(a,r$acf[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable.tab')