R version 2.8.0 (2008-10-20)
Copyright (C) 2008 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
Natural language support but running in an English locale
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> x <- array(list(1
+ ,26
+ ,24
+ ,24
+ ,14
+ ,14
+ ,11
+ ,11
+ ,12
+ ,12
+ ,24
+ ,24
+ ,1
+ ,23
+ ,25
+ ,25
+ ,11
+ ,11
+ ,7
+ ,7
+ ,8
+ ,8
+ ,25
+ ,25
+ ,0
+ ,25
+ ,17
+ ,0
+ ,6
+ ,0
+ ,17
+ ,0
+ ,8
+ ,0
+ ,30
+ ,0
+ ,1
+ ,23
+ ,18
+ ,18
+ ,12
+ ,12
+ ,10
+ ,10
+ ,8
+ ,8
+ ,19
+ ,19
+ ,1
+ ,19
+ ,18
+ ,18
+ ,8
+ ,8
+ ,12
+ ,12
+ ,9
+ ,9
+ ,22
+ ,22
+ ,0
+ ,29
+ ,16
+ ,0
+ ,10
+ ,0
+ ,12
+ ,0
+ ,7
+ ,0
+ ,22
+ ,0
+ ,1
+ ,25
+ ,20
+ ,20
+ ,10
+ ,10
+ ,11
+ ,11
+ ,4
+ ,4
+ ,25
+ ,25
+ ,1
+ ,21
+ ,16
+ ,16
+ ,11
+ ,11
+ ,11
+ ,11
+ ,11
+ ,11
+ ,23
+ ,23
+ ,1
+ ,22
+ ,18
+ ,18
+ ,16
+ ,16
+ ,12
+ ,12
+ ,7
+ ,7
+ ,17
+ ,17
+ ,1
+ ,25
+ ,17
+ ,17
+ ,11
+ ,11
+ ,13
+ ,13
+ ,7
+ ,7
+ ,21
+ ,21
+ ,1
+ ,24
+ ,23
+ ,23
+ ,13
+ ,13
+ ,14
+ ,14
+ ,12
+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
+ ,1
+ ,12
+ ,22
+ ,22
+ ,9
+ ,9
+ ,14
+ ,14
+ ,6
+ ,6
+ ,19
+ ,19
+ ,1
+ ,20
+ ,20
+ ,20
+ ,11
+ ,11
+ ,20
+ ,20
+ ,13
+ ,13
+ ,24
+ ,24
+ ,1
+ ,21
+ ,17
+ ,17
+ ,9
+ ,9
+ ,13
+ ,13
+ ,6
+ ,6
+ ,19
+ ,19
+ ,1
+ ,24
+ ,28
+ ,28
+ ,14
+ ,14
+ ,11
+ ,11
+ ,8
+ ,8
+ ,24
+ ,24
+ ,1
+ ,22
+ ,22
+ ,22
+ ,13
+ ,13
+ ,15
+ ,15
+ ,10
+ ,10
+ ,22
+ ,22
+ ,1
+ ,20
+ ,31
+ ,31
+ ,16
+ ,16
+ ,19
+ ,19
+ ,16
+ ,16
+ ,17
+ ,17)
+ ,dim=c(12
+ ,159)
+ ,dimnames=list(c('Br'
+ ,'org'
+ ,'cm'
+ ,'cm_b'
+ ,'d'
+ ,'d_b'
+ ,'pe'
+ ,'pe_b'
+ ,'pc'
+ ,'pc_b'
+ ,'ps'
+ ,'ps_b')
+ ,1:159))
> y <- array(NA,dim=c(12,159),dimnames=list(c('Br','org','cm','cm_b','d','d_b','pe','pe_b','pc','pc_b','ps','ps_b'),1:159))
> for (i in 1:dim(x)[1])
+ {
+ for (j in 1:dim(x)[2])
+ {
+ y[i,j] <- as.numeric(x[i,j])
+ }
+ }
> par3 = 'No Linear Trend'
> par2 = 'Do not include Seasonal Dummies'
> par1 = '8'
> #'GNU S' R Code compiled by R2WASP v. 1.0.44 ()
> #Author: Prof. Dr. P. Wessa
> #To cite this work: AUTHOR(S), (YEAR), YOUR SOFTWARE TITLE (vNUMBER) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_YOURPAGE.wasp/
> #Source of accompanying publication: Office for Research, Development, and Education
> #Technical description: Write here your technical program description (don't use hard returns!)
> library(lattice)
> library(lmtest)
Loading required package: zoo
Attaching package: 'zoo'
The following object(s) are masked from package:base :
as.Date.numeric
> n25 <- 25 #minimum number of obs. for Goldfeld-Quandt test
> par1 <- as.numeric(par1)
> x <- t(y)
> k <- length(x[1,])
> n <- length(x[,1])
> x1 <- cbind(x[,par1], x[,1:k!=par1])
> mycolnames <- c(colnames(x)[par1], colnames(x)[1:k!=par1])
> colnames(x1) <- mycolnames #colnames(x)[par1]
> x <- x1
> if (par3 == 'First Differences'){
+ x2 <- array(0, dim=c(n-1,k), dimnames=list(1:(n-1), paste('(1-B)',colnames(x),sep='')))
+ for (i in 1:n-1) {
+ for (j in 1:k) {
+ x2[i,j] <- x[i+1,j] - x[i,j]
+ }
+ }
+ x <- x2
+ }
> if (par2 == 'Include Monthly Dummies'){
+ x2 <- array(0, dim=c(n,11), dimnames=list(1:n, paste('M', seq(1:11), sep ='')))
+ for (i in 1:11){
+ x2[seq(i,n,12),i] <- 1
+ }
+ x <- cbind(x, x2)
+ }
> if (par2 == 'Include Quarterly Dummies'){
+ x2 <- array(0, dim=c(n,3), dimnames=list(1:n, paste('Q', seq(1:3), sep ='')))
+ for (i in 1:3){
+ x2[seq(i,n,4),i] <- 1
+ }
+ x <- cbind(x, x2)
+ }
> k <- length(x[1,])
> if (par3 == 'Linear Trend'){
+ x <- cbind(x, c(1:n))
+ colnames(x)[k+1] <- 't'
+ }
> x
pe_b Br org cm cm_b d d_b pe pc pc_b ps ps_b
1 11 1 26 24 24 14 14 11 12 12 24 24
2 7 1 23 25 25 11 11 7 8 8 25 25
3 0 0 25 17 0 6 0 17 8 0 30 0
4 10 1 23 18 18 12 12 10 8 8 19 19
5 12 1 19 18 18 8 8 12 9 9 22 22
6 0 0 29 16 0 10 0 12 7 0 22 0
7 11 1 25 20 20 10 10 11 4 4 25 25
8 11 1 21 16 16 11 11 11 11 11 23 23
9 12 1 22 18 18 16 16 12 7 7 17 17
10 13 1 25 17 17 11 11 13 7 7 21 21
11 14 1 24 23 23 13 13 14 12 12 19 19
12 16 1 18 30 30 12 12 16 10 10 19 19
13 11 1 22 23 23 8 8 11 10 10 15 15
14 10 1 15 18 18 12 12 10 8 8 16 16
15 11 1 22 15 15 11 11 11 8 8 23 23
16 15 1 28 12 12 4 4 15 4 4 27 27
17 9 1 20 21 21 9 9 9 9 9 22 22
18 11 1 12 15 15 8 8 11 8 8 14 14
19 17 1 24 20 20 8 8 17 7 7 22 22
20 17 1 20 31 31 14 14 17 11 11 23 23
21 11 1 21 27 27 15 15 11 9 9 23 23
22 18 1 20 34 34 16 16 18 11 11 21 21
23 14 1 21 21 21 9 9 14 13 13 19 19
24 10 1 23 31 31 14 14 10 8 8 18 18
25 11 1 28 19 19 11 11 11 8 8 20 20
26 15 1 24 16 16 8 8 15 9 9 23 23
27 15 1 24 20 20 9 9 15 6 6 25 25
28 13 1 24 21 21 9 9 13 9 9 19 19
29 16 1 23 22 22 9 9 16 9 9 24 24
30 13 1 23 17 17 9 9 13 6 6 22 22
31 9 1 29 24 24 10 10 9 6 6 25 25
32 18 1 24 25 25 16 16 18 16 16 26 26
33 18 1 18 26 26 11 11 18 5 5 29 29
34 12 1 25 25 25 8 8 12 7 7 32 32
35 17 1 21 17 17 9 9 17 9 9 25 25
36 9 1 26 32 32 16 16 9 6 6 29 29
37 9 1 22 33 33 11 11 9 6 6 28 28
38 12 1 22 13 13 16 16 12 5 5 17 17
39 0 0 22 32 0 12 0 18 12 0 28 0
40 12 1 23 25 25 12 12 12 7 7 29 29
41 18 1 30 29 29 14 14 18 10 10 26 26
42 14 1 23 22 22 9 9 14 9 9 25 25
43 15 1 17 18 18 10 10 15 8 8 14 14
44 16 1 23 17 17 9 9 16 5 5 25 25
45 10 1 23 20 20 10 10 10 8 8 26 26
46 11 1 25 15 15 12 12 11 8 8 20 20
47 14 1 24 20 20 14 14 14 10 10 18 18
48 9 1 24 33 33 14 14 9 6 6 32 32
49 12 1 23 29 29 10 10 12 8 8 25 25
50 17 1 21 23 23 14 14 17 7 7 25 25
51 5 1 24 26 26 16 16 5 4 4 23 23
52 12 1 24 18 18 9 9 12 8 8 21 21
53 12 1 28 20 20 10 10 12 8 8 20 20
54 6 1 16 11 11 6 6 6 4 4 15 15
55 24 1 20 28 28 8 8 24 20 20 30 30
56 12 1 29 26 26 13 13 12 8 8 24 24
57 12 1 27 22 22 10 10 12 8 8 26 26
58 14 1 22 17 17 8 8 14 6 6 24 24
59 7 1 28 12 12 7 7 7 4 4 22 22
60 13 1 16 14 14 15 15 13 8 8 14 14
61 12 1 25 17 17 9 9 12 9 9 24 24
62 13 1 24 21 21 10 10 13 6 6 24 24
63 0 0 28 19 0 12 0 14 7 0 24 0
64 8 1 24 18 18 13 13 8 9 9 24 24
65 11 1 23 10 10 10 10 11 5 5 19 19
66 9 1 30 29 29 11 11 9 5 5 31 31
67 11 1 24 31 31 8 8 11 8 8 22 22
68 13 1 21 19 19 9 9 13 8 8 27 27
69 10 1 25 9 9 13 13 10 6 6 19 19
70 0 0 25 20 0 11 0 11 8 0 25 0
71 12 1 22 28 28 8 8 12 7 7 20 20
72 9 1 23 19 19 9 9 9 7 7 21 21
73 15 1 26 30 30 9 9 15 9 9 27 27
74 18 1 23 29 29 15 15 18 11 11 23 23
75 15 1 25 26 26 9 9 15 6 6 25 25
76 12 1 21 23 23 10 10 12 8 8 20 20
77 13 1 25 13 13 14 14 13 6 6 21 21
78 14 1 24 21 21 12 12 14 9 9 22 22
79 10 1 29 19 19 12 12 10 8 8 23 23
80 13 1 22 28 28 11 11 13 6 6 25 25
81 13 1 27 23 23 14 14 13 10 10 25 25
82 0 0 26 18 0 6 0 11 8 0 17 0
83 13 1 22 21 21 12 12 13 8 8 19 19
84 16 1 24 20 20 8 8 16 10 10 25 25
85 0 0 27 23 0 14 0 8 5 0 19 0
86 16 1 24 21 21 11 11 16 7 7 20 20
87 11 1 24 21 21 10 10 11 5 5 26 26
88 9 1 29 15 15 14 14 9 8 8 23 23
89 16 1 22 28 28 12 12 16 14 14 27 27
90 0 0 21 19 0 10 0 12 7 0 17 0
91 14 1 24 26 26 14 14 14 8 8 17 17
92 8 1 24 10 10 5 5 8 6 6 19 19
93 0 0 23 16 0 11 0 9 5 0 17 0
94 15 1 20 22 22 10 10 15 6 6 22 22
95 11 1 27 19 19 9 9 11 10 10 21 21
96 21 1 26 31 31 10 10 21 12 12 32 32
97 14 1 25 31 31 16 16 14 9 9 21 21
98 18 1 21 29 29 13 13 18 12 12 21 21
99 12 1 21 19 19 9 9 12 7 7 18 18
100 13 1 19 22 22 10 10 13 8 8 18 18
101 15 1 21 23 23 10 10 15 10 10 23 23
102 12 1 21 15 15 7 7 12 6 6 19 19
103 19 1 16 20 20 9 9 19 10 10 20 20
104 15 1 22 18 18 8 8 15 10 10 21 21
105 11 1 29 23 23 14 14 11 10 10 20 20
106 0 0 15 25 0 14 0 11 5 0 17 0
107 10 1 17 21 21 8 8 10 7 7 18 18
108 13 1 15 24 24 9 9 13 10 10 19 19
109 15 1 21 25 25 14 14 15 11 11 22 22
110 0 0 21 17 0 14 0 12 6 0 15 0
111 12 1 19 13 13 8 8 12 7 7 14 14
112 16 1 24 28 28 8 8 16 12 12 18 18
113 9 1 20 21 21 8 8 9 11 11 24 24
114 0 0 17 25 0 7 0 18 11 0 35 0
115 8 1 23 9 9 6 6 8 11 11 29 29
116 13 1 24 16 16 8 8 13 5 5 21 21
117 17 1 14 19 19 6 6 17 8 8 25 25
118 9 1 19 17 17 11 11 9 6 6 20 20
119 15 1 24 25 25 14 14 15 9 9 22 22
120 8 1 13 20 20 11 11 8 4 4 13 13
121 7 1 22 29 29 11 11 7 4 4 26 26
122 12 1 16 14 14 11 11 12 7 7 17 17
123 0 0 19 22 0 14 0 14 11 0 25 0
124 6 1 25 15 15 8 8 6 6 6 20 20
125 8 1 25 19 19 20 20 8 7 7 19 19
126 17 1 23 20 20 11 11 17 8 8 21 21
127 0 0 24 15 0 8 0 10 4 0 22 0
128 11 1 26 20 20 11 11 11 8 8 24 24
129 14 1 26 18 18 10 10 14 9 9 21 21
130 11 1 25 33 33 14 14 11 8 8 26 26
131 13 1 18 22 22 11 11 13 11 11 24 24
132 12 1 21 16 16 9 9 12 8 8 16 16
133 11 1 26 17 17 9 9 11 5 5 23 23
134 9 1 23 16 16 8 8 9 4 4 18 18
135 12 1 23 21 21 10 10 12 8 8 16 16
136 20 1 22 26 26 13 13 20 10 10 26 26
137 12 1 20 18 18 13 13 12 6 6 19 19
138 13 1 13 18 18 12 12 13 9 9 21 21
139 12 1 24 17 17 8 8 12 9 9 21 21
140 12 1 15 22 22 13 13 12 13 13 22 22
141 9 1 14 30 30 14 14 9 9 9 23 23
142 0 0 22 30 0 12 0 15 10 0 29 0
143 24 1 10 24 24 14 14 24 20 20 21 21
144 7 1 24 21 21 15 15 7 5 5 21 21
145 17 1 22 21 21 13 13 17 11 11 23 23
146 11 1 24 29 29 16 16 11 6 6 27 27
147 17 1 19 31 31 9 9 17 9 9 25 25
148 0 0 20 20 0 9 0 11 7 0 21 0
149 12 1 13 16 16 9 9 12 9 9 10 10
150 14 1 20 22 22 8 8 14 10 10 20 20
151 11 1 22 20 20 7 7 11 9 9 26 26
152 16 1 24 28 28 16 16 16 8 8 24 24
153 21 1 29 38 38 11 11 21 7 7 29 29
154 14 1 12 22 22 9 9 14 6 6 19 19
155 20 1 20 20 20 11 11 20 13 13 24 24
156 13 1 21 17 17 9 9 13 6 6 19 19
157 11 1 24 28 28 14 14 11 8 8 24 24
158 15 1 22 22 22 13 13 15 10 10 22 22
159 19 1 20 31 31 16 16 19 16 16 17 17
> k <- length(x[1,])
> df <- as.data.frame(x)
> (mylm <- lm(df))
Call:
lm(formula = df)
Coefficients:
(Intercept) Br org cm cm_b d
-3.3167593 3.3594341 0.0069329 -0.0005313 0.0039672 0.0574141
d_b pe pc pc_b ps ps_b
-0.0630115 0.9731898 -0.6235298 0.6443095 -0.2235503 0.2218383
> (mysum <- summary(mylm))
Call:
lm(formula = df)
Residuals:
Min 1Q Median 3Q Max
-2.2074394 -0.0630672 -0.0005717 0.0632834 2.3944182
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) -3.3167593 0.8480949 -3.911 0.000140 ***
Br 3.3594341 0.8492458 3.956 0.000118 ***
org 0.0069329 0.0107003 0.648 0.518052
cm -0.0005313 0.0370547 -0.014 0.988580
cm_b 0.0039672 0.0379308 0.105 0.916844
d 0.0574141 0.0546433 1.051 0.295117
d_b -0.0630115 0.0567194 -1.111 0.268411
pe 0.9731898 0.0136247 71.428 < 2e-16 ***
pc -0.6235298 0.0820191 -7.602 3.17e-12 ***
pc_b 0.6443095 0.0828865 7.773 1.22e-12 ***
ps -0.2235503 0.0329318 -6.788 2.60e-10 ***
ps_b 0.2218383 0.0346683 6.399 1.97e-09 ***
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 0.4528 on 147 degrees of freedom
Multiple R-squared: 0.9927, Adjusted R-squared: 0.9921
F-statistic: 1814 on 11 and 147 DF, p-value: < 2.2e-16
> if (n > n25) {
+ kp3 <- k + 3
+ nmkm3 <- n - k - 3
+ gqarr <- array(NA, dim=c(nmkm3-kp3+1,3))
+ numgqtests <- 0
+ numsignificant1 <- 0
+ numsignificant5 <- 0
+ numsignificant10 <- 0
+ for (mypoint in kp3:nmkm3) {
+ j <- 0
+ numgqtests <- numgqtests + 1
+ for (myalt in c('greater', 'two.sided', 'less')) {
+ j <- j + 1
+ gqarr[mypoint-kp3+1,j] <- gqtest(mylm, point=mypoint, alternative=myalt)$p.value
+ }
+ if (gqarr[mypoint-kp3+1,2] < 0.01) numsignificant1 <- numsignificant1 + 1
+ if (gqarr[mypoint-kp3+1,2] < 0.05) numsignificant5 <- numsignificant5 + 1
+ if (gqarr[mypoint-kp3+1,2] < 0.10) numsignificant10 <- numsignificant10 + 1
+ }
+ gqarr
+ }
[,1] [,2] [,3]
[1,] 7.123521e-40 1.424704e-39 1.000000e+00
[2,] 8.629833e-54 1.725967e-53 1.000000e+00
[3,] 4.366996e-68 8.733992e-68 1.000000e+00
[4,] 6.180059e-82 1.236012e-81 1.000000e+00
[5,] 7.807984e-93 1.561597e-92 1.000000e+00
[6,] 1.205510e-107 2.411021e-107 1.000000e+00
[7,] 3.779574e-125 7.559148e-125 1.000000e+00
[8,] 2.221255e-132 4.442509e-132 1.000000e+00
[9,] 6.509213e-151 1.301843e-150 1.000000e+00
[10,] 3.351714e-157 6.703428e-157 1.000000e+00
[11,] 3.955113e-173 7.910226e-173 1.000000e+00
[12,] 3.006499e-187 6.012999e-187 1.000000e+00
[13,] 1.110922e-204 2.221844e-204 1.000000e+00
[14,] 5.334798e-218 1.066960e-217 1.000000e+00
[15,] 7.610072e-231 1.522014e-230 1.000000e+00
[16,] 4.351964e-240 8.703928e-240 1.000000e+00
[17,] 3.120097e-257 6.240194e-257 1.000000e+00
[18,] 9.868456e-261 1.973691e-260 1.000000e+00
[19,] 7.556697e-275 1.511339e-274 1.000000e+00
[20,] 5.162325e-292 1.032465e-291 1.000000e+00
[21,] 1.608245e-309 3.216491e-309 1.000000e+00
[22,] 1.877449e-322 3.754899e-322 1.000000e+00
[23,] 0.000000e+00 0.000000e+00 1.000000e+00
[24,] 0.000000e+00 0.000000e+00 1.000000e+00
[25,] 0.000000e+00 0.000000e+00 1.000000e+00
[26,] 0.000000e+00 0.000000e+00 1.000000e+00
[27,] 0.000000e+00 0.000000e+00 1.000000e+00
[28,] 0.000000e+00 0.000000e+00 1.000000e+00
[29,] 0.000000e+00 0.000000e+00 1.000000e+00
[30,] 0.000000e+00 0.000000e+00 1.000000e+00
[31,] 0.000000e+00 0.000000e+00 1.000000e+00
[32,] 0.000000e+00 0.000000e+00 1.000000e+00
[33,] 0.000000e+00 0.000000e+00 1.000000e+00
[34,] 0.000000e+00 0.000000e+00 1.000000e+00
[35,] 0.000000e+00 0.000000e+00 1.000000e+00
[36,] 0.000000e+00 0.000000e+00 1.000000e+00
[37,] 0.000000e+00 0.000000e+00 1.000000e+00
[38,] 0.000000e+00 0.000000e+00 1.000000e+00
[39,] 0.000000e+00 0.000000e+00 1.000000e+00
[40,] 0.000000e+00 0.000000e+00 1.000000e+00
[41,] 0.000000e+00 0.000000e+00 1.000000e+00
[42,] 0.000000e+00 0.000000e+00 1.000000e+00
[43,] 0.000000e+00 0.000000e+00 1.000000e+00
[44,] 0.000000e+00 0.000000e+00 1.000000e+00
[45,] 0.000000e+00 0.000000e+00 1.000000e+00
[46,] 0.000000e+00 0.000000e+00 1.000000e+00
[47,] 0.000000e+00 0.000000e+00 1.000000e+00
[48,] 0.000000e+00 0.000000e+00 1.000000e+00
[49,] 0.000000e+00 0.000000e+00 1.000000e+00
[50,] 0.000000e+00 0.000000e+00 1.000000e+00
[51,] 0.000000e+00 0.000000e+00 1.000000e+00
[52,] 0.000000e+00 0.000000e+00 1.000000e+00
[53,] 0.000000e+00 0.000000e+00 1.000000e+00
[54,] 0.000000e+00 0.000000e+00 1.000000e+00
[55,] 0.000000e+00 0.000000e+00 1.000000e+00
[56,] 0.000000e+00 0.000000e+00 1.000000e+00
[57,] 0.000000e+00 0.000000e+00 1.000000e+00
[58,] 0.000000e+00 0.000000e+00 1.000000e+00
[59,] 0.000000e+00 0.000000e+00 1.000000e+00
[60,] 0.000000e+00 0.000000e+00 1.000000e+00
[61,] 0.000000e+00 0.000000e+00 1.000000e+00
[62,] 0.000000e+00 0.000000e+00 1.000000e+00
[63,] 0.000000e+00 0.000000e+00 1.000000e+00
[64,] 0.000000e+00 0.000000e+00 1.000000e+00
[65,] 0.000000e+00 0.000000e+00 1.000000e+00
[66,] 0.000000e+00 0.000000e+00 1.000000e+00
[67,] 0.000000e+00 0.000000e+00 1.000000e+00
[68,] 1.789703e-02 3.579406e-02 9.821030e-01
[69,] 1.314534e-02 2.629068e-02 9.868547e-01
[70,] 9.533224e-03 1.906645e-02 9.904668e-01
[71,] 5.405595e-01 9.188810e-01 4.594405e-01
[72,] 4.938892e-01 9.877783e-01 5.061108e-01
[73,] 4.450177e-01 8.900355e-01 5.549823e-01
[74,] 3.975929e-01 7.951858e-01 6.024071e-01
[75,] 3.514582e-01 7.029164e-01 6.485418e-01
[76,] 9.055046e-01 1.889907e-01 9.449537e-02
[77,] 8.827369e-01 2.345262e-01 1.172631e-01
[78,] 8.570519e-01 2.858963e-01 1.429481e-01
[79,] 9.411370e-01 1.177259e-01 5.886296e-02
[80,] 9.253981e-01 1.492039e-01 7.460193e-02
[81,] 9.070348e-01 1.859304e-01 9.296518e-02
[82,] 8.844367e-01 2.311266e-01 1.155633e-01
[83,] 8.576286e-01 2.847429e-01 1.423714e-01
[84,] 8.269004e-01 3.461992e-01 1.730996e-01
[85,] 7.918346e-01 4.163308e-01 2.081654e-01
[86,] 7.527839e-01 4.944321e-01 2.472161e-01
[87,] 7.099654e-01 5.800692e-01 2.900346e-01
[88,] 6.638185e-01 6.723631e-01 3.361815e-01
[89,] 6.188346e-01 7.623309e-01 3.811654e-01
[90,] 5.677848e-01 8.644303e-01 4.322152e-01
[91,] 5.199013e-01 9.601973e-01 4.800987e-01
[92,] 8.004972e-01 3.990056e-01 1.995028e-01
[93,] 7.604649e-01 4.790703e-01 2.395351e-01
[94,] 7.163403e-01 5.673193e-01 2.836597e-01
[95,] 6.682234e-01 6.635532e-01 3.317766e-01
[96,] 1.000000e+00 0.000000e+00 0.000000e+00
[97,] 1.000000e+00 0.000000e+00 0.000000e+00
[98,] 1.000000e+00 0.000000e+00 0.000000e+00
[99,] 1.000000e+00 0.000000e+00 0.000000e+00
[100,] 1.000000e+00 0.000000e+00 0.000000e+00
[101,] 1.000000e+00 0.000000e+00 0.000000e+00
[102,] 1.000000e+00 0.000000e+00 0.000000e+00
[103,] 1.000000e+00 0.000000e+00 0.000000e+00
[104,] 1.000000e+00 0.000000e+00 0.000000e+00
[105,] 1.000000e+00 0.000000e+00 0.000000e+00
[106,] 1.000000e+00 0.000000e+00 0.000000e+00
[107,] 1.000000e+00 0.000000e+00 0.000000e+00
[108,] 1.000000e+00 0.000000e+00 0.000000e+00
[109,] 1.000000e+00 0.000000e+00 0.000000e+00
[110,] 1.000000e+00 0.000000e+00 0.000000e+00
[111,] 1.000000e+00 4.332215e-306 2.166108e-306
[112,] 1.000000e+00 4.986502e-299 2.493251e-299
[113,] 1.000000e+00 4.171893e-283 2.085946e-283
[114,] 1.000000e+00 2.770155e-268 1.385078e-268
[115,] 1.000000e+00 5.951989e-258 2.975994e-258
[116,] 1.000000e+00 1.684130e-240 8.420650e-241
[117,] 1.000000e+00 7.935752e-230 3.967876e-230
[118,] 1.000000e+00 6.436537e-218 3.218268e-218
[119,] 1.000000e+00 6.771765e-202 3.385883e-202
[120,] 1.000000e+00 1.395276e-188 6.976381e-189
[121,] 1.000000e+00 1.591566e-174 7.957829e-175
[122,] 1.000000e+00 2.554934e-159 1.277467e-159
[123,] 1.000000e+00 1.289007e-145 6.445037e-146
[124,] 1.000000e+00 8.307217e-131 4.153609e-131
[125,] 1.000000e+00 1.261204e-116 6.306022e-117
[126,] 1.000000e+00 1.537897e-100 7.689483e-101
[127,] 1.000000e+00 3.627097e-87 1.813549e-87
[128,] 1.000000e+00 4.790026e-71 2.395013e-71
[129,] 1.000000e+00 1.482580e-56 7.412902e-57
[130,] 1.000000e+00 9.650704e-44 4.825352e-44
> postscript(file="/var/www/html/freestat/rcomp/tmp/1sra21290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> plot(x[,1], type='l', main='Actuals and Interpolation', ylab='value of Actuals and Interpolation (dots)', xlab='time or index')
> points(x[,1]-mysum$resid)
> grid()
> dev.off()
null device
1
> postscript(file="/var/www/html/freestat/rcomp/tmp/2l0rn1290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> plot(mysum$resid, type='b', pch=19, main='Residuals', ylab='value of Residuals', xlab='time or index')
> grid()
> dev.off()
null device
1
> postscript(file="/var/www/html/freestat/rcomp/tmp/3l0rn1290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> hist(mysum$resid, main='Residual Histogram', xlab='values of Residuals')
> grid()
> dev.off()
null device
1
> postscript(file="/var/www/html/freestat/rcomp/tmp/4l0rn1290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> densityplot(~mysum$resid,col='black',main='Residual Density Plot', xlab='values of Residuals')
> dev.off()
null device
1
> postscript(file="/var/www/html/freestat/rcomp/tmp/5v9881290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> qqnorm(mysum$resid, main='Residual Normal Q-Q Plot')
> qqline(mysum$resid)
> grid()
> dev.off()
null device
1
> (myerror <- as.ts(mysum$resid))
Time Series:
Start = 1
End = 159
Frequency = 1
1 2 3 4 5
-0.1403814195 -0.1622209406 -2.0414925597 -0.0624141218 -0.0190955022
6 7 8 9 10
0.1546049602 0.0258547289 -0.0759546877 0.0378843210 0.0261929305
11 12 13 14 15
-0.0568069474 0.0503213267 -0.1166476887 -0.0120873910 -0.0171126533
16 17 18 19 20
0.1096235292 -0.1111691269 0.0200152563 0.1149786664 0.0570932597
21 22 23 24 25
-0.0498003866 0.0813665211 -0.0723059308 -0.0975978036 -0.0775894898
26 27 28 29 30
0.0352545444 0.0928715452 -0.0367960051 0.0556917573 0.0513555438
31 32 33 34 35
-0.1107999356 -0.0107800909 0.2331066494 -0.0260639917 0.1152591130
36 37 38 39 40
-0.0770557240 -0.0824592847 0.0966230705 -1.2833800972 0.0050552343
41 42 43 44 45
0.0473624207 0.0037834512 0.0934788512 0.1577018988 -0.0684963630
46 47 48 49 50
-0.0374499695 -0.0010545970 -0.0726845633 -0.0475109904 0.1641902355
51 52 53 54 55
-0.1185283846 -0.0290947677 -0.0598126072 -0.0543876421 0.0464549777
56 57 58 59 60
-0.0637203147 -0.0494792103 0.0829252680 -0.0966259031 0.0885219508
61 62 63 64 65
-0.0482352674 0.0397006716 -1.4509754002 -0.1295893452 0.0430272934
66 67 68 69 70
-0.0982628185 -0.1044567693 0.0253504089 0.0017998474 2.3944181992
71 72 73 74 75
-0.0361176555 -0.0852486522 -0.0142679031 0.0755740344 0.0653233960
76 77 78 79 80
-0.0215902310 0.0775083693 0.0119425645 -0.1005989641 0.0368246851
81 82 83 84 85
-0.0469866501 0.8850903828 0.0146416278 0.0309656253 1.9175820350
86 87 88 89 90
0.0981007487 0.0102840864 -0.1024707882 -0.0399606349 -0.9060899753
91 92 93 94 95
0.0181774060 -0.0931028413 0.6935461208 0.1141924865 -0.1216987495
96 97 98 99 100
0.0949759342 -0.0086715050 0.0540411558 0.0039114522 0.0190974488
101 102 103 104 105
0.0224171109 0.0289518713 0.1638962042 0.0180447306 -0.1230329761
106 107 108 109 110
-1.3648312002 -0.0344466404 -0.0054875798 0.0154432826 -2.2074393780
111 112 113 114 115
0.0259468476 -0.0500651185 -0.1549017829 -0.0240419701 -0.1639145411
116 117 118 119 120
0.0613287724 0.1609047999 -0.0203830000 0.0362040443 0.0136713303
121 122 123 124 125
-0.0842008726 0.0652379380 1.2158558095 -0.1523311733 -0.0677770973
126 127 128 129 130
0.1162120473 0.3793562128 -0.0603114512 -0.0045223889 -0.0778287091
131 132 133 134 135
-0.0204389904 -0.0099846742 -0.0005716715 -0.0233355585 -0.0354323880
136 137 138 139 140
0.1611558881 0.0591615704 0.0699894421 -0.0520359711 -0.0602392022
141 142 143 144 145
-0.0707957804 0.6116174259 0.1477031385 -0.0775298059 0.0719889407
146 147 148 149 150
-0.0026861032 0.0810224921 1.0261794346 0.0144262358 -0.0103553032
151 152 153 154 155
-0.0723252376 0.0881051766 0.1544858024 0.1321116255 0.1186789566
156 157 158 159
0.0600851141 -0.0571405414 0.0340003241 0.0077377888
> postscript(file="/var/www/html/freestat/rcomp/tmp/6v9881290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> dum <- cbind(lag(myerror,k=1),myerror)
> dum
Time Series:
Start = 0
End = 159
Frequency = 1
lag(myerror, k = 1) myerror
0 -0.1403814195 NA
1 -0.1622209406 -0.1403814195
2 -2.0414925597 -0.1622209406
3 -0.0624141218 -2.0414925597
4 -0.0190955022 -0.0624141218
5 0.1546049602 -0.0190955022
6 0.0258547289 0.1546049602
7 -0.0759546877 0.0258547289
8 0.0378843210 -0.0759546877
9 0.0261929305 0.0378843210
10 -0.0568069474 0.0261929305
11 0.0503213267 -0.0568069474
12 -0.1166476887 0.0503213267
13 -0.0120873910 -0.1166476887
14 -0.0171126533 -0.0120873910
15 0.1096235292 -0.0171126533
16 -0.1111691269 0.1096235292
17 0.0200152563 -0.1111691269
18 0.1149786664 0.0200152563
19 0.0570932597 0.1149786664
20 -0.0498003866 0.0570932597
21 0.0813665211 -0.0498003866
22 -0.0723059308 0.0813665211
23 -0.0975978036 -0.0723059308
24 -0.0775894898 -0.0975978036
25 0.0352545444 -0.0775894898
26 0.0928715452 0.0352545444
27 -0.0367960051 0.0928715452
28 0.0556917573 -0.0367960051
29 0.0513555438 0.0556917573
30 -0.1107999356 0.0513555438
31 -0.0107800909 -0.1107999356
32 0.2331066494 -0.0107800909
33 -0.0260639917 0.2331066494
34 0.1152591130 -0.0260639917
35 -0.0770557240 0.1152591130
36 -0.0824592847 -0.0770557240
37 0.0966230705 -0.0824592847
38 -1.2833800972 0.0966230705
39 0.0050552343 -1.2833800972
40 0.0473624207 0.0050552343
41 0.0037834512 0.0473624207
42 0.0934788512 0.0037834512
43 0.1577018988 0.0934788512
44 -0.0684963630 0.1577018988
45 -0.0374499695 -0.0684963630
46 -0.0010545970 -0.0374499695
47 -0.0726845633 -0.0010545970
48 -0.0475109904 -0.0726845633
49 0.1641902355 -0.0475109904
50 -0.1185283846 0.1641902355
51 -0.0290947677 -0.1185283846
52 -0.0598126072 -0.0290947677
53 -0.0543876421 -0.0598126072
54 0.0464549777 -0.0543876421
55 -0.0637203147 0.0464549777
56 -0.0494792103 -0.0637203147
57 0.0829252680 -0.0494792103
58 -0.0966259031 0.0829252680
59 0.0885219508 -0.0966259031
60 -0.0482352674 0.0885219508
61 0.0397006716 -0.0482352674
62 -1.4509754002 0.0397006716
63 -0.1295893452 -1.4509754002
64 0.0430272934 -0.1295893452
65 -0.0982628185 0.0430272934
66 -0.1044567693 -0.0982628185
67 0.0253504089 -0.1044567693
68 0.0017998474 0.0253504089
69 2.3944181992 0.0017998474
70 -0.0361176555 2.3944181992
71 -0.0852486522 -0.0361176555
72 -0.0142679031 -0.0852486522
73 0.0755740344 -0.0142679031
74 0.0653233960 0.0755740344
75 -0.0215902310 0.0653233960
76 0.0775083693 -0.0215902310
77 0.0119425645 0.0775083693
78 -0.1005989641 0.0119425645
79 0.0368246851 -0.1005989641
80 -0.0469866501 0.0368246851
81 0.8850903828 -0.0469866501
82 0.0146416278 0.8850903828
83 0.0309656253 0.0146416278
84 1.9175820350 0.0309656253
85 0.0981007487 1.9175820350
86 0.0102840864 0.0981007487
87 -0.1024707882 0.0102840864
88 -0.0399606349 -0.1024707882
89 -0.9060899753 -0.0399606349
90 0.0181774060 -0.9060899753
91 -0.0931028413 0.0181774060
92 0.6935461208 -0.0931028413
93 0.1141924865 0.6935461208
94 -0.1216987495 0.1141924865
95 0.0949759342 -0.1216987495
96 -0.0086715050 0.0949759342
97 0.0540411558 -0.0086715050
98 0.0039114522 0.0540411558
99 0.0190974488 0.0039114522
100 0.0224171109 0.0190974488
101 0.0289518713 0.0224171109
102 0.1638962042 0.0289518713
103 0.0180447306 0.1638962042
104 -0.1230329761 0.0180447306
105 -1.3648312002 -0.1230329761
106 -0.0344466404 -1.3648312002
107 -0.0054875798 -0.0344466404
108 0.0154432826 -0.0054875798
109 -2.2074393780 0.0154432826
110 0.0259468476 -2.2074393780
111 -0.0500651185 0.0259468476
112 -0.1549017829 -0.0500651185
113 -0.0240419701 -0.1549017829
114 -0.1639145411 -0.0240419701
115 0.0613287724 -0.1639145411
116 0.1609047999 0.0613287724
117 -0.0203830000 0.1609047999
118 0.0362040443 -0.0203830000
119 0.0136713303 0.0362040443
120 -0.0842008726 0.0136713303
121 0.0652379380 -0.0842008726
122 1.2158558095 0.0652379380
123 -0.1523311733 1.2158558095
124 -0.0677770973 -0.1523311733
125 0.1162120473 -0.0677770973
126 0.3793562128 0.1162120473
127 -0.0603114512 0.3793562128
128 -0.0045223889 -0.0603114512
129 -0.0778287091 -0.0045223889
130 -0.0204389904 -0.0778287091
131 -0.0099846742 -0.0204389904
132 -0.0005716715 -0.0099846742
133 -0.0233355585 -0.0005716715
134 -0.0354323880 -0.0233355585
135 0.1611558881 -0.0354323880
136 0.0591615704 0.1611558881
137 0.0699894421 0.0591615704
138 -0.0520359711 0.0699894421
139 -0.0602392022 -0.0520359711
140 -0.0707957804 -0.0602392022
141 0.6116174259 -0.0707957804
142 0.1477031385 0.6116174259
143 -0.0775298059 0.1477031385
144 0.0719889407 -0.0775298059
145 -0.0026861032 0.0719889407
146 0.0810224921 -0.0026861032
147 1.0261794346 0.0810224921
148 0.0144262358 1.0261794346
149 -0.0103553032 0.0144262358
150 -0.0723252376 -0.0103553032
151 0.0881051766 -0.0723252376
152 0.1544858024 0.0881051766
153 0.1321116255 0.1544858024
154 0.1186789566 0.1321116255
155 0.0600851141 0.1186789566
156 -0.0571405414 0.0600851141
157 0.0340003241 -0.0571405414
158 0.0077377888 0.0340003241
159 NA 0.0077377888
> dum1 <- dum[2:length(myerror),]
> dum1
lag(myerror, k = 1) myerror
[1,] -0.1622209406 -0.1403814195
[2,] -2.0414925597 -0.1622209406
[3,] -0.0624141218 -2.0414925597
[4,] -0.0190955022 -0.0624141218
[5,] 0.1546049602 -0.0190955022
[6,] 0.0258547289 0.1546049602
[7,] -0.0759546877 0.0258547289
[8,] 0.0378843210 -0.0759546877
[9,] 0.0261929305 0.0378843210
[10,] -0.0568069474 0.0261929305
[11,] 0.0503213267 -0.0568069474
[12,] -0.1166476887 0.0503213267
[13,] -0.0120873910 -0.1166476887
[14,] -0.0171126533 -0.0120873910
[15,] 0.1096235292 -0.0171126533
[16,] -0.1111691269 0.1096235292
[17,] 0.0200152563 -0.1111691269
[18,] 0.1149786664 0.0200152563
[19,] 0.0570932597 0.1149786664
[20,] -0.0498003866 0.0570932597
[21,] 0.0813665211 -0.0498003866
[22,] -0.0723059308 0.0813665211
[23,] -0.0975978036 -0.0723059308
[24,] -0.0775894898 -0.0975978036
[25,] 0.0352545444 -0.0775894898
[26,] 0.0928715452 0.0352545444
[27,] -0.0367960051 0.0928715452
[28,] 0.0556917573 -0.0367960051
[29,] 0.0513555438 0.0556917573
[30,] -0.1107999356 0.0513555438
[31,] -0.0107800909 -0.1107999356
[32,] 0.2331066494 -0.0107800909
[33,] -0.0260639917 0.2331066494
[34,] 0.1152591130 -0.0260639917
[35,] -0.0770557240 0.1152591130
[36,] -0.0824592847 -0.0770557240
[37,] 0.0966230705 -0.0824592847
[38,] -1.2833800972 0.0966230705
[39,] 0.0050552343 -1.2833800972
[40,] 0.0473624207 0.0050552343
[41,] 0.0037834512 0.0473624207
[42,] 0.0934788512 0.0037834512
[43,] 0.1577018988 0.0934788512
[44,] -0.0684963630 0.1577018988
[45,] -0.0374499695 -0.0684963630
[46,] -0.0010545970 -0.0374499695
[47,] -0.0726845633 -0.0010545970
[48,] -0.0475109904 -0.0726845633
[49,] 0.1641902355 -0.0475109904
[50,] -0.1185283846 0.1641902355
[51,] -0.0290947677 -0.1185283846
[52,] -0.0598126072 -0.0290947677
[53,] -0.0543876421 -0.0598126072
[54,] 0.0464549777 -0.0543876421
[55,] -0.0637203147 0.0464549777
[56,] -0.0494792103 -0.0637203147
[57,] 0.0829252680 -0.0494792103
[58,] -0.0966259031 0.0829252680
[59,] 0.0885219508 -0.0966259031
[60,] -0.0482352674 0.0885219508
[61,] 0.0397006716 -0.0482352674
[62,] -1.4509754002 0.0397006716
[63,] -0.1295893452 -1.4509754002
[64,] 0.0430272934 -0.1295893452
[65,] -0.0982628185 0.0430272934
[66,] -0.1044567693 -0.0982628185
[67,] 0.0253504089 -0.1044567693
[68,] 0.0017998474 0.0253504089
[69,] 2.3944181992 0.0017998474
[70,] -0.0361176555 2.3944181992
[71,] -0.0852486522 -0.0361176555
[72,] -0.0142679031 -0.0852486522
[73,] 0.0755740344 -0.0142679031
[74,] 0.0653233960 0.0755740344
[75,] -0.0215902310 0.0653233960
[76,] 0.0775083693 -0.0215902310
[77,] 0.0119425645 0.0775083693
[78,] -0.1005989641 0.0119425645
[79,] 0.0368246851 -0.1005989641
[80,] -0.0469866501 0.0368246851
[81,] 0.8850903828 -0.0469866501
[82,] 0.0146416278 0.8850903828
[83,] 0.0309656253 0.0146416278
[84,] 1.9175820350 0.0309656253
[85,] 0.0981007487 1.9175820350
[86,] 0.0102840864 0.0981007487
[87,] -0.1024707882 0.0102840864
[88,] -0.0399606349 -0.1024707882
[89,] -0.9060899753 -0.0399606349
[90,] 0.0181774060 -0.9060899753
[91,] -0.0931028413 0.0181774060
[92,] 0.6935461208 -0.0931028413
[93,] 0.1141924865 0.6935461208
[94,] -0.1216987495 0.1141924865
[95,] 0.0949759342 -0.1216987495
[96,] -0.0086715050 0.0949759342
[97,] 0.0540411558 -0.0086715050
[98,] 0.0039114522 0.0540411558
[99,] 0.0190974488 0.0039114522
[100,] 0.0224171109 0.0190974488
[101,] 0.0289518713 0.0224171109
[102,] 0.1638962042 0.0289518713
[103,] 0.0180447306 0.1638962042
[104,] -0.1230329761 0.0180447306
[105,] -1.3648312002 -0.1230329761
[106,] -0.0344466404 -1.3648312002
[107,] -0.0054875798 -0.0344466404
[108,] 0.0154432826 -0.0054875798
[109,] -2.2074393780 0.0154432826
[110,] 0.0259468476 -2.2074393780
[111,] -0.0500651185 0.0259468476
[112,] -0.1549017829 -0.0500651185
[113,] -0.0240419701 -0.1549017829
[114,] -0.1639145411 -0.0240419701
[115,] 0.0613287724 -0.1639145411
[116,] 0.1609047999 0.0613287724
[117,] -0.0203830000 0.1609047999
[118,] 0.0362040443 -0.0203830000
[119,] 0.0136713303 0.0362040443
[120,] -0.0842008726 0.0136713303
[121,] 0.0652379380 -0.0842008726
[122,] 1.2158558095 0.0652379380
[123,] -0.1523311733 1.2158558095
[124,] -0.0677770973 -0.1523311733
[125,] 0.1162120473 -0.0677770973
[126,] 0.3793562128 0.1162120473
[127,] -0.0603114512 0.3793562128
[128,] -0.0045223889 -0.0603114512
[129,] -0.0778287091 -0.0045223889
[130,] -0.0204389904 -0.0778287091
[131,] -0.0099846742 -0.0204389904
[132,] -0.0005716715 -0.0099846742
[133,] -0.0233355585 -0.0005716715
[134,] -0.0354323880 -0.0233355585
[135,] 0.1611558881 -0.0354323880
[136,] 0.0591615704 0.1611558881
[137,] 0.0699894421 0.0591615704
[138,] -0.0520359711 0.0699894421
[139,] -0.0602392022 -0.0520359711
[140,] -0.0707957804 -0.0602392022
[141,] 0.6116174259 -0.0707957804
[142,] 0.1477031385 0.6116174259
[143,] -0.0775298059 0.1477031385
[144,] 0.0719889407 -0.0775298059
[145,] -0.0026861032 0.0719889407
[146,] 0.0810224921 -0.0026861032
[147,] 1.0261794346 0.0810224921
[148,] 0.0144262358 1.0261794346
[149,] -0.0103553032 0.0144262358
[150,] -0.0723252376 -0.0103553032
[151,] 0.0881051766 -0.0723252376
[152,] 0.1544858024 0.0881051766
[153,] 0.1321116255 0.1544858024
[154,] 0.1186789566 0.1321116255
[155,] 0.0600851141 0.1186789566
[156,] -0.0571405414 0.0600851141
[157,] 0.0340003241 -0.0571405414
[158,] 0.0077377888 0.0340003241
> z <- as.data.frame(dum1)
> z
lag(myerror, k = 1) myerror
1 -0.1622209406 -0.1403814195
2 -2.0414925597 -0.1622209406
3 -0.0624141218 -2.0414925597
4 -0.0190955022 -0.0624141218
5 0.1546049602 -0.0190955022
6 0.0258547289 0.1546049602
7 -0.0759546877 0.0258547289
8 0.0378843210 -0.0759546877
9 0.0261929305 0.0378843210
10 -0.0568069474 0.0261929305
11 0.0503213267 -0.0568069474
12 -0.1166476887 0.0503213267
13 -0.0120873910 -0.1166476887
14 -0.0171126533 -0.0120873910
15 0.1096235292 -0.0171126533
16 -0.1111691269 0.1096235292
17 0.0200152563 -0.1111691269
18 0.1149786664 0.0200152563
19 0.0570932597 0.1149786664
20 -0.0498003866 0.0570932597
21 0.0813665211 -0.0498003866
22 -0.0723059308 0.0813665211
23 -0.0975978036 -0.0723059308
24 -0.0775894898 -0.0975978036
25 0.0352545444 -0.0775894898
26 0.0928715452 0.0352545444
27 -0.0367960051 0.0928715452
28 0.0556917573 -0.0367960051
29 0.0513555438 0.0556917573
30 -0.1107999356 0.0513555438
31 -0.0107800909 -0.1107999356
32 0.2331066494 -0.0107800909
33 -0.0260639917 0.2331066494
34 0.1152591130 -0.0260639917
35 -0.0770557240 0.1152591130
36 -0.0824592847 -0.0770557240
37 0.0966230705 -0.0824592847
38 -1.2833800972 0.0966230705
39 0.0050552343 -1.2833800972
40 0.0473624207 0.0050552343
41 0.0037834512 0.0473624207
42 0.0934788512 0.0037834512
43 0.1577018988 0.0934788512
44 -0.0684963630 0.1577018988
45 -0.0374499695 -0.0684963630
46 -0.0010545970 -0.0374499695
47 -0.0726845633 -0.0010545970
48 -0.0475109904 -0.0726845633
49 0.1641902355 -0.0475109904
50 -0.1185283846 0.1641902355
51 -0.0290947677 -0.1185283846
52 -0.0598126072 -0.0290947677
53 -0.0543876421 -0.0598126072
54 0.0464549777 -0.0543876421
55 -0.0637203147 0.0464549777
56 -0.0494792103 -0.0637203147
57 0.0829252680 -0.0494792103
58 -0.0966259031 0.0829252680
59 0.0885219508 -0.0966259031
60 -0.0482352674 0.0885219508
61 0.0397006716 -0.0482352674
62 -1.4509754002 0.0397006716
63 -0.1295893452 -1.4509754002
64 0.0430272934 -0.1295893452
65 -0.0982628185 0.0430272934
66 -0.1044567693 -0.0982628185
67 0.0253504089 -0.1044567693
68 0.0017998474 0.0253504089
69 2.3944181992 0.0017998474
70 -0.0361176555 2.3944181992
71 -0.0852486522 -0.0361176555
72 -0.0142679031 -0.0852486522
73 0.0755740344 -0.0142679031
74 0.0653233960 0.0755740344
75 -0.0215902310 0.0653233960
76 0.0775083693 -0.0215902310
77 0.0119425645 0.0775083693
78 -0.1005989641 0.0119425645
79 0.0368246851 -0.1005989641
80 -0.0469866501 0.0368246851
81 0.8850903828 -0.0469866501
82 0.0146416278 0.8850903828
83 0.0309656253 0.0146416278
84 1.9175820350 0.0309656253
85 0.0981007487 1.9175820350
86 0.0102840864 0.0981007487
87 -0.1024707882 0.0102840864
88 -0.0399606349 -0.1024707882
89 -0.9060899753 -0.0399606349
90 0.0181774060 -0.9060899753
91 -0.0931028413 0.0181774060
92 0.6935461208 -0.0931028413
93 0.1141924865 0.6935461208
94 -0.1216987495 0.1141924865
95 0.0949759342 -0.1216987495
96 -0.0086715050 0.0949759342
97 0.0540411558 -0.0086715050
98 0.0039114522 0.0540411558
99 0.0190974488 0.0039114522
100 0.0224171109 0.0190974488
101 0.0289518713 0.0224171109
102 0.1638962042 0.0289518713
103 0.0180447306 0.1638962042
104 -0.1230329761 0.0180447306
105 -1.3648312002 -0.1230329761
106 -0.0344466404 -1.3648312002
107 -0.0054875798 -0.0344466404
108 0.0154432826 -0.0054875798
109 -2.2074393780 0.0154432826
110 0.0259468476 -2.2074393780
111 -0.0500651185 0.0259468476
112 -0.1549017829 -0.0500651185
113 -0.0240419701 -0.1549017829
114 -0.1639145411 -0.0240419701
115 0.0613287724 -0.1639145411
116 0.1609047999 0.0613287724
117 -0.0203830000 0.1609047999
118 0.0362040443 -0.0203830000
119 0.0136713303 0.0362040443
120 -0.0842008726 0.0136713303
121 0.0652379380 -0.0842008726
122 1.2158558095 0.0652379380
123 -0.1523311733 1.2158558095
124 -0.0677770973 -0.1523311733
125 0.1162120473 -0.0677770973
126 0.3793562128 0.1162120473
127 -0.0603114512 0.3793562128
128 -0.0045223889 -0.0603114512
129 -0.0778287091 -0.0045223889
130 -0.0204389904 -0.0778287091
131 -0.0099846742 -0.0204389904
132 -0.0005716715 -0.0099846742
133 -0.0233355585 -0.0005716715
134 -0.0354323880 -0.0233355585
135 0.1611558881 -0.0354323880
136 0.0591615704 0.1611558881
137 0.0699894421 0.0591615704
138 -0.0520359711 0.0699894421
139 -0.0602392022 -0.0520359711
140 -0.0707957804 -0.0602392022
141 0.6116174259 -0.0707957804
142 0.1477031385 0.6116174259
143 -0.0775298059 0.1477031385
144 0.0719889407 -0.0775298059
145 -0.0026861032 0.0719889407
146 0.0810224921 -0.0026861032
147 1.0261794346 0.0810224921
148 0.0144262358 1.0261794346
149 -0.0103553032 0.0144262358
150 -0.0723252376 -0.0103553032
151 0.0881051766 -0.0723252376
152 0.1544858024 0.0881051766
153 0.1321116255 0.1544858024
154 0.1186789566 0.1321116255
155 0.0600851141 0.1186789566
156 -0.0571405414 0.0600851141
157 0.0340003241 -0.0571405414
158 0.0077377888 0.0340003241
> plot(z,main=paste('Residual Lag plot, lowess, and regression line'), ylab='values of Residuals', xlab='lagged values of Residuals')
> lines(lowess(z))
> abline(lm(z))
> grid()
> dev.off()
null device
1
> postscript(file="/var/www/html/freestat/rcomp/tmp/7o08t1290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> acf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Autocorrelation Function')
> grid()
> dev.off()
null device
1
> postscript(file="/var/www/html/freestat/rcomp/tmp/8o08t1290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> pacf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Partial Autocorrelation Function')
> grid()
> dev.off()
null device
1
> postscript(file="/var/www/html/freestat/rcomp/tmp/9zapv1290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> opar <- par(mfrow = c(2,2), oma = c(0, 0, 1.1, 0))
> plot(mylm, las = 1, sub='Residual Diagnostics')
> par(opar)
> dev.off()
null device
1
> if (n > n25) {
+ postscript(file="/var/www/html/freestat/rcomp/tmp/10zapv1290179599.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
+ plot(kp3:nmkm3,gqarr[,2], main='Goldfeld-Quandt test',ylab='2-sided p-value',xlab='breakpoint')
+ grid()
+ dev.off()
+ }
null device
1
>
> #Note: the /var/www/html/freestat/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab
> load(file="/var/www/html/freestat/rcomp/createtable")
>
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Estimated Regression Equation', 1, TRUE)
> a<-table.row.end(a)
> myeq <- colnames(x)[1]
> myeq <- paste(myeq, '[t] = ', sep='')
> for (i in 1:k){
+ if (mysum$coefficients[i,1] > 0) myeq <- paste(myeq, '+', '')
+ myeq <- paste(myeq, mysum$coefficients[i,1], sep=' ')
+ if (rownames(mysum$coefficients)[i] != '(Intercept)') {
+ myeq <- paste(myeq, rownames(mysum$coefficients)[i], sep='')
+ if (rownames(mysum$coefficients)[i] != 't') myeq <- paste(myeq, '[t]', sep='')
+ }
+ }
> myeq <- paste(myeq, ' + e[t]')
> a<-table.row.start(a)
> a<-table.element(a, myeq)
> a<-table.row.end(a)
> a<-table.end(a)
> table.save(a,file="/var/www/html/freestat/rcomp/tmp/11i6fl1290179600.tab")
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a,hyperlink('http://www.xycoon.com/ols1.htm','Multiple Linear Regression - Ordinary Least Squares',''), 6, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a,'Variable',header=TRUE)
> a<-table.element(a,'Parameter',header=TRUE)
> a<-table.element(a,'S.D.',header=TRUE)
> a<-table.element(a,'T-STAT
H0: parameter = 0',header=TRUE)
> a<-table.element(a,'2-tail p-value',header=TRUE)
> a<-table.element(a,'1-tail p-value',header=TRUE)
> a<-table.row.end(a)
> for (i in 1:k){
+ a<-table.row.start(a)
+ a<-table.element(a,rownames(mysum$coefficients)[i],header=TRUE)
+ a<-table.element(a,mysum$coefficients[i,1])
+ a<-table.element(a, round(mysum$coefficients[i,2],6))
+ a<-table.element(a, round(mysum$coefficients[i,3],4))
+ a<-table.element(a, round(mysum$coefficients[i,4],6))
+ a<-table.element(a, round(mysum$coefficients[i,4]/2,6))
+ a<-table.row.end(a)
+ }
> a<-table.end(a)
> table.save(a,file="/var/www/html/freestat/rcomp/tmp/12g3pk1290179600.tab")
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Regression Statistics', 2, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple R',1,TRUE)
> a<-table.element(a, sqrt(mysum$r.squared))
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'R-squared',1,TRUE)
> a<-table.element(a, mysum$r.squared)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Adjusted R-squared',1,TRUE)
> a<-table.element(a, mysum$adj.r.squared)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'F-TEST (value)',1,TRUE)
> a<-table.element(a, mysum$fstatistic[1])
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'F-TEST (DF numerator)',1,TRUE)
> a<-table.element(a, mysum$fstatistic[2])
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'F-TEST (DF denominator)',1,TRUE)
> a<-table.element(a, mysum$fstatistic[3])
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'p-value',1,TRUE)
> a<-table.element(a, 1-pf(mysum$fstatistic[1],mysum$fstatistic[2],mysum$fstatistic[3]))
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Residual Statistics', 2, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Residual Standard Deviation',1,TRUE)
> a<-table.element(a, mysum$sigma)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Sum Squared Residuals',1,TRUE)
> a<-table.element(a, sum(myerror*myerror))
> a<-table.row.end(a)
> a<-table.end(a)
> table.save(a,file="/var/www/html/freestat/rcomp/tmp/13uc4b1290179600.tab")
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Actuals, Interpolation, and Residuals', 4, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Time or Index', 1, TRUE)
> a<-table.element(a, 'Actuals', 1, TRUE)
> a<-table.element(a, 'Interpolation
Forecast', 1, TRUE)
> a<-table.element(a, 'Residuals
Prediction Error', 1, TRUE)
> a<-table.row.end(a)
> for (i in 1:n) {
+ a<-table.row.start(a)
+ a<-table.element(a,i, 1, TRUE)
+ a<-table.element(a,x[i])
+ a<-table.element(a,x[i]-mysum$resid[i])
+ a<-table.element(a,mysum$resid[i])
+ a<-table.row.end(a)
+ }
> a<-table.end(a)
> table.save(a,file="/var/www/html/freestat/rcomp/tmp/14xdlz1290179600.tab")
> if (n > n25) {
+ a<-table.start()
+ a<-table.row.start(a)
+ a<-table.element(a,'Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'p-values',header=TRUE)
+ a<-table.element(a,'Alternative Hypothesis',3,header=TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'breakpoint index',header=TRUE)
+ a<-table.element(a,'greater',header=TRUE)
+ a<-table.element(a,'2-sided',header=TRUE)
+ a<-table.element(a,'less',header=TRUE)
+ a<-table.row.end(a)
+ for (mypoint in kp3:nmkm3) {
+ a<-table.row.start(a)
+ a<-table.element(a,mypoint,header=TRUE)
+ a<-table.element(a,gqarr[mypoint-kp3+1,1])
+ a<-table.element(a,gqarr[mypoint-kp3+1,2])
+ a<-table.element(a,gqarr[mypoint-kp3+1,3])
+ a<-table.row.end(a)
+ }
+ a<-table.end(a)
+ table.save(a,file="/var/www/html/freestat/rcomp/tmp/151wjn1290179600.tab")
+ a<-table.start()
+ a<-table.row.start(a)
+ a<-table.element(a,'Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'Description',header=TRUE)
+ a<-table.element(a,'# significant tests',header=TRUE)
+ a<-table.element(a,'% significant tests',header=TRUE)
+ a<-table.element(a,'OK/NOK',header=TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'1% type I error level',header=TRUE)
+ a<-table.element(a,numsignificant1)
+ a<-table.element(a,numsignificant1/numgqtests)
+ if (numsignificant1/numgqtests < 0.01) dum <- 'OK' else dum <- 'NOK'
+ a<-table.element(a,dum)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'5% type I error level',header=TRUE)
+ a<-table.element(a,numsignificant5)
+ a<-table.element(a,numsignificant5/numgqtests)
+ if (numsignificant5/numgqtests < 0.05) dum <- 'OK' else dum <- 'NOK'
+ a<-table.element(a,dum)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'10% type I error level',header=TRUE)
+ a<-table.element(a,numsignificant10)
+ a<-table.element(a,numsignificant10/numgqtests)
+ if (numsignificant10/numgqtests < 0.1) dum <- 'OK' else dum <- 'NOK'
+ a<-table.element(a,dum)
+ a<-table.row.end(a)
+ a<-table.end(a)
+ table.save(a,file="/var/www/html/freestat/rcomp/tmp/16xnhd1290179600.tab")
+ }
>
> try(system("convert tmp/1sra21290179599.ps tmp/1sra21290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/2l0rn1290179599.ps tmp/2l0rn1290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/3l0rn1290179599.ps tmp/3l0rn1290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/4l0rn1290179599.ps tmp/4l0rn1290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/5v9881290179599.ps tmp/5v9881290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/6v9881290179599.ps tmp/6v9881290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/7o08t1290179599.ps tmp/7o08t1290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/8o08t1290179599.ps tmp/8o08t1290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/9zapv1290179599.ps tmp/9zapv1290179599.png",intern=TRUE))
character(0)
> try(system("convert tmp/10zapv1290179599.ps tmp/10zapv1290179599.png",intern=TRUE))
character(0)
>
>
> proc.time()
user system elapsed
6.877 2.745 48.924