R version 2.15.2 (2012-10-26) -- "Trick or Treat"
Copyright (C) 2012 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: i686-pc-linux-gnu (32-bit)
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.
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(19
+ ,39
+ ,31
+ ,12
+ ,14
+ ,22
+ ,53
+ ,37
+ ,15
+ ,34
+ ,36
+ ,14
+ ,14
+ ,11
+ ,80
+ ,49
+ ,14
+ ,36
+ ,35
+ ,12
+ ,15
+ ,10
+ ,74
+ ,45
+ ,15
+ ,37
+ ,38
+ ,6
+ ,15
+ ,13
+ ,76
+ ,47
+ ,16
+ ,38
+ ,31
+ ,10
+ ,17
+ ,10
+ ,79
+ ,49
+ ,16
+ ,36
+ ,34
+ ,12
+ ,19
+ ,8
+ ,54
+ ,33
+ ,16
+ ,38
+ ,35
+ ,12
+ ,10
+ ,15
+ ,67
+ ,42
+ ,16
+ ,39
+ ,38
+ ,11
+ ,16
+ ,14
+ ,54
+ ,33
+ ,17
+ ,33
+ ,37
+ ,15
+ ,18
+ ,10
+ ,87
+ ,53
+ ,15
+ ,32
+ ,33
+ ,12
+ ,14
+ ,14
+ ,58
+ ,36
+ ,15
+ ,36
+ ,32
+ ,10
+ ,14
+ ,14
+ ,75
+ ,45
+ ,20
+ ,38
+ ,38
+ ,12
+ ,17
+ ,11
+ ,88
+ ,54
+ ,18
+ ,39
+ ,38
+ ,11
+ ,14
+ ,10
+ ,64
+ ,41
+ ,16
+ ,32
+ ,32
+ ,12
+ ,16
+ ,13
+ ,57
+ ,36
+ ,16
+ ,32
+ ,33
+ ,11
+ ,18
+ ,7
+ ,66
+ ,41
+ ,16
+ ,31
+ ,31
+ ,12
+ ,11
+ ,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19
+ ,73
+ ,46
+ ,10
+ ,38
+ ,39
+ ,7
+ ,16
+ ,12
+ ,85
+ ,53
+ ,15
+ ,42
+ ,37
+ ,13
+ ,13
+ ,17
+ ,79
+ ,47
+ ,16
+ ,34
+ ,38
+ ,9
+ ,16
+ ,9
+ ,71
+ ,41
+ ,16
+ ,35
+ ,39
+ ,6
+ ,12
+ ,12
+ ,72
+ ,44
+ ,14
+ ,35
+ ,34
+ ,8
+ ,9
+ ,19
+ ,69
+ ,43
+ ,10
+ ,33
+ ,31
+ ,8
+ ,13
+ ,18
+ ,78
+ ,51
+ ,17
+ ,36
+ ,32
+ ,15
+ ,13
+ ,15
+ ,54
+ ,33
+ ,13
+ ,32
+ ,37
+ ,6
+ ,14
+ ,14
+ ,69
+ ,43
+ ,15
+ ,33
+ ,36
+ ,9
+ ,19
+ ,11
+ ,81
+ ,53
+ ,16
+ ,34
+ ,32
+ ,11
+ ,13
+ ,9
+ ,84
+ ,51
+ ,12
+ ,32
+ ,35
+ ,8
+ ,12
+ ,18
+ ,84
+ ,50
+ ,13
+ ,34
+ ,36
+ ,8
+ ,13
+ ,16
+ ,69
+ ,46)
+ ,dim=c(8
+ ,156)
+ ,dimnames=list(c('Learning'
+ ,'Connected'
+ ,'Separate'
+ ,'Software'
+ ,'Happiness'
+ ,'Depression'
+ ,'Belonging'
+ ,'Belongfinal
')
+ ,1:156))
> y <- array(NA,dim=c(8,156),dimnames=list(c('Learning','Connected','Separate','Software','Happiness','Depression','Belonging','Belongfinal
'),1:156))
> for (i in 1:dim(x)[1])
+ {
+ for (j in 1:dim(x)[2])
+ {
+ y[i,j] <- as.numeric(x[i,j])
+ }
+ }
> par3 = 'Linear Trend'
> par2 = 'Do not include Seasonal Dummies'
> par1 = '1'
> par3 <- 'Linear Trend'
> par2 <- 'Do not include Seasonal Dummies'
> par1 <- '1'
> #'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, 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
Learning Connected Separate Software Happiness Depression Belonging
1 19 39 31 12 14 22 53
2 15 34 36 14 14 11 80
3 14 36 35 12 15 10 74
4 15 37 38 6 15 13 76
5 16 38 31 10 17 10 79
6 16 36 34 12 19 8 54
7 16 38 35 12 10 15 67
8 16 39 38 11 16 14 54
9 17 33 37 15 18 10 87
10 15 32 33 12 14 14 58
11 15 36 32 10 14 14 75
12 20 38 38 12 17 11 88
13 18 39 38 11 14 10 64
14 16 32 32 12 16 13 57
15 16 32 33 11 18 7 66
16 16 31 31 12 11 14 68
17 19 39 38 13 14 12 54
18 16 37 39 11 12 14 56
19 17 39 32 9 17 11 86
20 17 41 32 13 9 9 80
21 16 36 35 10 16 11 76
22 15 33 37 14 14 15 69
23 16 33 33 12 15 14 78
24 14 34 33 10 11 13 67
25 15 31 28 12 16 9 80
26 12 27 32 8 13 15 54
27 14 37 31 10 17 10 71
28 16 34 37 12 15 11 84
29 14 34 30 12 14 13 74
30 7 32 33 7 16 8 71
31 10 29 31 6 9 20 63
32 14 36 33 12 15 12 71
33 16 29 31 10 17 10 76
34 16 35 33 10 13 10 69
35 16 37 32 10 15 9 74
36 14 34 33 12 16 14 75
37 20 38 32 15 16 8 54
38 14 35 33 10 12 14 52
39 14 38 28 10 12 11 69
40 11 37 35 12 11 13 68
41 14 38 39 13 15 9 65
42 15 33 34 11 15 11 75
43 16 36 38 11 17 15 74
44 14 38 32 12 13 11 75
45 16 32 38 14 16 10 72
46 14 32 30 10 14 14 67
47 12 32 33 12 11 18 63
48 16 34 38 13 12 14 62
49 9 32 32 5 12 11 63
50 14 37 32 6 15 12 76
51 16 39 34 12 16 13 74
52 16 29 34 12 15 9 67
53 15 37 36 11 12 10 73
54 16 35 34 10 12 15 70
55 12 30 28 7 8 20 53
56 16 38 34 12 13 12 77
57 16 34 35 14 11 12 77
58 14 31 35 11 14 14 52
59 16 34 31 12 15 13 54
60 17 35 37 13 10 11 80
61 18 36 35 14 11 17 66
62 18 30 27 11 12 12 73
63 12 39 40 12 15 13 63
64 16 35 37 12 15 14 69
65 10 38 36 8 14 13 67
66 14 31 38 11 16 15 54
67 18 34 39 14 15 13 81
68 18 38 41 14 15 10 69
69 16 34 27 12 13 11 84
70 17 39 30 9 12 19 80
71 16 37 37 13 17 13 70
72 16 34 31 11 13 17 69
73 13 28 31 12 15 13 77
74 16 37 27 12 13 9 54
75 16 33 36 12 15 11 79
76 20 37 38 12 16 10 30
77 16 35 37 12 15 9 71
78 15 37 33 12 16 12 73
79 15 32 34 11 15 12 72
80 16 33 31 10 14 13 77
81 14 38 39 9 15 13 75
82 16 33 34 12 14 12 69
83 16 29 32 12 13 15 54
84 15 33 33 12 7 22 70
85 12 31 36 9 17 13 73
86 17 36 32 15 13 15 54
87 16 35 41 12 15 13 77
88 15 32 28 12 14 15 82
89 13 29 30 12 13 10 80
90 16 39 36 10 16 11 80
91 16 37 35 13 12 16 69
92 16 35 31 9 14 11 78
93 16 37 34 12 17 11 81
94 14 32 36 10 15 10 76
95 16 38 36 14 17 10 76
96 16 37 35 11 12 16 73
97 20 36 37 15 16 12 85
98 15 32 28 11 11 11 66
99 16 33 39 11 15 16 79
100 13 40 32 12 9 19 68
101 17 38 35 12 16 11 76
102 16 41 39 12 15 16 71
103 16 36 35 11 10 15 54
104 12 43 42 7 10 24 46
105 16 30 34 12 15 14 82
106 16 31 33 14 11 15 74
107 17 32 41 11 13 11 88
108 13 32 33 11 14 15 38
109 12 37 34 10 18 12 76
110 18 37 32 13 16 10 86
111 14 33 40 13 14 14 54
112 14 34 40 8 14 13 70
113 13 33 35 11 14 9 69
114 16 38 36 12 14 15 90
115 13 33 37 11 12 15 54
116 16 31 27 13 14 14 76
117 13 38 39 12 15 11 89
118 16 37 38 14 15 8 76
119 15 33 31 13 15 11 73
120 16 31 33 15 13 11 79
121 15 39 32 10 17 8 90
122 17 44 39 11 17 10 74
123 15 33 36 9 19 11 81
124 12 35 33 11 15 13 72
125 16 32 33 10 13 11 71
126 10 28 32 11 9 20 66
127 16 40 37 8 15 10 77
128 12 27 30 11 15 15 65
129 14 37 38 12 15 12 74
130 15 32 29 12 16 14 82
131 13 28 22 9 11 23 54
132 15 34 35 11 14 14 63
133 11 30 35 10 11 16 54
134 12 35 34 8 15 11 64
135 8 31 35 9 13 12 69
136 16 32 34 8 15 10 54
137 15 30 34 9 16 14 84
138 17 30 35 15 14 12 86
139 16 31 23 11 15 12 77
140 10 40 31 8 16 11 89
141 18 32 27 13 16 12 76
142 13 36 36 12 11 13 60
143 16 32 31 12 12 11 75
144 13 35 32 9 9 19 73
145 10 38 39 7 16 12 85
146 15 42 37 13 13 17 79
147 16 34 38 9 16 9 71
148 16 35 39 6 12 12 72
149 14 35 34 8 9 19 69
150 10 33 31 8 13 18 78
151 17 36 32 15 13 15 54
152 13 32 37 6 14 14 69
153 15 33 36 9 19 11 81
154 16 34 32 11 13 9 84
155 12 32 35 8 12 18 84
156 13 34 36 8 13 16 69
Belongfinal\r t
1 37 1
2 49 2
3 45 3
4 47 4
5 49 5
6 33 6
7 42 7
8 33 8
9 53 9
10 36 10
11 45 11
12 54 12
13 41 13
14 36 14
15 41 15
16 44 16
17 33 17
18 37 18
19 52 19
20 47 20
21 43 21
22 44 22
23 45 23
24 44 24
25 49 25
26 33 26
27 43 27
28 54 28
29 42 29
30 44 30
31 37 31
32 43 32
33 46 33
34 42 34
35 45 35
36 44 36
37 33 37
38 31 38
39 42 39
40 40 40
41 43 41
42 46 42
43 42 43
44 45 44
45 44 45
46 40 46
47 37 47
48 46 48
49 36 49
50 47 50
51 45 51
52 42 52
53 43 53
54 43 54
55 32 55
56 45 56
57 45 57
58 31 58
59 33 59
60 49 60
61 42 61
62 41 62
63 38 63
64 42 64
65 44 65
66 33 66
67 48 67
68 40 68
69 50 69
70 49 70
71 43 71
72 44 72
73 47 73
74 33 74
75 46 75
76 0 76
77 45 77
78 43 78
79 44 79
80 47 80
81 45 81
82 42 82
83 33 83
84 43 84
85 46 85
86 33 86
87 46 87
88 48 88
89 47 89
90 47 90
91 43 91
92 46 92
93 48 93
94 46 94
95 45 95
96 45 96
97 52 97
98 42 98
99 47 99
100 41 100
101 47 101
102 43 102
103 33 103
104 30 104
105 49 105
106 44 106
107 55 107
108 11 108
109 47 109
110 53 110
111 33 111
112 44 112
113 42 113
114 55 114
115 33 115
116 46 116
117 54 117
118 47 118
119 45 119
120 47 120
121 55 121
122 44 122
123 53 123
124 44 124
125 42 125
126 40 126
127 46 127
128 40 128
129 46 129
130 53 130
131 33 131
132 42 132
133 35 133
134 40 134
135 41 135
136 33 136
137 51 137
138 53 138
139 46 139
140 55 140
141 47 141
142 38 142
143 46 143
144 46 144
145 53 145
146 47 146
147 41 147
148 44 148
149 43 149
150 51 150
151 33 151
152 43 152
153 53 153
154 51 154
155 50 155
156 46 156
> k <- length(x[1,])
> df <- as.data.frame(x)
> (mylm <- lm(df))
Call:
lm(formula = df)
Coefficients:
(Intercept) Connected Separate Software
3.88264 0.13322 -0.02400 0.54336
Happiness Depression Belonging `Belongfinal\\r`
0.10811 -0.02974 0.04661 -0.06506
t
-0.00453
> (mysum <- summary(mylm))
Call:
lm(formula = df)
Residuals:
Min 1Q Median 3Q Max
-5.9600 -1.0391 0.2202 1.1992 4.3670
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 3.882640 2.683792 1.447 0.15011
Connected 0.133224 0.047820 2.786 0.00604 **
Separate -0.024001 0.045101 -0.532 0.59543
Software 0.543359 0.070891 7.665 2.24e-12 ***
Happiness 0.108110 0.078736 1.373 0.17182
Depression -0.029736 0.059321 -0.501 0.61693
Belonging 0.046608 0.044483 1.048 0.29646
`Belongfinal\\r` -0.065057 0.063180 -1.030 0.30484
t -0.004530 0.003414 -1.327 0.18666
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 1.815 on 147 degrees of freedom
Multiple R-squared: 0.3895, Adjusted R-squared: 0.3562
F-statistic: 11.72 on 8 and 147 DF, p-value: 8.021e-13
> 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,] 0.069570859 0.139141718 0.9304291
[2,] 0.064225909 0.128451817 0.9357741
[3,] 0.027940821 0.055881642 0.9720592
[4,] 0.010119047 0.020238093 0.9898810
[5,] 0.003576985 0.007153971 0.9964230
[6,] 0.002247084 0.004494168 0.9977529
[7,] 0.029668453 0.059336906 0.9703315
[8,] 0.030700691 0.061401381 0.9692993
[9,] 0.017232467 0.034464933 0.9827675
[10,] 0.009147692 0.018295384 0.9908523
[11,] 0.056860156 0.113720313 0.9431398
[12,] 0.036738597 0.073477193 0.9632614
[13,] 0.042741849 0.085483699 0.9572582
[14,] 0.027835204 0.055670408 0.9721648
[15,] 0.016850252 0.033700505 0.9831497
[16,] 0.045794601 0.091589203 0.9542054
[17,] 0.032593948 0.065187895 0.9674061
[18,] 0.026893154 0.053786307 0.9731068
[19,] 0.412319687 0.824639374 0.5876803
[20,] 0.351601041 0.703202083 0.6483990
[21,] 0.354085700 0.708171399 0.6459143
[22,] 0.494849119 0.989698239 0.5051509
[23,] 0.508155019 0.983689962 0.4918450
[24,] 0.460876418 0.921752836 0.5391236
[25,] 0.456392667 0.912785334 0.5436073
[26,] 0.473815199 0.947630398 0.5261848
[27,] 0.415863422 0.831726844 0.5841366
[28,] 0.377928853 0.755857705 0.6220711
[29,] 0.638049652 0.723900696 0.3619503
[30,] 0.678477209 0.643045582 0.3215228
[31,] 0.642849491 0.714301018 0.3571505
[32,] 0.602075028 0.795849945 0.3979250
[33,] 0.590084118 0.819831764 0.4099159
[34,] 0.548633198 0.902733605 0.4513668
[35,] 0.502502827 0.994994345 0.4974972
[36,] 0.518602895 0.962794209 0.4813971
[37,] 0.474660026 0.949320051 0.5253400
[38,] 0.482899936 0.965799872 0.5171001
[39,] 0.448387791 0.896775581 0.5516122
[40,] 0.399243753 0.798487506 0.6007562
[41,] 0.434570207 0.869140414 0.5654298
[42,] 0.405954883 0.811909766 0.5940451
[43,] 0.424826148 0.849652296 0.5751739
[44,] 0.399487449 0.798974899 0.6005126
[45,] 0.357784265 0.715568530 0.6422157
[46,] 0.333157098 0.666314195 0.6668429
[47,] 0.291565595 0.583131190 0.7084344
[48,] 0.255260450 0.510520901 0.7447395
[49,] 0.256303581 0.512607163 0.7436964
[50,] 0.247204362 0.494408724 0.7527956
[51,] 0.437931446 0.875862892 0.5620686
[52,] 0.609362276 0.781275448 0.3906377
[53,] 0.566258444 0.867483112 0.4337416
[54,] 0.704820806 0.590358388 0.2951792
[55,] 0.664660816 0.670678368 0.3353392
[56,] 0.654438334 0.691123331 0.3455617
[57,] 0.632099527 0.735800947 0.3679005
[58,] 0.586375458 0.827249084 0.4136245
[59,] 0.618066761 0.763866478 0.3819332
[60,] 0.576235078 0.847529845 0.4237649
[61,] 0.551248896 0.897502208 0.4487511
[62,] 0.555722310 0.888555380 0.4442777
[63,] 0.508838715 0.982322570 0.4911613
[64,] 0.470430393 0.940860786 0.5295696
[65,] 0.592216251 0.815567499 0.4077837
[66,] 0.553213227 0.893573547 0.4467868
[67,] 0.526213909 0.947572182 0.4737861
[68,] 0.481839335 0.963678670 0.5181607
[69,] 0.473211776 0.946423552 0.5267882
[70,] 0.426856866 0.853713731 0.5731431
[71,] 0.386849990 0.773699981 0.6131500
[72,] 0.370062208 0.740124417 0.6299378
[73,] 0.333434476 0.666868952 0.6665655
[74,] 0.320944179 0.641888358 0.6790558
[75,] 0.286406268 0.572812536 0.7135937
[76,] 0.249850845 0.499701691 0.7501492
[77,] 0.215711741 0.431423482 0.7842883
[78,] 0.229400584 0.458801168 0.7705994
[79,] 0.198465332 0.396930664 0.8015347
[80,] 0.167901353 0.335802705 0.8320986
[81,] 0.166779868 0.333559736 0.8332201
[82,] 0.138707632 0.277415265 0.8612924
[83,] 0.116974438 0.233948876 0.8830256
[84,] 0.106003387 0.212006774 0.8939966
[85,] 0.093892349 0.187784699 0.9061077
[86,] 0.119716160 0.239432319 0.8802838
[87,] 0.099602804 0.199205609 0.9003972
[88,] 0.094810031 0.189620061 0.9051900
[89,] 0.110088713 0.220177425 0.8899113
[90,] 0.096069457 0.192138915 0.9039305
[91,] 0.083924286 0.167848573 0.9160757
[92,] 0.083085615 0.166171230 0.9169144
[93,] 0.082503789 0.165007578 0.9174962
[94,] 0.073922294 0.147844587 0.9260777
[95,] 0.061355217 0.122710434 0.9386448
[96,] 0.094897342 0.189794684 0.9051027
[97,] 0.088934120 0.177868240 0.9110659
[98,] 0.107380542 0.214761084 0.8926195
[99,] 0.113314956 0.226629912 0.8866850
[100,] 0.094283065 0.188566130 0.9057169
[101,] 0.097231114 0.194462227 0.9027689
[102,] 0.086218952 0.172437905 0.9137810
[103,] 0.098085074 0.196170148 0.9019149
[104,] 0.077839118 0.155678235 0.9221609
[105,] 0.067556814 0.135113628 0.9324432
[106,] 0.066554627 0.133109254 0.9334454
[107,] 0.050509952 0.101019904 0.9494900
[108,] 0.037830375 0.075660751 0.9621696
[109,] 0.027665080 0.055330160 0.9723349
[110,] 0.019631357 0.039262715 0.9803686
[111,] 0.018414953 0.036829907 0.9815850
[112,] 0.020584229 0.041168458 0.9794158
[113,] 0.020988277 0.041976553 0.9790117
[114,] 0.024291874 0.048583747 0.9757081
[115,] 0.025714326 0.051428651 0.9742857
[116,] 0.056961083 0.113922166 0.9430389
[117,] 0.059641247 0.119282494 0.9403588
[118,] 0.045298552 0.090597104 0.9547014
[119,] 0.036536617 0.073073233 0.9634634
[120,] 0.025865150 0.051730300 0.9741349
[121,] 0.031730047 0.063460094 0.9682700
[122,] 0.026087730 0.052175460 0.9739123
[123,] 0.016939916 0.033879831 0.9830601
[124,] 0.478863203 0.957726407 0.5211368
[125,] 0.428493245 0.856986491 0.5715068
[126,] 0.359670544 0.719341088 0.6403295
[127,] 0.276475881 0.552951762 0.7235241
[128,] 0.203333755 0.406667509 0.7966662
[129,] 0.251312021 0.502624043 0.7486880
[130,] 0.283396714 0.566793429 0.7166033
[131,] 0.573714358 0.852571285 0.4262856
[132,] 0.585905621 0.828188757 0.4140944
[133,] 0.588018003 0.823963994 0.4119820
> postscript(file="/var/wessaorg/rcomp/tmp/1isgt1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/2i4kp1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/3a6mh1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/4bs7v1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/570d81352156658.ps",horizontal=F,onefile=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 = 156
Frequency = 1
1 2 3 4 5
3.2273654694 -1.8735239681 -2.1911503419 2.1384162991 0.3531443497
6 7 8 9 10
-0.5419952395 0.3808343832 0.2094961522 -0.7561536623 -0.2872759082
11 12 13 14 15
0.0402496508 3.4016865651 2.3837990760 0.5074954535 0.5905637462
16 17 18 19 20
1.2038325893 2.3202958724 1.1446969846 1.7493477865 0.0737653185
21 22 23 24 25
0.6754007108 -1.3193551967 0.1836290477 -0.0080096409 -0.7506406031
26 27 28 29 30
-0.2701326505 -1.4314514031 0.3857146531 -1.9247818273 -5.9599649593
31 32 33 34 35
-1.0293409101 -2.0386035642 1.6236538320 1.3753072983 0.8055626401
36 37 38 39 40
-1.9240497255 1.9782340024 -0.3028106433 -0.9838734727 -4.6807587878
41 42 43 44 45
-2.4731972845 -0.0472686062 0.3426916799 -2.1445280255 -0.5626654667
46 47 48 49 50
-0.2687283207 -2.8443814476 0.8754129609 -2.4371240524 1.1730521148
51 52 53 54 55
-0.4162933783 1.0407343219 -0.2896968154 1.7651422326 0.5796970867
56 57 58 59 60
-0.1056491962 -0.4147192290 -0.3908937652 0.4736538906 1.2557848135
61 62 63 64 65
1.8031474905 3.3969952277 -4.0525317894 0.4232093413 -3.5207927225
66 67 68 69 70
-0.4322399364 1.3326154478 0.8018828872 0.2874263021 2.7952831429
71 72 73 74 75
-0.5823963351 1.4275700053 -1.8247690589 0.1432048235 0.4204266681
76 77 78 79 80
3.0933860168 0.4353751106 -1.1647799501 0.2930071136 1.7356464779
81 82 83 84 85
-0.3355904943 0.7478334921 1.5481849494 0.8054680315 -1.5148484125
86 87 88 89 90
-0.0008738667 0.4810263663 -0.3621225123 -1.9223267710 0.6860855480
91 92 93 94 95
0.1365656310 1.8957790016 -0.2582565106 -0.1634739400 -1.4130046417
96 97 98 99 100
1.1896150160 2.5466530059 0.7873113407 1.3582393581 -2.4209501698
101 102 103 104 105
0.9448523861 -0.1246888017 1.6459027047 -0.4953842650 1.0525488314
106 107 108 109 110
0.3228910665 2.7442299786 -1.9645180315 -3.0094510254 1.3980106676
111 112 113 114 115
-1.3470768088 1.1811869010 -1.6335871883 0.2308466236 -1.0682846977
116 117 118 119 120
0.4503779648 -2.9290634678 -0.8407285582 -0.8290285959 -0.5300816171
121 122 123 124 125
-0.4124315481 0.6401938508 1.1976814818 -2.8970865310 2.1237188379
126 127 128 129 130
-3.1032263746 1.9843274510 -1.7596735479 -1.5570801664 -0.0685372267
131 132 133 134 135
0.7430205646 0.7475827523 -1.8237555503 -1.1445440615 -5.0485030121
136 137 138 139 140
3.2451350661 1.7563703220 0.7183927653 1.3310921106 -4.1529455067
141 142 143 144 145
2.2197663207 -1.8187351618 1.2524432959 0.1668090060 -3.0424300555
146 147 148 149 150
-1.5166396589 2.1714305230 4.3670243756 1.7720798506 -2.3901354037
151 152 153 154 155
0.2935683065 1.6548342970 1.3335778694 1.3414138557 -0.3748554371
156
0.6585386991
> postscript(file="/var/wessaorg/rcomp/tmp/6n5qt1352156658.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556)
> dum <- cbind(lag(myerror,k=1),myerror)
> dum
Time Series:
Start = 0
End = 156
Frequency = 1
lag(myerror, k = 1) myerror
0 3.2273654694 NA
1 -1.8735239681 3.2273654694
2 -2.1911503419 -1.8735239681
3 2.1384162991 -2.1911503419
4 0.3531443497 2.1384162991
5 -0.5419952395 0.3531443497
6 0.3808343832 -0.5419952395
7 0.2094961522 0.3808343832
8 -0.7561536623 0.2094961522
9 -0.2872759082 -0.7561536623
10 0.0402496508 -0.2872759082
11 3.4016865651 0.0402496508
12 2.3837990760 3.4016865651
13 0.5074954535 2.3837990760
14 0.5905637462 0.5074954535
15 1.2038325893 0.5905637462
16 2.3202958724 1.2038325893
17 1.1446969846 2.3202958724
18 1.7493477865 1.1446969846
19 0.0737653185 1.7493477865
20 0.6754007108 0.0737653185
21 -1.3193551967 0.6754007108
22 0.1836290477 -1.3193551967
23 -0.0080096409 0.1836290477
24 -0.7506406031 -0.0080096409
25 -0.2701326505 -0.7506406031
26 -1.4314514031 -0.2701326505
27 0.3857146531 -1.4314514031
28 -1.9247818273 0.3857146531
29 -5.9599649593 -1.9247818273
30 -1.0293409101 -5.9599649593
31 -2.0386035642 -1.0293409101
32 1.6236538320 -2.0386035642
33 1.3753072983 1.6236538320
34 0.8055626401 1.3753072983
35 -1.9240497255 0.8055626401
36 1.9782340024 -1.9240497255
37 -0.3028106433 1.9782340024
38 -0.9838734727 -0.3028106433
39 -4.6807587878 -0.9838734727
40 -2.4731972845 -4.6807587878
41 -0.0472686062 -2.4731972845
42 0.3426916799 -0.0472686062
43 -2.1445280255 0.3426916799
44 -0.5626654667 -2.1445280255
45 -0.2687283207 -0.5626654667
46 -2.8443814476 -0.2687283207
47 0.8754129609 -2.8443814476
48 -2.4371240524 0.8754129609
49 1.1730521148 -2.4371240524
50 -0.4162933783 1.1730521148
51 1.0407343219 -0.4162933783
52 -0.2896968154 1.0407343219
53 1.7651422326 -0.2896968154
54 0.5796970867 1.7651422326
55 -0.1056491962 0.5796970867
56 -0.4147192290 -0.1056491962
57 -0.3908937652 -0.4147192290
58 0.4736538906 -0.3908937652
59 1.2557848135 0.4736538906
60 1.8031474905 1.2557848135
61 3.3969952277 1.8031474905
62 -4.0525317894 3.3969952277
63 0.4232093413 -4.0525317894
64 -3.5207927225 0.4232093413
65 -0.4322399364 -3.5207927225
66 1.3326154478 -0.4322399364
67 0.8018828872 1.3326154478
68 0.2874263021 0.8018828872
69 2.7952831429 0.2874263021
70 -0.5823963351 2.7952831429
71 1.4275700053 -0.5823963351
72 -1.8247690589 1.4275700053
73 0.1432048235 -1.8247690589
74 0.4204266681 0.1432048235
75 3.0933860168 0.4204266681
76 0.4353751106 3.0933860168
77 -1.1647799501 0.4353751106
78 0.2930071136 -1.1647799501
79 1.7356464779 0.2930071136
80 -0.3355904943 1.7356464779
81 0.7478334921 -0.3355904943
82 1.5481849494 0.7478334921
83 0.8054680315 1.5481849494
84 -1.5148484125 0.8054680315
85 -0.0008738667 -1.5148484125
86 0.4810263663 -0.0008738667
87 -0.3621225123 0.4810263663
88 -1.9223267710 -0.3621225123
89 0.6860855480 -1.9223267710
90 0.1365656310 0.6860855480
91 1.8957790016 0.1365656310
92 -0.2582565106 1.8957790016
93 -0.1634739400 -0.2582565106
94 -1.4130046417 -0.1634739400
95 1.1896150160 -1.4130046417
96 2.5466530059 1.1896150160
97 0.7873113407 2.5466530059
98 1.3582393581 0.7873113407
99 -2.4209501698 1.3582393581
100 0.9448523861 -2.4209501698
101 -0.1246888017 0.9448523861
102 1.6459027047 -0.1246888017
103 -0.4953842650 1.6459027047
104 1.0525488314 -0.4953842650
105 0.3228910665 1.0525488314
106 2.7442299786 0.3228910665
107 -1.9645180315 2.7442299786
108 -3.0094510254 -1.9645180315
109 1.3980106676 -3.0094510254
110 -1.3470768088 1.3980106676
111 1.1811869010 -1.3470768088
112 -1.6335871883 1.1811869010
113 0.2308466236 -1.6335871883
114 -1.0682846977 0.2308466236
115 0.4503779648 -1.0682846977
116 -2.9290634678 0.4503779648
117 -0.8407285582 -2.9290634678
118 -0.8290285959 -0.8407285582
119 -0.5300816171 -0.8290285959
120 -0.4124315481 -0.5300816171
121 0.6401938508 -0.4124315481
122 1.1976814818 0.6401938508
123 -2.8970865310 1.1976814818
124 2.1237188379 -2.8970865310
125 -3.1032263746 2.1237188379
126 1.9843274510 -3.1032263746
127 -1.7596735479 1.9843274510
128 -1.5570801664 -1.7596735479
129 -0.0685372267 -1.5570801664
130 0.7430205646 -0.0685372267
131 0.7475827523 0.7430205646
132 -1.8237555503 0.7475827523
133 -1.1445440615 -1.8237555503
134 -5.0485030121 -1.1445440615
135 3.2451350661 -5.0485030121
136 1.7563703220 3.2451350661
137 0.7183927653 1.7563703220
138 1.3310921106 0.7183927653
139 -4.1529455067 1.3310921106
140 2.2197663207 -4.1529455067
141 -1.8187351618 2.2197663207
142 1.2524432959 -1.8187351618
143 0.1668090060 1.2524432959
144 -3.0424300555 0.1668090060
145 -1.5166396589 -3.0424300555
146 2.1714305230 -1.5166396589
147 4.3670243756 2.1714305230
148 1.7720798506 4.3670243756
149 -2.3901354037 1.7720798506
150 0.2935683065 -2.3901354037
151 1.6548342970 0.2935683065
152 1.3335778694 1.6548342970
153 1.3414138557 1.3335778694
154 -0.3748554371 1.3414138557
155 0.6585386991 -0.3748554371
156 NA 0.6585386991
> dum1 <- dum[2:length(myerror),]
> dum1
lag(myerror, k = 1) myerror
[1,] -1.8735239681 3.2273654694
[2,] -2.1911503419 -1.8735239681
[3,] 2.1384162991 -2.1911503419
[4,] 0.3531443497 2.1384162991
[5,] -0.5419952395 0.3531443497
[6,] 0.3808343832 -0.5419952395
[7,] 0.2094961522 0.3808343832
[8,] -0.7561536623 0.2094961522
[9,] -0.2872759082 -0.7561536623
[10,] 0.0402496508 -0.2872759082
[11,] 3.4016865651 0.0402496508
[12,] 2.3837990760 3.4016865651
[13,] 0.5074954535 2.3837990760
[14,] 0.5905637462 0.5074954535
[15,] 1.2038325893 0.5905637462
[16,] 2.3202958724 1.2038325893
[17,] 1.1446969846 2.3202958724
[18,] 1.7493477865 1.1446969846
[19,] 0.0737653185 1.7493477865
[20,] 0.6754007108 0.0737653185
[21,] -1.3193551967 0.6754007108
[22,] 0.1836290477 -1.3193551967
[23,] -0.0080096409 0.1836290477
[24,] -0.7506406031 -0.0080096409
[25,] -0.2701326505 -0.7506406031
[26,] -1.4314514031 -0.2701326505
[27,] 0.3857146531 -1.4314514031
[28,] -1.9247818273 0.3857146531
[29,] -5.9599649593 -1.9247818273
[30,] -1.0293409101 -5.9599649593
[31,] -2.0386035642 -1.0293409101
[32,] 1.6236538320 -2.0386035642
[33,] 1.3753072983 1.6236538320
[34,] 0.8055626401 1.3753072983
[35,] -1.9240497255 0.8055626401
[36,] 1.9782340024 -1.9240497255
[37,] -0.3028106433 1.9782340024
[38,] -0.9838734727 -0.3028106433
[39,] -4.6807587878 -0.9838734727
[40,] -2.4731972845 -4.6807587878
[41,] -0.0472686062 -2.4731972845
[42,] 0.3426916799 -0.0472686062
[43,] -2.1445280255 0.3426916799
[44,] -0.5626654667 -2.1445280255
[45,] -0.2687283207 -0.5626654667
[46,] -2.8443814476 -0.2687283207
[47,] 0.8754129609 -2.8443814476
[48,] -2.4371240524 0.8754129609
[49,] 1.1730521148 -2.4371240524
[50,] -0.4162933783 1.1730521148
[51,] 1.0407343219 -0.4162933783
[52,] -0.2896968154 1.0407343219
[53,] 1.7651422326 -0.2896968154
[54,] 0.5796970867 1.7651422326
[55,] -0.1056491962 0.5796970867
[56,] -0.4147192290 -0.1056491962
[57,] -0.3908937652 -0.4147192290
[58,] 0.4736538906 -0.3908937652
[59,] 1.2557848135 0.4736538906
[60,] 1.8031474905 1.2557848135
[61,] 3.3969952277 1.8031474905
[62,] -4.0525317894 3.3969952277
[63,] 0.4232093413 -4.0525317894
[64,] -3.5207927225 0.4232093413
[65,] -0.4322399364 -3.5207927225
[66,] 1.3326154478 -0.4322399364
[67,] 0.8018828872 1.3326154478
[68,] 0.2874263021 0.8018828872
[69,] 2.7952831429 0.2874263021
[70,] -0.5823963351 2.7952831429
[71,] 1.4275700053 -0.5823963351
[72,] -1.8247690589 1.4275700053
[73,] 0.1432048235 -1.8247690589
[74,] 0.4204266681 0.1432048235
[75,] 3.0933860168 0.4204266681
[76,] 0.4353751106 3.0933860168
[77,] -1.1647799501 0.4353751106
[78,] 0.2930071136 -1.1647799501
[79,] 1.7356464779 0.2930071136
[80,] -0.3355904943 1.7356464779
[81,] 0.7478334921 -0.3355904943
[82,] 1.5481849494 0.7478334921
[83,] 0.8054680315 1.5481849494
[84,] -1.5148484125 0.8054680315
[85,] -0.0008738667 -1.5148484125
[86,] 0.4810263663 -0.0008738667
[87,] -0.3621225123 0.4810263663
[88,] -1.9223267710 -0.3621225123
[89,] 0.6860855480 -1.9223267710
[90,] 0.1365656310 0.6860855480
[91,] 1.8957790016 0.1365656310
[92,] -0.2582565106 1.8957790016
[93,] -0.1634739400 -0.2582565106
[94,] -1.4130046417 -0.1634739400
[95,] 1.1896150160 -1.4130046417
[96,] 2.5466530059 1.1896150160
[97,] 0.7873113407 2.5466530059
[98,] 1.3582393581 0.7873113407
[99,] -2.4209501698 1.3582393581
[100,] 0.9448523861 -2.4209501698
[101,] -0.1246888017 0.9448523861
[102,] 1.6459027047 -0.1246888017
[103,] -0.4953842650 1.6459027047
[104,] 1.0525488314 -0.4953842650
[105,] 0.3228910665 1.0525488314
[106,] 2.7442299786 0.3228910665
[107,] -1.9645180315 2.7442299786
[108,] -3.0094510254 -1.9645180315
[109,] 1.3980106676 -3.0094510254
[110,] -1.3470768088 1.3980106676
[111,] 1.1811869010 -1.3470768088
[112,] -1.6335871883 1.1811869010
[113,] 0.2308466236 -1.6335871883
[114,] -1.0682846977 0.2308466236
[115,] 0.4503779648 -1.0682846977
[116,] -2.9290634678 0.4503779648
[117,] -0.8407285582 -2.9290634678
[118,] -0.8290285959 -0.8407285582
[119,] -0.5300816171 -0.8290285959
[120,] -0.4124315481 -0.5300816171
[121,] 0.6401938508 -0.4124315481
[122,] 1.1976814818 0.6401938508
[123,] -2.8970865310 1.1976814818
[124,] 2.1237188379 -2.8970865310
[125,] -3.1032263746 2.1237188379
[126,] 1.9843274510 -3.1032263746
[127,] -1.7596735479 1.9843274510
[128,] -1.5570801664 -1.7596735479
[129,] -0.0685372267 -1.5570801664
[130,] 0.7430205646 -0.0685372267
[131,] 0.7475827523 0.7430205646
[132,] -1.8237555503 0.7475827523
[133,] -1.1445440615 -1.8237555503
[134,] -5.0485030121 -1.1445440615
[135,] 3.2451350661 -5.0485030121
[136,] 1.7563703220 3.2451350661
[137,] 0.7183927653 1.7563703220
[138,] 1.3310921106 0.7183927653
[139,] -4.1529455067 1.3310921106
[140,] 2.2197663207 -4.1529455067
[141,] -1.8187351618 2.2197663207
[142,] 1.2524432959 -1.8187351618
[143,] 0.1668090060 1.2524432959
[144,] -3.0424300555 0.1668090060
[145,] -1.5166396589 -3.0424300555
[146,] 2.1714305230 -1.5166396589
[147,] 4.3670243756 2.1714305230
[148,] 1.7720798506 4.3670243756
[149,] -2.3901354037 1.7720798506
[150,] 0.2935683065 -2.3901354037
[151,] 1.6548342970 0.2935683065
[152,] 1.3335778694 1.6548342970
[153,] 1.3414138557 1.3335778694
[154,] -0.3748554371 1.3414138557
[155,] 0.6585386991 -0.3748554371
> z <- as.data.frame(dum1)
> z
lag(myerror, k = 1) myerror
1 -1.8735239681 3.2273654694
2 -2.1911503419 -1.8735239681
3 2.1384162991 -2.1911503419
4 0.3531443497 2.1384162991
5 -0.5419952395 0.3531443497
6 0.3808343832 -0.5419952395
7 0.2094961522 0.3808343832
8 -0.7561536623 0.2094961522
9 -0.2872759082 -0.7561536623
10 0.0402496508 -0.2872759082
11 3.4016865651 0.0402496508
12 2.3837990760 3.4016865651
13 0.5074954535 2.3837990760
14 0.5905637462 0.5074954535
15 1.2038325893 0.5905637462
16 2.3202958724 1.2038325893
17 1.1446969846 2.3202958724
18 1.7493477865 1.1446969846
19 0.0737653185 1.7493477865
20 0.6754007108 0.0737653185
21 -1.3193551967 0.6754007108
22 0.1836290477 -1.3193551967
23 -0.0080096409 0.1836290477
24 -0.7506406031 -0.0080096409
25 -0.2701326505 -0.7506406031
26 -1.4314514031 -0.2701326505
27 0.3857146531 -1.4314514031
28 -1.9247818273 0.3857146531
29 -5.9599649593 -1.9247818273
30 -1.0293409101 -5.9599649593
31 -2.0386035642 -1.0293409101
32 1.6236538320 -2.0386035642
33 1.3753072983 1.6236538320
34 0.8055626401 1.3753072983
35 -1.9240497255 0.8055626401
36 1.9782340024 -1.9240497255
37 -0.3028106433 1.9782340024
38 -0.9838734727 -0.3028106433
39 -4.6807587878 -0.9838734727
40 -2.4731972845 -4.6807587878
41 -0.0472686062 -2.4731972845
42 0.3426916799 -0.0472686062
43 -2.1445280255 0.3426916799
44 -0.5626654667 -2.1445280255
45 -0.2687283207 -0.5626654667
46 -2.8443814476 -0.2687283207
47 0.8754129609 -2.8443814476
48 -2.4371240524 0.8754129609
49 1.1730521148 -2.4371240524
50 -0.4162933783 1.1730521148
51 1.0407343219 -0.4162933783
52 -0.2896968154 1.0407343219
53 1.7651422326 -0.2896968154
54 0.5796970867 1.7651422326
55 -0.1056491962 0.5796970867
56 -0.4147192290 -0.1056491962
57 -0.3908937652 -0.4147192290
58 0.4736538906 -0.3908937652
59 1.2557848135 0.4736538906
60 1.8031474905 1.2557848135
61 3.3969952277 1.8031474905
62 -4.0525317894 3.3969952277
63 0.4232093413 -4.0525317894
64 -3.5207927225 0.4232093413
65 -0.4322399364 -3.5207927225
66 1.3326154478 -0.4322399364
67 0.8018828872 1.3326154478
68 0.2874263021 0.8018828872
69 2.7952831429 0.2874263021
70 -0.5823963351 2.7952831429
71 1.4275700053 -0.5823963351
72 -1.8247690589 1.4275700053
73 0.1432048235 -1.8247690589
74 0.4204266681 0.1432048235
75 3.0933860168 0.4204266681
76 0.4353751106 3.0933860168
77 -1.1647799501 0.4353751106
78 0.2930071136 -1.1647799501
79 1.7356464779 0.2930071136
80 -0.3355904943 1.7356464779
81 0.7478334921 -0.3355904943
82 1.5481849494 0.7478334921
83 0.8054680315 1.5481849494
84 -1.5148484125 0.8054680315
85 -0.0008738667 -1.5148484125
86 0.4810263663 -0.0008738667
87 -0.3621225123 0.4810263663
88 -1.9223267710 -0.3621225123
89 0.6860855480 -1.9223267710
90 0.1365656310 0.6860855480
91 1.8957790016 0.1365656310
92 -0.2582565106 1.8957790016
93 -0.1634739400 -0.2582565106
94 -1.4130046417 -0.1634739400
95 1.1896150160 -1.4130046417
96 2.5466530059 1.1896150160
97 0.7873113407 2.5466530059
98 1.3582393581 0.7873113407
99 -2.4209501698 1.3582393581
100 0.9448523861 -2.4209501698
101 -0.1246888017 0.9448523861
102 1.6459027047 -0.1246888017
103 -0.4953842650 1.6459027047
104 1.0525488314 -0.4953842650
105 0.3228910665 1.0525488314
106 2.7442299786 0.3228910665
107 -1.9645180315 2.7442299786
108 -3.0094510254 -1.9645180315
109 1.3980106676 -3.0094510254
110 -1.3470768088 1.3980106676
111 1.1811869010 -1.3470768088
112 -1.6335871883 1.1811869010
113 0.2308466236 -1.6335871883
114 -1.0682846977 0.2308466236
115 0.4503779648 -1.0682846977
116 -2.9290634678 0.4503779648
117 -0.8407285582 -2.9290634678
118 -0.8290285959 -0.8407285582
119 -0.5300816171 -0.8290285959
120 -0.4124315481 -0.5300816171
121 0.6401938508 -0.4124315481
122 1.1976814818 0.6401938508
123 -2.8970865310 1.1976814818
124 2.1237188379 -2.8970865310
125 -3.1032263746 2.1237188379
126 1.9843274510 -3.1032263746
127 -1.7596735479 1.9843274510
128 -1.5570801664 -1.7596735479
129 -0.0685372267 -1.5570801664
130 0.7430205646 -0.0685372267
131 0.7475827523 0.7430205646
132 -1.8237555503 0.7475827523
133 -1.1445440615 -1.8237555503
134 -5.0485030121 -1.1445440615
135 3.2451350661 -5.0485030121
136 1.7563703220 3.2451350661
137 0.7183927653 1.7563703220
138 1.3310921106 0.7183927653
139 -4.1529455067 1.3310921106
140 2.2197663207 -4.1529455067
141 -1.8187351618 2.2197663207
142 1.2524432959 -1.8187351618
143 0.1668090060 1.2524432959
144 -3.0424300555 0.1668090060
145 -1.5166396589 -3.0424300555
146 2.1714305230 -1.5166396589
147 4.3670243756 2.1714305230
148 1.7720798506 4.3670243756
149 -2.3901354037 1.7720798506
150 0.2935683065 -2.3901354037
151 1.6548342970 0.2935683065
152 1.3335778694 1.6548342970
153 1.3414138557 1.3335778694
154 -0.3748554371 1.3414138557
155 0.6585386991 -0.3748554371
> 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/wessaorg/rcomp/tmp/74mzk1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/8kq7g1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/9b1hy1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/10rtni1352156658.ps",horizontal=F,onefile=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/wessaorg/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab
> load(file="/var/wessaorg/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/wessaorg/rcomp/tmp/11w82a1352156658.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/wessaorg/rcomp/tmp/12gwa91352156658.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/wessaorg/rcomp/tmp/136hw21352156658.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/wessaorg/rcomp/tmp/14tuz91352156658.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/wessaorg/rcomp/tmp/15e0gj1352156658.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/wessaorg/rcomp/tmp/16a3e01352156658.tab")
+ }
>
> try(system("convert tmp/1isgt1352156658.ps tmp/1isgt1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/2i4kp1352156658.ps tmp/2i4kp1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/3a6mh1352156658.ps tmp/3a6mh1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/4bs7v1352156658.ps tmp/4bs7v1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/570d81352156658.ps tmp/570d81352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/6n5qt1352156658.ps tmp/6n5qt1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/74mzk1352156658.ps tmp/74mzk1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/8kq7g1352156658.ps tmp/8kq7g1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/9b1hy1352156658.ps tmp/9b1hy1352156658.png",intern=TRUE))
character(0)
> try(system("convert tmp/10rtni1352156658.ps tmp/10rtni1352156658.png",intern=TRUE))
character(0)
>
>
> proc.time()
user system elapsed
7.720 0.891 8.609