R version 2.13.0 (2011-04-13)
Copyright (C) 2011 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: i486-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(0
+ ,65
+ ,146455
+ ,0
+ ,1
+ ,0
+ ,95556
+ ,0
+ ,114468
+ ,0
+ ,127
+ ,0
+ ,0
+ ,54
+ ,84944
+ ,0
+ ,4
+ ,0
+ ,54565
+ ,0
+ ,88594
+ ,0
+ ,90
+ ,0
+ ,0
+ ,58
+ ,113337
+ ,0
+ ,9
+ ,0
+ ,63016
+ ,0
+ ,74151
+ ,0
+ ,68
+ ,0
+ ,0
+ ,75
+ ,128655
+ ,0
+ ,2
+ ,0
+ ,79774
+ ,0
+ ,77921
+ ,0
+ ,111
+ ,0
+ ,0
+ ,41
+ ,74398
+ ,0
+ ,1
+ ,0
+ ,31258
+ ,0
+ ,53212
+ ,0
+ ,51
+ ,0
+ ,0
+ ,0
+ ,35523
+ ,0
+ ,2
+ ,0
+ ,52491
+ ,0
+ ,34956
+ ,0
+ ,33
+ ,0
+ ,1
+ ,111
+ ,293403
+ ,293403
+ ,0
+ ,0
+ ,91256
+ ,91256
+ ,149703
+ ,149703
+ ,123
+ ,123
+ ,0
+ ,1
+ ,32750
+ ,0
+ ,0
+ ,0
+ ,22807
+ ,0
+ ,6853
+ ,0
+ ,5
+ ,0
+ ,0
+ ,36
+ ,106539
+ ,0
+ ,5
+ ,0
+ ,77411
+ ,0
+ ,58907
+ ,0
+ ,63
+ ,0
+ ,0
+ ,60
+ ,130539
+ ,0
+ ,0
+ ,0
+ ,48821
+ ,0
+ ,67067
+ ,0
+ ,66
+ ,0
+ ,0
+ ,63
+ ,154991
+ ,0
+ ,0
+ ,0
+ ,52295
+ ,0
+ ,110563
+ ,0
+ ,99
+ ,0
+ ,1
+ ,71
+ ,126683
+ ,126683
+ ,7
+ ,7
+ ,63262
+ ,63262
+ ,58126
+ ,58126
+ ,72
+ ,72
+ ,1
+ ,38
+ ,100672
+ ,100672
+ ,6
+ ,6
+ ,50466
+ ,50466
+ ,57113
+ ,57113
+ ,55
+ ,55
+ ,1
+ ,76
+ ,179562
+ ,179562
+ ,3
+ ,3
+ ,62932
+ ,62932
+ ,77993
+ ,77993
+ ,116
+ ,116
+ ,1
+ ,61
+ ,125971
+ ,125971
+ ,4
+ ,4
+ ,38439
+ ,38439
+ ,68091
+ ,68091
+ ,71
+ ,71
+ ,0
+ ,125
+ ,234509
+ ,0
+ ,0
+ ,0
+ ,70817
+ ,0
+ ,124676
+ ,0
+ ,125
+ ,0
+ ,1
+ ,84
+ ,158980
+ ,158980
+ ,4
+ ,4
+ ,105965
+ ,105965
+ ,109522
+ ,109522
+ ,123
+ ,123
+ ,0
+ ,69
+ ,184217
+ ,0
+ ,3
+ ,0
+ ,73795
+ ,0
+ ,75865
+ ,0
+ ,74
+ ,0
+ ,1
+ ,77
+ ,107342
+ ,107342
+ ,0
+ ,0
+ ,82043
+ ,82043
+ ,79746
+ ,79746
+ ,116
+ ,116
+ ,1
+ ,95
+ ,141371
+ ,141371
+ ,5
+ ,5
+ ,74349
+ ,74349
+ ,77844
+ ,77844
+ ,117
+ ,117
+ ,1
+ ,78
+ ,154730
+ ,154730
+ ,0
+ ,0
+ ,82204
+ ,82204
+ ,98681
+ ,98681
+ ,98
+ ,98
+ ,1
+ ,76
+ ,264020
+ ,264020
+ ,1
+ ,1
+ ,55709
+ ,55709
+ ,105531
+ ,105531
+ ,101
+ ,101
+ ,1
+ ,40
+ ,90938
+ ,90938
+ ,3
+ ,3
+ ,37137
+ ,37137
+ ,51428
+ ,51428
+ ,43
+ ,43
+ ,0
+ ,81
+ ,101324
+ ,0
+ ,5
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,70
+ ,114397
+ ,114397
+ ,0
+ ,0
+ ,55064
+ ,55064
+ ,81278
+ ,81278
+ ,87
+ ,87
+ ,1
+ ,8
+ ,24188
+ ,24188
+ ,0
+ ,0
+ ,5950
+ ,5950
+ ,15049
+ ,15049
+ ,7
+ ,7
+ ,1
+ ,67
+ ,246209
+ ,246209
+ ,6
+ ,6
+ ,84607
+ ,84607
+ ,113935
+ ,113935
+ ,130
+ ,130
+ ,0
+ ,21
+ ,65029
+ ,0
+ ,5
+ ,0
+ ,32551
+ ,0
+ ,25109
+ ,0
+ ,21
+ ,0
+ ,0
+ ,30
+ ,98030
+ ,0
+ ,3
+ ,0
+ ,31701
+ ,0
+ ,45824
+ ,0
+ ,35
+ ,0
+ ,1
+ ,70
+ ,173587
+ ,173587
+ ,1
+ ,1
+ ,71170
+ ,71170
+ ,89644
+ ,89644
+ ,97
+ ,97
+ ,0
+ ,87
+ ,172684
+ ,0
+ ,5
+ ,0
+ ,101773
+ ,0
+ ,109011
+ ,0
+ ,103
+ ,0
+ ,0
+ ,87
+ ,191381
+ ,0
+ ,5
+ ,0
+ ,101653
+ ,0
+ ,134245
+ ,0
+ ,210
+ ,0
+ ,1
+ ,112
+ ,191276
+ ,191276
+ ,0
+ ,0
+ ,81493
+ ,81493
+ ,136692
+ ,136692
+ ,151
+ ,151
+ ,1
+ ,54
+ ,134043
+ ,134043
+ ,9
+ ,9
+ ,55901
+ ,55901
+ ,50741
+ ,50741
+ ,57
+ ,57
+ ,1
+ ,96
+ ,233406
+ ,233406
+ ,6
+ ,6
+ ,109104
+ ,109104
+ ,149510
+ ,149510
+ ,117
+ ,117
+ ,1
+ ,93
+ ,195304
+ ,195304
+ ,6
+ ,6
+ ,114425
+ ,114425
+ ,147888
+ ,147888
+ ,152
+ ,152
+ ,1
+ ,49
+ ,127619
+ ,127619
+ ,5
+ ,5
+ ,36311
+ ,36311
+ ,54987
+ ,54987
+ ,52
+ ,52
+ ,0
+ ,49
+ ,162810
+ ,0
+ ,6
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,116900
+ ,116900
+ ,1
+ ,1
+ ,28340
+ ,28340
+ ,63249
+ ,63249
+ ,58
+ ,58
+ ,0
+ ,108
+ ,142146
+ ,0
+ ,2
+ ,0
+ ,76013
+ ,0
+ ,82928
+ ,0
+ ,152
+ ,0
+ ,1
+ ,27
+ ,99246
+ ,99246
+ ,4
+ ,4
+ ,37361
+ ,37361
+ ,50000
+ ,50000
+ ,52
+ ,52
+ ,0
+ ,79
+ ,156833
+ ,0
+ ,1
+ ,0
+ ,48204
+ ,0
+ ,69455
+ ,0
+ ,85
+ ,0
+ ,1
+ ,49
+ ,175078
+ ,175078
+ ,4
+ ,4
+ ,76168
+ ,76168
+ ,84068
+ ,84068
+ ,95
+ ,95
+ ,0
+ ,64
+ ,130533
+ ,0
+ ,0
+ ,0
+ ,85168
+ ,0
+ ,76195
+ ,0
+ ,78
+ ,0
+ ,1
+ ,75
+ ,142339
+ ,142339
+ ,2
+ ,2
+ ,125410
+ ,125410
+ ,114634
+ ,114634
+ ,144
+ ,144
+ ,0
+ ,115
+ ,176789
+ ,0
+ ,0
+ ,0
+ ,123328
+ ,0
+ ,139357
+ ,0
+ ,149
+ ,0
+ ,1
+ ,92
+ ,181379
+ ,181379
+ ,7
+ ,7
+ ,83038
+ ,83038
+ ,110044
+ ,110044
+ ,101
+ ,101
+ ,0
+ ,106
+ ,228548
+ ,0
+ ,7
+ ,0
+ ,120087
+ ,0
+ ,155118
+ ,0
+ ,205
+ ,0
+ ,1
+ ,73
+ ,142141
+ ,142141
+ ,6
+ ,6
+ ,91939
+ ,91939
+ ,83061
+ ,83061
+ ,61
+ ,61
+ ,1
+ ,105
+ ,167845
+ ,167845
+ ,0
+ ,0
+ ,103646
+ ,103646
+ ,127122
+ ,127122
+ ,145
+ ,145
+ ,1
+ ,30
+ ,103012
+ ,103012
+ ,0
+ ,0
+ ,29467
+ ,29467
+ ,45653
+ ,45653
+ ,28
+ ,28
+ ,1
+ ,13
+ ,43287
+ ,43287
+ ,4
+ ,4
+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2
+ ,0
+ ,162365
+ ,0
+ ,159051
+ ,0
+ ,159
+ ,0
+ ,1
+ ,57
+ ,139144
+ ,139144
+ ,0
+ ,0
+ ,56530
+ ,56530
+ ,76506
+ ,76506
+ ,75
+ ,75
+ ,1
+ ,28
+ ,75812
+ ,75812
+ ,0
+ ,0
+ ,35606
+ ,35606
+ ,49145
+ ,49145
+ ,30
+ ,30
+ ,1
+ ,56
+ ,178218
+ ,178218
+ ,4
+ ,4
+ ,70111
+ ,70111
+ ,66398
+ ,66398
+ ,83
+ ,83
+ ,1
+ ,81
+ ,246834
+ ,246834
+ ,4
+ ,4
+ ,92046
+ ,92046
+ ,127546
+ ,127546
+ ,135
+ ,135
+ ,0
+ ,2
+ ,50999
+ ,0
+ ,8
+ ,0
+ ,63989
+ ,0
+ ,6802
+ ,0
+ ,8
+ ,0
+ ,0
+ ,88
+ ,223842
+ ,0
+ ,0
+ ,0
+ ,104911
+ ,0
+ ,99509
+ ,0
+ ,115
+ ,0
+ ,0
+ ,41
+ ,93577
+ ,0
+ ,4
+ ,0
+ ,43448
+ ,0
+ ,43106
+ ,0
+ ,60
+ ,0
+ ,1
+ ,83
+ ,155383
+ ,155383
+ ,0
+ ,0
+ ,60029
+ ,60029
+ ,108303
+ ,108303
+ ,99
+ ,99
+ ,1
+ ,55
+ ,111664
+ ,111664
+ ,1
+ ,1
+ ,38650
+ ,38650
+ ,64167
+ ,64167
+ ,98
+ ,98
+ ,1
+ ,3
+ ,75426
+ ,75426
+ ,0
+ ,0
+ ,47261
+ ,47261
+ ,8579
+ ,8579
+ ,36
+ ,36
+ ,1
+ ,54
+ ,243551
+ ,243551
+ ,9
+ ,9
+ ,73586
+ ,73586
+ ,97811
+ ,97811
+ ,93
+ ,93
+ ,1
+ ,89
+ ,136548
+ ,136548
+ ,0
+ ,0
+ ,83042
+ ,83042
+ ,84365
+ ,84365
+ ,158
+ ,158
+ ,1
+ ,41
+ ,173260
+ ,173260
+ ,3
+ ,3
+ ,37238
+ ,37238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0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,1
+ ,7
+ ,7199
+ ,7199
+ ,0
+ ,0
+ ,1644
+ ,1644
+ ,4245
+ ,4245
+ ,6
+ ,6
+ ,1
+ ,12
+ ,46660
+ ,46660
+ ,0
+ ,0
+ ,6179
+ ,6179
+ ,21509
+ ,21509
+ ,13
+ ,13
+ ,0
+ ,0
+ ,17547
+ ,0
+ ,0
+ ,0
+ ,3926
+ ,0
+ ,7670
+ ,0
+ ,3
+ ,0
+ ,1
+ ,37
+ ,73567
+ ,73567
+ ,0
+ ,0
+ ,23238
+ ,23238
+ ,10641
+ ,10641
+ ,18
+ ,18
+ ,0
+ ,0
+ ,969
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,0
+ ,39
+ ,101060
+ ,0
+ ,2
+ ,0
+ ,49288
+ ,0
+ ,41243
+ ,0
+ ,49
+ ,0)
+ ,dim=c(12
+ ,164)
+ ,dimnames=list(c('Pop'
+ ,'BloggedComputations'
+ ,'TotalTime'
+ ,'TotalTimep'
+ ,'Shared'
+ ,'Sharedp'
+ ,'Characters'
+ ,'Charactersp'
+ ,'Writing'
+ ,'Writingp'
+ ,'Hyperlinks'
+ ,'Hyperlinksp')
+ ,1:164))
> y <- array(NA,dim=c(12,164),dimnames=list(c('Pop','BloggedComputations','TotalTime','TotalTimep','Shared','Sharedp','Characters','Charactersp','Writing','Writingp','Hyperlinks','Hyperlinksp'),1:164))
> 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 = '2'
> library(lattice)
> library(lmtest)
Loading required package: zoo
> 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
BloggedComputations Pop TotalTime TotalTimep Shared Sharedp Characters
1 65 0 146455 0 1 0 95556
2 54 0 84944 0 4 0 54565
3 58 0 113337 0 9 0 63016
4 75 0 128655 0 2 0 79774
5 41 0 74398 0 1 0 31258
6 0 0 35523 0 2 0 52491
7 111 1 293403 293403 0 0 91256
8 1 0 32750 0 0 0 22807
9 36 0 106539 0 5 0 77411
10 60 0 130539 0 0 0 48821
11 63 0 154991 0 0 0 52295
12 71 1 126683 126683 7 7 63262
13 38 1 100672 100672 6 6 50466
14 76 1 179562 179562 3 3 62932
15 61 1 125971 125971 4 4 38439
16 125 0 234509 0 0 0 70817
17 84 1 158980 158980 4 4 105965
18 69 0 184217 0 3 0 73795
19 77 1 107342 107342 0 0 82043
20 95 1 141371 141371 5 5 74349
21 78 1 154730 154730 0 0 82204
22 76 1 264020 264020 1 1 55709
23 40 1 90938 90938 3 3 37137
24 81 0 101324 0 5 0 70780
25 102 0 130232 0 0 0 55027
26 70 0 137793 0 0 0 56699
27 75 0 161678 0 4 0 65911
28 93 1 151503 151503 0 0 56316
29 42 1 105324 105324 0 0 26982
30 95 1 175914 175914 0 0 54628
31 87 0 181853 0 3 0 96750
32 44 0 114928 0 4 0 53009
33 84 1 190410 190410 1 1 64664
34 28 1 61499 61499 4 4 36990
35 87 1 223004 223004 1 1 85224
36 71 1 167131 167131 0 0 37048
37 68 1 233482 233482 0 0 59635
38 50 1 121185 121185 2 2 42051
39 30 1 78776 78776 1 1 26998
40 86 1 188967 188967 2 2 63717
41 75 1 199512 199512 8 8 55071
42 46 1 102531 102531 5 5 40001
43 52 1 118958 118958 3 3 54506
44 31 0 68948 0 4 0 35838
45 30 0 93125 0 1 0 50838
46 70 0 277108 0 2 0 86997
47 20 0 78800 0 2 0 33032
48 84 0 157250 0 0 0 61704
49 81 1 210554 210554 6 6 117986
50 79 0 127324 0 3 0 56733
51 70 1 114397 114397 0 0 55064
52 8 1 24188 24188 0 0 5950
53 67 1 246209 246209 6 6 84607
54 21 0 65029 0 5 0 32551
55 30 0 98030 0 3 0 31701
56 70 1 173587 173587 1 1 71170
57 87 0 172684 0 5 0 101773
58 87 0 191381 0 5 0 101653
59 112 1 191276 191276 0 0 81493
60 54 1 134043 134043 9 9 55901
61 96 1 233406 233406 6 6 109104
62 93 1 195304 195304 6 6 114425
63 49 1 127619 127619 5 5 36311
64 49 0 162810 0 6 0 70027
65 38 0 129100 0 2 0 73713
66 64 1 108715 108715 0 0 40671
67 62 0 106469 0 3 0 89041
68 66 1 142069 142069 8 8 57231
69 98 0 143937 0 2 0 78792
70 97 1 84256 84256 5 5 59155
71 56 0 118807 0 11 0 55827
72 22 1 69471 69471 6 6 22618
73 51 0 122433 0 5 0 58425
74 56 1 131122 131122 1 1 65724
75 94 0 94763 0 0 0 56979
76 98 1 188780 188780 3 3 72369
77 76 0 191467 0 3 0 79194
78 57 0 105615 0 6 0 202316
79 75 0 89318 0 1 0 44970
80 48 0 107335 0 0 0 49319
81 48 0 98599 0 1 0 36252
82 109 0 260646 0 0 0 75741
83 27 1 131876 131876 5 5 38417
84 83 1 119291 119291 2 2 64102
85 49 1 80953 80953 0 0 56622
86 24 1 99768 99768 0 0 15430
87 43 1 84572 84572 5 5 72571
88 44 1 202373 202373 1 1 67271
89 49 1 166790 166790 0 0 43460
90 106 0 99946 0 1 0 99501
91 42 1 116900 116900 1 1 28340
92 108 0 142146 0 2 0 76013
93 27 1 99246 99246 4 4 37361
94 79 0 156833 0 1 0 48204
95 49 1 175078 175078 4 4 76168
96 64 0 130533 0 0 0 85168
97 75 1 142339 142339 2 2 125410
98 115 0 176789 0 0 0 123328
99 92 1 181379 181379 7 7 83038
100 106 0 228548 0 7 0 120087
101 73 1 142141 142141 6 6 91939
102 105 1 167845 167845 0 0 103646
103 30 1 103012 103012 0 0 29467
104 13 1 43287 43287 4 4 43750
105 69 1 125366 125366 4 4 34497
106 72 1 118372 118372 0 0 66477
107 80 0 135171 0 0 0 71181
108 106 0 175568 0 0 0 74482
109 28 0 74112 0 0 0 174949
110 70 0 88817 0 0 0 46765
111 51 1 164767 164767 4 4 90257
112 90 0 141933 0 0 0 51370
113 12 0 22938 0 0 0 1168
114 84 0 115199 0 0 0 51360
115 23 0 61857 0 4 0 25162
116 57 1 91185 91185 0 0 21067
117 84 0 213765 0 1 0 58233
118 4 1 21054 21054 0 0 855
119 56 0 167105 0 5 0 85903
120 18 0 31414 0 0 0 14116
121 86 1 178863 178863 1 1 57637
122 39 0 126681 0 7 0 94137
123 16 1 64320 64320 5 5 62147
124 18 1 67746 67746 2 2 62832
125 16 1 38214 38214 0 0 8773
126 42 1 90961 90961 1 1 63785
127 75 1 181510 181510 0 0 65196
128 30 0 116775 0 0 0 73087
129 104 0 223914 0 2 0 72631
130 121 0 185139 0 0 0 86281
131 106 0 242879 0 2 0 162365
132 57 1 139144 139144 0 0 56530
133 28 1 75812 75812 0 0 35606
134 56 1 178218 178218 4 4 70111
135 81 1 246834 246834 4 4 92046
136 2 0 50999 0 8 0 63989
137 88 0 223842 0 0 0 104911
138 41 0 93577 0 4 0 43448
139 83 1 155383 155383 0 0 60029
140 55 1 111664 111664 1 1 38650
141 3 1 75426 75426 0 0 47261
142 54 1 243551 243551 9 9 73586
143 89 1 136548 136548 0 0 83042
144 41 1 173260 173260 3 3 37238
145 94 0 185039 0 7 0 63958
146 101 0 67507 0 5 0 78956
147 70 0 139350 0 2 0 99518
148 111 0 172964 0 1 0 111436
149 0 1 0 0 9 9 0
150 4 1 14688 14688 0 0 6023
151 0 1 98 98 0 0 0
152 0 1 455 455 0 0 0
153 0 0 0 0 1 0 0
154 0 0 0 0 0 0 0
155 42 1 128066 128066 2 2 42564
156 97 0 176460 0 1 0 38885
157 0 1 0 0 0 0 0
158 0 1 203 203 0 0 0
159 7 1 7199 7199 0 0 1644
160 12 1 46660 46660 0 0 6179
161 0 0 17547 0 0 0 3926
162 37 1 73567 73567 0 0 23238
163 0 0 969 0 0 0 0
164 39 0 101060 0 2 0 49288
Charactersp Writing Writingp Hyperlinks Hyperlinksp
1 0 114468 0 127 0
2 0 88594 0 90 0
3 0 74151 0 68 0
4 0 77921 0 111 0
5 0 53212 0 51 0
6 0 34956 0 33 0
7 91256 149703 149703 123 123
8 0 6853 0 5 0
9 0 58907 0 63 0
10 0 67067 0 66 0
11 0 110563 0 99 0
12 63262 58126 58126 72 72
13 50466 57113 57113 55 55
14 62932 77993 77993 116 116
15 38439 68091 68091 71 71
16 0 124676 0 125 0
17 105965 109522 109522 123 123
18 0 75865 0 74 0
19 82043 79746 79746 116 116
20 74349 77844 77844 117 117
21 82204 98681 98681 98 98
22 55709 105531 105531 101 101
23 37137 51428 51428 43 43
24 0 65703 0 103 0
25 0 72562 0 107 0
26 0 81728 0 77 0
27 0 95580 0 87 0
28 56316 98278 98278 99 99
29 26982 46629 46629 46 46
30 54628 115189 115189 96 96
31 0 124865 0 92 0
32 0 59392 0 96 0
33 64664 127818 127818 96 96
34 36990 17821 17821 15 15
35 85224 154076 154076 147 147
36 37048 64881 64881 56 56
37 59635 136506 136506 81 81
38 42051 66524 66524 69 69
39 26998 45988 45988 34 34
40 63717 107445 107445 98 98
41 55071 102772 102772 82 82
42 40001 46657 46657 64 64
43 54506 97563 97563 61 61
44 0 36663 0 45 0
45 0 55369 0 37 0
46 0 77921 0 64 0
47 0 56968 0 21 0
48 0 77519 0 104 0
49 117986 129805 129805 126 126
50 0 72761 0 104 0
51 55064 81278 81278 87 87
52 5950 15049 15049 7 7
53 84607 113935 113935 130 130
54 0 25109 0 21 0
55 0 45824 0 35 0
56 71170 89644 89644 97 97
57 0 109011 0 103 0
58 0 134245 0 210 0
59 81493 136692 136692 151 151
60 55901 50741 50741 57 57
61 109104 149510 149510 117 117
62 114425 147888 147888 152 152
63 36311 54987 54987 52 52
64 0 74467 0 83 0
65 0 100033 0 87 0
66 40671 85505 85505 80 80
67 0 62426 0 88 0
68 57231 82932 82932 83 83
69 0 79169 0 140 0
70 59155 65469 65469 76 76
71 0 63572 0 70 0
72 22618 23824 23824 26 26
73 0 73831 0 66 0
74 65724 63551 63551 89 89
75 0 56756 0 100 0
76 72369 81399 81399 98 98
77 0 117881 0 109 0
78 0 70711 0 51 0
79 0 50495 0 82 0
80 0 53845 0 65 0
81 0 51390 0 46 0
82 0 104953 0 104 0
83 38417 65983 65983 36 36
84 64102 76839 76839 123 123
85 56622 55792 55792 59 59
86 15430 25155 25155 27 27
87 72571 55291 55291 84 84
88 67271 84279 84279 61 61
89 43460 99692 99692 46 46
90 0 59633 0 125 0
91 28340 63249 63249 58 58
92 0 82928 0 152 0
93 37361 50000 50000 52 52
94 0 69455 0 85 0
95 76168 84068 84068 95 95
96 0 76195 0 78 0
97 125410 114634 114634 144 144
98 0 139357 0 149 0
99 83038 110044 110044 101 101
100 0 155118 0 205 0
101 91939 83061 83061 61 61
102 103646 127122 127122 145 145
103 29467 45653 45653 28 28
104 43750 19630 19630 49 49
105 34497 67229 67229 68 68
106 66477 86060 86060 142 142
107 0 88003 0 82 0
108 0 95815 0 105 0
109 0 85499 0 52 0
110 0 27220 0 56 0
111 90257 109882 109882 81 81
112 0 72579 0 100 0
113 0 5841 0 11 0
114 0 68369 0 87 0
115 0 24610 0 31 0
116 21067 30995 30995 67 67
117 0 150662 0 150 0
118 855 6622 6622 4 4
119 0 93694 0 75 0
120 0 13155 0 39 0
121 57637 111908 111908 88 88
122 0 57550 0 67 0
123 62147 16356 16356 24 24
124 62832 40174 40174 58 58
125 8773 13983 13983 16 16
126 63785 52316 52316 49 49
127 65196 99585 99585 109 109
128 0 86271 0 124 0
129 0 131012 0 115 0
130 0 130274 0 128 0
131 0 159051 0 159 0
132 56530 76506 76506 75 75
133 35606 49145 49145 30 30
134 70111 66398 66398 83 83
135 92046 127546 127546 135 135
136 0 6802 0 8 0
137 0 99509 0 115 0
138 0 43106 0 60 0
139 60029 108303 108303 99 99
140 38650 64167 64167 98 98
141 47261 8579 8579 36 36
142 73586 97811 97811 93 93
143 83042 84365 84365 158 158
144 37238 10901 10901 16 16
145 0 91346 0 100 0
146 0 33660 0 49 0
147 0 93634 0 89 0
148 0 109348 0 153 0
149 0 0 0 0 0
150 6023 7953 7953 5 5
151 0 0 0 0 0
152 0 0 0 0 0
153 0 0 0 0 0
154 0 0 0 0 0
155 42564 63538 63538 80 80
156 0 108281 0 122 0
157 0 0 0 0 0
158 0 0 0 0 0
159 1644 4245 4245 6 6
160 6179 21509 21509 13 13
161 0 7670 0 3 0
162 23238 10641 10641 18 18
163 0 0 0 0 0
164 0 41243 0 49 0
> k <- length(x[1,])
> df <- as.data.frame(x)
> (mylm <- lm(df))
Call:
lm(formula = df)
Coefficients:
(Intercept) Pop TotalTime TotalTimep Shared Sharedp
5.231e+00 5.502e-02 2.738e-04 -2.074e-04 -1.541e+00 1.613e+00
Characters Charactersp Writing Writingp Hyperlinks Hyperlinksp
7.417e-05 -1.769e-04 -2.615e-04 4.975e-04 4.972e-01 -8.562e-02
> (mysum <- summary(mylm))
Call:
lm(formula = df)
Residuals:
Min 1Q Median 3Q Max
-51.717 -8.148 -1.558 8.604 63.572
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 5.231e+00 4.412e+00 1.186 0.23766
Pop 5.502e-02 5.759e+00 0.010 0.99239
TotalTime 2.738e-04 5.830e-05 4.697 5.86e-06 ***
TotalTimep -2.074e-04 7.845e-05 -2.644 0.00905 **
Shared -1.541e+00 7.089e-01 -2.173 0.03130 *
Sharedp 1.613e+00 9.765e-01 1.652 0.10070
Characters 7.417e-05 6.496e-05 1.142 0.25535
Charactersp -1.769e-04 1.384e-04 -1.278 0.20305
Writing -2.615e-04 1.274e-04 -2.053 0.04181 *
Writingp 4.975e-04 1.695e-04 2.935 0.00385 **
Hyperlinks 4.972e-01 7.637e-02 6.510 1.03e-09 ***
Hyperlinksp -8.562e-02 1.194e-01 -0.717 0.47427
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 15.05 on 152 degrees of freedom
Multiple R-squared: 0.7969, Adjusted R-squared: 0.7822
F-statistic: 54.21 on 11 and 152 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,] 0.069486989 1.389740e-01 9.305130e-01
[2,] 0.069204635 1.384093e-01 9.307954e-01
[3,] 0.026470082 5.294016e-02 9.735299e-01
[4,] 0.014910513 2.982103e-02 9.850895e-01
[5,] 0.061895263 1.237905e-01 9.381047e-01
[6,] 0.077435362 1.548707e-01 9.225646e-01
[7,] 0.047613496 9.522699e-02 9.523865e-01
[8,] 0.040281360 8.056272e-02 9.597186e-01
[9,] 0.022722254 4.544451e-02 9.772777e-01
[10,] 0.012373797 2.474759e-02 9.876262e-01
[11,] 0.007863344 1.572669e-02 9.921367e-01
[12,] 0.009491964 1.898393e-02 9.905080e-01
[13,] 0.005133635 1.026727e-02 9.948664e-01
[14,] 0.005806408 1.161282e-02 9.941936e-01
[15,] 0.003421985 6.843969e-03 9.965780e-01
[16,] 0.001953584 3.907168e-03 9.980464e-01
[17,] 0.045748204 9.149641e-02 9.542518e-01
[18,] 0.191325472 3.826509e-01 8.086745e-01
[19,] 0.167004486 3.340090e-01 8.329955e-01
[20,] 0.151231832 3.024637e-01 8.487682e-01
[21,] 0.249816098 4.996322e-01 7.501839e-01
[22,] 0.242444256 4.848885e-01 7.575557e-01
[23,] 0.221013916 4.420278e-01 7.789861e-01
[24,] 0.193193693 3.863874e-01 8.068063e-01
[25,] 0.167092333 3.341847e-01 8.329077e-01
[26,] 0.140398729 2.807975e-01 8.596013e-01
[27,] 0.111385229 2.227705e-01 8.886148e-01
[28,] 0.089810251 1.796205e-01 9.101897e-01
[29,] 0.068468801 1.369376e-01 9.315312e-01
[30,] 0.050767212 1.015344e-01 9.492328e-01
[31,] 0.037542788 7.508558e-02 9.624572e-01
[32,] 0.058115737 1.162315e-01 9.418843e-01
[33,] 0.043011574 8.602315e-02 9.569884e-01
[34,] 0.031515047 6.303009e-02 9.684850e-01
[35,] 0.028157564 5.631513e-02 9.718424e-01
[36,] 0.020520839 4.104168e-02 9.794792e-01
[37,] 0.014978763 2.995753e-02 9.850212e-01
[38,] 0.013244446 2.648889e-02 9.867556e-01
[39,] 0.035446548 7.089310e-02 9.645535e-01
[40,] 0.026510112 5.302022e-02 9.734899e-01
[41,] 0.020178716 4.035743e-02 9.798213e-01
[42,] 0.015030313 3.006063e-02 9.849697e-01
[43,] 0.013486736 2.697347e-02 9.865133e-01
[44,] 0.133867506 2.677350e-01 8.661325e-01
[45,] 0.113757370 2.275147e-01 8.862426e-01
[46,] 0.098940994 1.978820e-01 9.010590e-01
[47,] 0.081173109 1.623462e-01 9.188269e-01
[48,] 0.070846255 1.416925e-01 9.291537e-01
[49,] 0.055686813 1.113736e-01 9.443132e-01
[50,] 0.062425549 1.248511e-01 9.375745e-01
[51,] 0.086485245 1.729705e-01 9.135148e-01
[52,] 0.068608264 1.372165e-01 9.313917e-01
[53,] 0.062827999 1.256560e-01 9.371720e-01
[54,] 0.049660130 9.932026e-02 9.503399e-01
[55,] 0.044274284 8.854857e-02 9.557257e-01
[56,] 0.210790325 4.215806e-01 7.892097e-01
[57,] 0.192911086 3.858222e-01 8.070889e-01
[58,] 0.170430362 3.408607e-01 8.295696e-01
[59,] 0.141934386 2.838688e-01 8.580656e-01
[60,] 0.124143549 2.482871e-01 8.758565e-01
[61,] 0.190953289 3.819066e-01 8.090467e-01
[62,] 0.269276710 5.385534e-01 7.307233e-01
[63,] 0.237951053 4.759021e-01 7.620489e-01
[64,] 0.239759082 4.795182e-01 7.602409e-01
[65,] 0.249425607 4.988512e-01 7.505744e-01
[66,] 0.223880668 4.477613e-01 7.761193e-01
[67,] 0.193966024 3.879320e-01 8.060340e-01
[68,] 0.170720756 3.414415e-01 8.292792e-01
[69,] 0.163702466 3.274049e-01 8.362975e-01
[70,] 0.147227395 2.944548e-01 8.527726e-01
[71,] 0.126122352 2.522447e-01 8.738776e-01
[72,] 0.108396455 2.167929e-01 8.916035e-01
[73,] 0.102050634 2.041013e-01 8.979494e-01
[74,] 0.098431987 1.968640e-01 9.015680e-01
[75,] 0.084498279 1.689966e-01 9.155017e-01
[76,] 0.105423746 2.108475e-01 8.945763e-01
[77,] 0.091406668 1.828133e-01 9.085933e-01
[78,] 0.080734058 1.614681e-01 9.192659e-01
[79,] 0.079814269 1.596285e-01 9.201857e-01
[80,] 0.064704107 1.294082e-01 9.352959e-01
[81,] 0.073434023 1.468680e-01 9.265660e-01
[82,] 0.058679116 1.173582e-01 9.413209e-01
[83,] 0.054712324 1.094246e-01 9.452877e-01
[84,] 0.057508277 1.150166e-01 9.424917e-01
[85,] 0.062095740 1.241915e-01 9.379043e-01
[86,] 0.065894673 1.317893e-01 9.341053e-01
[87,] 0.102638566 2.052771e-01 8.973614e-01
[88,] 0.101480645 2.029613e-01 8.985194e-01
[89,] 0.082444768 1.648895e-01 9.175552e-01
[90,] 0.080289107 1.605782e-01 9.197109e-01
[91,] 0.085207775 1.704156e-01 9.147922e-01
[92,] 0.075779705 1.515594e-01 9.242203e-01
[93,] 0.073473909 1.469478e-01 9.265261e-01
[94,] 0.083605854 1.672117e-01 9.163941e-01
[95,] 0.076599426 1.531989e-01 9.234006e-01
[96,] 0.082699599 1.653992e-01 9.173004e-01
[97,] 0.072868875 1.457378e-01 9.271311e-01
[98,] 0.071817440 1.436349e-01 9.281826e-01
[99,] 0.057070464 1.141409e-01 9.429295e-01
[100,] 0.074457350 1.489147e-01 9.255426e-01
[101,] 0.058675350 1.173507e-01 9.413246e-01
[102,] 0.054544862 1.090897e-01 9.454551e-01
[103,] 0.070231612 1.404632e-01 9.297684e-01
[104,] 0.056559621 1.131192e-01 9.434404e-01
[105,] 0.057765306 1.155306e-01 9.422347e-01
[106,] 0.048559870 9.711974e-02 9.514401e-01
[107,] 0.045174232 9.034846e-02 9.548258e-01
[108,] 0.058825461 1.176509e-01 9.411745e-01
[109,] 0.046608036 9.321607e-02 9.533920e-01
[110,] 0.043108994 8.621799e-02 9.568910e-01
[111,] 0.031493849 6.298770e-02 9.685062e-01
[112,] 0.025340528 5.068106e-02 9.746595e-01
[113,] 0.017956061 3.591212e-02 9.820439e-01
[114,] 0.298791053 5.975821e-01 7.012089e-01
[115,] 0.282945443 5.658909e-01 7.170546e-01
[116,] 0.411977245 8.239545e-01 5.880228e-01
[117,] 0.416902828 8.338057e-01 5.830972e-01
[118,] 0.355600100 7.112002e-01 6.443999e-01
[119,] 0.297776448 5.955529e-01 7.022236e-01
[120,] 0.244146597 4.882932e-01 7.558534e-01
[121,] 0.207351645 4.147033e-01 7.926484e-01
[122,] 0.467095274 9.341905e-01 5.329047e-01
[123,] 0.470061477 9.401230e-01 5.299385e-01
[124,] 0.603598760 7.928025e-01 3.964012e-01
[125,] 0.782272392 4.354552e-01 2.177276e-01
[126,] 0.777341985 4.453160e-01 2.226580e-01
[127,] 0.855923990 2.881520e-01 1.440760e-01
[128,] 0.813114723 3.737706e-01 1.868853e-01
[129,] 0.735326171 5.293477e-01 2.646738e-01
[130,] 0.725566038 5.488679e-01 2.744340e-01
[131,] 0.985578513 2.884297e-02 1.442149e-02
[132,] 0.999976645 4.670920e-05 2.335460e-05
[133,] 0.999919811 1.603776e-04 8.018879e-05
[134,] 0.999311409 1.377182e-03 6.885912e-04
[135,] 0.999999946 1.076323e-07 5.381616e-08
> postscript(file="/var/wessaorg/rcomp/tmp/1txdt1321896929.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/2d54p1321896929.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/36ma41321896929.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/4erwf1321896929.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/5d60x1321896929.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 = 164
Frequency = 1
1 2 3 4 5 6
-19.0874702 6.0477986 16.5099663 -3.1052312 3.1787681 -23.0353580
7 8 9 10 11 12
9.6543997 -15.5844897 -12.3599115 0.1276986 -8.8571184 19.9463152
13 14 15 16 17 18
-5.3333362 -1.1077573 5.7199045 20.7583900 2.2848325 -4.4781482
19 20 21 22 23 24
6.4523842 21.0801542 7.2620396 -7.6387463 2.4403295 16.4502551
25 26 27 28 29 30
22.8042703 5.9223089 8.5121602 19.5009710 2.5560399 16.9505352
31 32 33 34 35 36
16.3324320 -22.6678740 2.9664141 11.7627520 -21.2724544 20.0631545
37 38 39 40 41 42
-12.2148240 -3.2544369 -2.6616564 8.8778557 3.5455550 0.3039651
43 44 45 46 47 48
-3.9320485 -2.3914751 -6.8770955 -25.9256546 -1.7198997 -0.3015848
49 50 51 52 53 54
-9.0702178 6.6397179 7.7867420 -4.7133628 -26.7667137 -0.6232750
55 56 57 58 59 60
-5.2213854 -0.6509440 11.9367761 -39.7727962 7.9792848 9.4738984
61 62 63 64 65 66
2.5539643 -11.3915746 4.2321125 -18.5547524 -22.0622472 2.5690941
67 68 69 70 71 72
-1.7938916 2.8519883 1.6910520 45.1062384 12.8655944 -2.3305007
73 74 75 76 77 78
2.1075500 -2.9404161 23.7186971 27.8537310 -6.2766172 10.2224071
79 80 81 82 83 84
15.9529402 -8.5159133 5.1905758 2.5183953 -13.8443110 7.4775119
85 86 87 88 89 90
6.7056347 -3.3740467 -8.4273126 -12.8803347 -5.3554106 21.0090586
91 92 93 94 95 96
-7.0060938 7.4045893 -14.5273020 4.6920303 -19.3135353 -2.1455175
97 98 99 100 101 102
-13.3183670 14.5766538 15.1580542 -21.2915921 22.5798219 9.5381209
103 104 105 106 107 108
-1.3968073 -15.7537399 14.7933157 -13.0693527 14.7213539 20.0222834
109 110 111 112 113 114
-13.9947865 16.2557540 -15.5121377 11.3560401 -3.5402876 18.0398207
115 116 117 118 119 120
-3.8495726 12.9341303 -17.7202891 -5.8051264 -6.4432565 -12.8298711
121 122 123 124 125 126
12.0585848 -15.3783986 -1.2710510 -18.8262682 -0.8071452 4.6407868
127 128 129 130 131 132
-4.0033605 -51.7169499 12.2353909 29.1032601 -12.1565667 -0.6408536
133 134 135 136 137 138
-2.6075777 -4.0352817 -17.1701763 -11.8156767 -17.4596686 -5.4729016
139 140 141 142 143 144
7.2588177 -9.2786044 -19.2807244 -21.9051609 -1.7597570 18.6614035
145 146 147 148 149 150
18.3113466 63.5715057 2.5489619 4.2098154 -5.9339633 -5.5773429
151 152 153 154 155 156
-5.2925407 -5.3162437 -3.6903205 -5.2310169 -15.4810825 9.7673164
157 158 159 160 161 162
-5.2860340 -5.2995122 -2.0663396 -6.1757865 -9.8128334 19.2968358
163 164
-5.4963657 -8.0548741
> postscript(file="/var/wessaorg/rcomp/tmp/6289v1321896929.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 = 164
Frequency = 1
lag(myerror, k = 1) myerror
0 -19.0874702 NA
1 6.0477986 -19.0874702
2 16.5099663 6.0477986
3 -3.1052312 16.5099663
4 3.1787681 -3.1052312
5 -23.0353580 3.1787681
6 9.6543997 -23.0353580
7 -15.5844897 9.6543997
8 -12.3599115 -15.5844897
9 0.1276986 -12.3599115
10 -8.8571184 0.1276986
11 19.9463152 -8.8571184
12 -5.3333362 19.9463152
13 -1.1077573 -5.3333362
14 5.7199045 -1.1077573
15 20.7583900 5.7199045
16 2.2848325 20.7583900
17 -4.4781482 2.2848325
18 6.4523842 -4.4781482
19 21.0801542 6.4523842
20 7.2620396 21.0801542
21 -7.6387463 7.2620396
22 2.4403295 -7.6387463
23 16.4502551 2.4403295
24 22.8042703 16.4502551
25 5.9223089 22.8042703
26 8.5121602 5.9223089
27 19.5009710 8.5121602
28 2.5560399 19.5009710
29 16.9505352 2.5560399
30 16.3324320 16.9505352
31 -22.6678740 16.3324320
32 2.9664141 -22.6678740
33 11.7627520 2.9664141
34 -21.2724544 11.7627520
35 20.0631545 -21.2724544
36 -12.2148240 20.0631545
37 -3.2544369 -12.2148240
38 -2.6616564 -3.2544369
39 8.8778557 -2.6616564
40 3.5455550 8.8778557
41 0.3039651 3.5455550
42 -3.9320485 0.3039651
43 -2.3914751 -3.9320485
44 -6.8770955 -2.3914751
45 -25.9256546 -6.8770955
46 -1.7198997 -25.9256546
47 -0.3015848 -1.7198997
48 -9.0702178 -0.3015848
49 6.6397179 -9.0702178
50 7.7867420 6.6397179
51 -4.7133628 7.7867420
52 -26.7667137 -4.7133628
53 -0.6232750 -26.7667137
54 -5.2213854 -0.6232750
55 -0.6509440 -5.2213854
56 11.9367761 -0.6509440
57 -39.7727962 11.9367761
58 7.9792848 -39.7727962
59 9.4738984 7.9792848
60 2.5539643 9.4738984
61 -11.3915746 2.5539643
62 4.2321125 -11.3915746
63 -18.5547524 4.2321125
64 -22.0622472 -18.5547524
65 2.5690941 -22.0622472
66 -1.7938916 2.5690941
67 2.8519883 -1.7938916
68 1.6910520 2.8519883
69 45.1062384 1.6910520
70 12.8655944 45.1062384
71 -2.3305007 12.8655944
72 2.1075500 -2.3305007
73 -2.9404161 2.1075500
74 23.7186971 -2.9404161
75 27.8537310 23.7186971
76 -6.2766172 27.8537310
77 10.2224071 -6.2766172
78 15.9529402 10.2224071
79 -8.5159133 15.9529402
80 5.1905758 -8.5159133
81 2.5183953 5.1905758
82 -13.8443110 2.5183953
83 7.4775119 -13.8443110
84 6.7056347 7.4775119
85 -3.3740467 6.7056347
86 -8.4273126 -3.3740467
87 -12.8803347 -8.4273126
88 -5.3554106 -12.8803347
89 21.0090586 -5.3554106
90 -7.0060938 21.0090586
91 7.4045893 -7.0060938
92 -14.5273020 7.4045893
93 4.6920303 -14.5273020
94 -19.3135353 4.6920303
95 -2.1455175 -19.3135353
96 -13.3183670 -2.1455175
97 14.5766538 -13.3183670
98 15.1580542 14.5766538
99 -21.2915921 15.1580542
100 22.5798219 -21.2915921
101 9.5381209 22.5798219
102 -1.3968073 9.5381209
103 -15.7537399 -1.3968073
104 14.7933157 -15.7537399
105 -13.0693527 14.7933157
106 14.7213539 -13.0693527
107 20.0222834 14.7213539
108 -13.9947865 20.0222834
109 16.2557540 -13.9947865
110 -15.5121377 16.2557540
111 11.3560401 -15.5121377
112 -3.5402876 11.3560401
113 18.0398207 -3.5402876
114 -3.8495726 18.0398207
115 12.9341303 -3.8495726
116 -17.7202891 12.9341303
117 -5.8051264 -17.7202891
118 -6.4432565 -5.8051264
119 -12.8298711 -6.4432565
120 12.0585848 -12.8298711
121 -15.3783986 12.0585848
122 -1.2710510 -15.3783986
123 -18.8262682 -1.2710510
124 -0.8071452 -18.8262682
125 4.6407868 -0.8071452
126 -4.0033605 4.6407868
127 -51.7169499 -4.0033605
128 12.2353909 -51.7169499
129 29.1032601 12.2353909
130 -12.1565667 29.1032601
131 -0.6408536 -12.1565667
132 -2.6075777 -0.6408536
133 -4.0352817 -2.6075777
134 -17.1701763 -4.0352817
135 -11.8156767 -17.1701763
136 -17.4596686 -11.8156767
137 -5.4729016 -17.4596686
138 7.2588177 -5.4729016
139 -9.2786044 7.2588177
140 -19.2807244 -9.2786044
141 -21.9051609 -19.2807244
142 -1.7597570 -21.9051609
143 18.6614035 -1.7597570
144 18.3113466 18.6614035
145 63.5715057 18.3113466
146 2.5489619 63.5715057
147 4.2098154 2.5489619
148 -5.9339633 4.2098154
149 -5.5773429 -5.9339633
150 -5.2925407 -5.5773429
151 -5.3162437 -5.2925407
152 -3.6903205 -5.3162437
153 -5.2310169 -3.6903205
154 -15.4810825 -5.2310169
155 9.7673164 -15.4810825
156 -5.2860340 9.7673164
157 -5.2995122 -5.2860340
158 -2.0663396 -5.2995122
159 -6.1757865 -2.0663396
160 -9.8128334 -6.1757865
161 19.2968358 -9.8128334
162 -5.4963657 19.2968358
163 -8.0548741 -5.4963657
164 NA -8.0548741
> dum1 <- dum[2:length(myerror),]
> dum1
lag(myerror, k = 1) myerror
[1,] 6.0477986 -19.0874702
[2,] 16.5099663 6.0477986
[3,] -3.1052312 16.5099663
[4,] 3.1787681 -3.1052312
[5,] -23.0353580 3.1787681
[6,] 9.6543997 -23.0353580
[7,] -15.5844897 9.6543997
[8,] -12.3599115 -15.5844897
[9,] 0.1276986 -12.3599115
[10,] -8.8571184 0.1276986
[11,] 19.9463152 -8.8571184
[12,] -5.3333362 19.9463152
[13,] -1.1077573 -5.3333362
[14,] 5.7199045 -1.1077573
[15,] 20.7583900 5.7199045
[16,] 2.2848325 20.7583900
[17,] -4.4781482 2.2848325
[18,] 6.4523842 -4.4781482
[19,] 21.0801542 6.4523842
[20,] 7.2620396 21.0801542
[21,] -7.6387463 7.2620396
[22,] 2.4403295 -7.6387463
[23,] 16.4502551 2.4403295
[24,] 22.8042703 16.4502551
[25,] 5.9223089 22.8042703
[26,] 8.5121602 5.9223089
[27,] 19.5009710 8.5121602
[28,] 2.5560399 19.5009710
[29,] 16.9505352 2.5560399
[30,] 16.3324320 16.9505352
[31,] -22.6678740 16.3324320
[32,] 2.9664141 -22.6678740
[33,] 11.7627520 2.9664141
[34,] -21.2724544 11.7627520
[35,] 20.0631545 -21.2724544
[36,] -12.2148240 20.0631545
[37,] -3.2544369 -12.2148240
[38,] -2.6616564 -3.2544369
[39,] 8.8778557 -2.6616564
[40,] 3.5455550 8.8778557
[41,] 0.3039651 3.5455550
[42,] -3.9320485 0.3039651
[43,] -2.3914751 -3.9320485
[44,] -6.8770955 -2.3914751
[45,] -25.9256546 -6.8770955
[46,] -1.7198997 -25.9256546
[47,] -0.3015848 -1.7198997
[48,] -9.0702178 -0.3015848
[49,] 6.6397179 -9.0702178
[50,] 7.7867420 6.6397179
[51,] -4.7133628 7.7867420
[52,] -26.7667137 -4.7133628
[53,] -0.6232750 -26.7667137
[54,] -5.2213854 -0.6232750
[55,] -0.6509440 -5.2213854
[56,] 11.9367761 -0.6509440
[57,] -39.7727962 11.9367761
[58,] 7.9792848 -39.7727962
[59,] 9.4738984 7.9792848
[60,] 2.5539643 9.4738984
[61,] -11.3915746 2.5539643
[62,] 4.2321125 -11.3915746
[63,] -18.5547524 4.2321125
[64,] -22.0622472 -18.5547524
[65,] 2.5690941 -22.0622472
[66,] -1.7938916 2.5690941
[67,] 2.8519883 -1.7938916
[68,] 1.6910520 2.8519883
[69,] 45.1062384 1.6910520
[70,] 12.8655944 45.1062384
[71,] -2.3305007 12.8655944
[72,] 2.1075500 -2.3305007
[73,] -2.9404161 2.1075500
[74,] 23.7186971 -2.9404161
[75,] 27.8537310 23.7186971
[76,] -6.2766172 27.8537310
[77,] 10.2224071 -6.2766172
[78,] 15.9529402 10.2224071
[79,] -8.5159133 15.9529402
[80,] 5.1905758 -8.5159133
[81,] 2.5183953 5.1905758
[82,] -13.8443110 2.5183953
[83,] 7.4775119 -13.8443110
[84,] 6.7056347 7.4775119
[85,] -3.3740467 6.7056347
[86,] -8.4273126 -3.3740467
[87,] -12.8803347 -8.4273126
[88,] -5.3554106 -12.8803347
[89,] 21.0090586 -5.3554106
[90,] -7.0060938 21.0090586
[91,] 7.4045893 -7.0060938
[92,] -14.5273020 7.4045893
[93,] 4.6920303 -14.5273020
[94,] -19.3135353 4.6920303
[95,] -2.1455175 -19.3135353
[96,] -13.3183670 -2.1455175
[97,] 14.5766538 -13.3183670
[98,] 15.1580542 14.5766538
[99,] -21.2915921 15.1580542
[100,] 22.5798219 -21.2915921
[101,] 9.5381209 22.5798219
[102,] -1.3968073 9.5381209
[103,] -15.7537399 -1.3968073
[104,] 14.7933157 -15.7537399
[105,] -13.0693527 14.7933157
[106,] 14.7213539 -13.0693527
[107,] 20.0222834 14.7213539
[108,] -13.9947865 20.0222834
[109,] 16.2557540 -13.9947865
[110,] -15.5121377 16.2557540
[111,] 11.3560401 -15.5121377
[112,] -3.5402876 11.3560401
[113,] 18.0398207 -3.5402876
[114,] -3.8495726 18.0398207
[115,] 12.9341303 -3.8495726
[116,] -17.7202891 12.9341303
[117,] -5.8051264 -17.7202891
[118,] -6.4432565 -5.8051264
[119,] -12.8298711 -6.4432565
[120,] 12.0585848 -12.8298711
[121,] -15.3783986 12.0585848
[122,] -1.2710510 -15.3783986
[123,] -18.8262682 -1.2710510
[124,] -0.8071452 -18.8262682
[125,] 4.6407868 -0.8071452
[126,] -4.0033605 4.6407868
[127,] -51.7169499 -4.0033605
[128,] 12.2353909 -51.7169499
[129,] 29.1032601 12.2353909
[130,] -12.1565667 29.1032601
[131,] -0.6408536 -12.1565667
[132,] -2.6075777 -0.6408536
[133,] -4.0352817 -2.6075777
[134,] -17.1701763 -4.0352817
[135,] -11.8156767 -17.1701763
[136,] -17.4596686 -11.8156767
[137,] -5.4729016 -17.4596686
[138,] 7.2588177 -5.4729016
[139,] -9.2786044 7.2588177
[140,] -19.2807244 -9.2786044
[141,] -21.9051609 -19.2807244
[142,] -1.7597570 -21.9051609
[143,] 18.6614035 -1.7597570
[144,] 18.3113466 18.6614035
[145,] 63.5715057 18.3113466
[146,] 2.5489619 63.5715057
[147,] 4.2098154 2.5489619
[148,] -5.9339633 4.2098154
[149,] -5.5773429 -5.9339633
[150,] -5.2925407 -5.5773429
[151,] -5.3162437 -5.2925407
[152,] -3.6903205 -5.3162437
[153,] -5.2310169 -3.6903205
[154,] -15.4810825 -5.2310169
[155,] 9.7673164 -15.4810825
[156,] -5.2860340 9.7673164
[157,] -5.2995122 -5.2860340
[158,] -2.0663396 -5.2995122
[159,] -6.1757865 -2.0663396
[160,] -9.8128334 -6.1757865
[161,] 19.2968358 -9.8128334
[162,] -5.4963657 19.2968358
[163,] -8.0548741 -5.4963657
> z <- as.data.frame(dum1)
> z
lag(myerror, k = 1) myerror
1 6.0477986 -19.0874702
2 16.5099663 6.0477986
3 -3.1052312 16.5099663
4 3.1787681 -3.1052312
5 -23.0353580 3.1787681
6 9.6543997 -23.0353580
7 -15.5844897 9.6543997
8 -12.3599115 -15.5844897
9 0.1276986 -12.3599115
10 -8.8571184 0.1276986
11 19.9463152 -8.8571184
12 -5.3333362 19.9463152
13 -1.1077573 -5.3333362
14 5.7199045 -1.1077573
15 20.7583900 5.7199045
16 2.2848325 20.7583900
17 -4.4781482 2.2848325
18 6.4523842 -4.4781482
19 21.0801542 6.4523842
20 7.2620396 21.0801542
21 -7.6387463 7.2620396
22 2.4403295 -7.6387463
23 16.4502551 2.4403295
24 22.8042703 16.4502551
25 5.9223089 22.8042703
26 8.5121602 5.9223089
27 19.5009710 8.5121602
28 2.5560399 19.5009710
29 16.9505352 2.5560399
30 16.3324320 16.9505352
31 -22.6678740 16.3324320
32 2.9664141 -22.6678740
33 11.7627520 2.9664141
34 -21.2724544 11.7627520
35 20.0631545 -21.2724544
36 -12.2148240 20.0631545
37 -3.2544369 -12.2148240
38 -2.6616564 -3.2544369
39 8.8778557 -2.6616564
40 3.5455550 8.8778557
41 0.3039651 3.5455550
42 -3.9320485 0.3039651
43 -2.3914751 -3.9320485
44 -6.8770955 -2.3914751
45 -25.9256546 -6.8770955
46 -1.7198997 -25.9256546
47 -0.3015848 -1.7198997
48 -9.0702178 -0.3015848
49 6.6397179 -9.0702178
50 7.7867420 6.6397179
51 -4.7133628 7.7867420
52 -26.7667137 -4.7133628
53 -0.6232750 -26.7667137
54 -5.2213854 -0.6232750
55 -0.6509440 -5.2213854
56 11.9367761 -0.6509440
57 -39.7727962 11.9367761
58 7.9792848 -39.7727962
59 9.4738984 7.9792848
60 2.5539643 9.4738984
61 -11.3915746 2.5539643
62 4.2321125 -11.3915746
63 -18.5547524 4.2321125
64 -22.0622472 -18.5547524
65 2.5690941 -22.0622472
66 -1.7938916 2.5690941
67 2.8519883 -1.7938916
68 1.6910520 2.8519883
69 45.1062384 1.6910520
70 12.8655944 45.1062384
71 -2.3305007 12.8655944
72 2.1075500 -2.3305007
73 -2.9404161 2.1075500
74 23.7186971 -2.9404161
75 27.8537310 23.7186971
76 -6.2766172 27.8537310
77 10.2224071 -6.2766172
78 15.9529402 10.2224071
79 -8.5159133 15.9529402
80 5.1905758 -8.5159133
81 2.5183953 5.1905758
82 -13.8443110 2.5183953
83 7.4775119 -13.8443110
84 6.7056347 7.4775119
85 -3.3740467 6.7056347
86 -8.4273126 -3.3740467
87 -12.8803347 -8.4273126
88 -5.3554106 -12.8803347
89 21.0090586 -5.3554106
90 -7.0060938 21.0090586
91 7.4045893 -7.0060938
92 -14.5273020 7.4045893
93 4.6920303 -14.5273020
94 -19.3135353 4.6920303
95 -2.1455175 -19.3135353
96 -13.3183670 -2.1455175
97 14.5766538 -13.3183670
98 15.1580542 14.5766538
99 -21.2915921 15.1580542
100 22.5798219 -21.2915921
101 9.5381209 22.5798219
102 -1.3968073 9.5381209
103 -15.7537399 -1.3968073
104 14.7933157 -15.7537399
105 -13.0693527 14.7933157
106 14.7213539 -13.0693527
107 20.0222834 14.7213539
108 -13.9947865 20.0222834
109 16.2557540 -13.9947865
110 -15.5121377 16.2557540
111 11.3560401 -15.5121377
112 -3.5402876 11.3560401
113 18.0398207 -3.5402876
114 -3.8495726 18.0398207
115 12.9341303 -3.8495726
116 -17.7202891 12.9341303
117 -5.8051264 -17.7202891
118 -6.4432565 -5.8051264
119 -12.8298711 -6.4432565
120 12.0585848 -12.8298711
121 -15.3783986 12.0585848
122 -1.2710510 -15.3783986
123 -18.8262682 -1.2710510
124 -0.8071452 -18.8262682
125 4.6407868 -0.8071452
126 -4.0033605 4.6407868
127 -51.7169499 -4.0033605
128 12.2353909 -51.7169499
129 29.1032601 12.2353909
130 -12.1565667 29.1032601
131 -0.6408536 -12.1565667
132 -2.6075777 -0.6408536
133 -4.0352817 -2.6075777
134 -17.1701763 -4.0352817
135 -11.8156767 -17.1701763
136 -17.4596686 -11.8156767
137 -5.4729016 -17.4596686
138 7.2588177 -5.4729016
139 -9.2786044 7.2588177
140 -19.2807244 -9.2786044
141 -21.9051609 -19.2807244
142 -1.7597570 -21.9051609
143 18.6614035 -1.7597570
144 18.3113466 18.6614035
145 63.5715057 18.3113466
146 2.5489619 63.5715057
147 4.2098154 2.5489619
148 -5.9339633 4.2098154
149 -5.5773429 -5.9339633
150 -5.2925407 -5.5773429
151 -5.3162437 -5.2925407
152 -3.6903205 -5.3162437
153 -5.2310169 -3.6903205
154 -15.4810825 -5.2310169
155 9.7673164 -15.4810825
156 -5.2860340 9.7673164
157 -5.2995122 -5.2860340
158 -2.0663396 -5.2995122
159 -6.1757865 -2.0663396
160 -9.8128334 -6.1757865
161 19.2968358 -9.8128334
162 -5.4963657 19.2968358
163 -8.0548741 -5.4963657
> 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/7dr681321896929.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/8zaxt1321896929.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/98bnl1321896929.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/10grbm1321896929.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/11elrs1321896929.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/12dn7q1321896929.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/13u8nw1321896929.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/14gxsu1321896929.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/15oy3o1321896929.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/1690hi1321896929.tab")
+ }
>
> try(system("convert tmp/1txdt1321896929.ps tmp/1txdt1321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/2d54p1321896929.ps tmp/2d54p1321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/36ma41321896929.ps tmp/36ma41321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/4erwf1321896929.ps tmp/4erwf1321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/5d60x1321896929.ps tmp/5d60x1321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/6289v1321896929.ps tmp/6289v1321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/7dr681321896929.ps tmp/7dr681321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/8zaxt1321896929.ps tmp/8zaxt1321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/98bnl1321896929.ps tmp/98bnl1321896929.png",intern=TRUE))
character(0)
> try(system("convert tmp/10grbm1321896929.ps tmp/10grbm1321896929.png",intern=TRUE))
character(0)
>
>
> proc.time()
user system elapsed
5.865 0.580 6.460