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(41
+ ,1966
+ ,4
+ ,3
+ ,39
+ ,1966
+ ,2
+ ,1
+ ,50
+ ,1966
+ ,3
+ ,2
+ ,40
+ ,1966
+ ,6
+ ,3
+ ,43
+ ,1966
+ ,5
+ ,1
+ ,38
+ ,1966
+ ,1
+ ,2
+ ,44
+ ,1966
+ ,3
+ ,3
+ ,35
+ ,1966
+ ,5
+ ,3
+ ,39
+ ,1966
+ ,2
+ ,2
+ ,35
+ ,1966
+ ,3
+ ,1
+ ,29
+ ,1966
+ ,6
+ ,2
+ ,49
+ ,1966
+ ,2
+ ,1
+ ,50
+ ,1967
+ ,5
+ ,2
+ ,59
+ ,1967
+ ,3
+ ,1
+ ,63
+ ,1967
+ ,1
+ ,3
+ ,32
+ ,1967
+ ,2
+ ,2
+ ,39
+ ,1967
+ ,4
+ ,1
+ ,47
+ ,1967
+ ,3
+ ,2
+ ,53
+ ,1967
+ ,4
+ ,3
+ ,60
+ ,1967
+ ,6
+ ,2
+ ,57
+ ,1967
+ ,2
+ ,1
+ ,52
+ ,1967
+ ,1
+ ,2
+ ,70
+ ,1967
+ ,4
+ ,3
+ ,90
+ ,1967
+ ,2
+ ,2
+ ,74
+ ,1968
+ ,1
+ ,3
+ ,62
+ ,1968
+ ,2
+ ,3
+ ,55
+ ,1968
+ ,5
+ ,2
+ ,84
+ ,1968
+ ,3
+ ,1
+ ,94
+ ,1968
+ ,6
+ ,2
+ ,70
+ ,1968
+ ,3
+ ,1
+ ,108
+ ,1968
+ ,1
+ ,2
+ ,139
+ ,1968
+ ,3
+ ,3
+ ,120
+ ,1968
+ ,5
+ ,2
+ ,97
+ ,1968
+ ,2
+ ,1
+ ,126
+ ,1968
+ ,3
+ ,1
+ ,149
+ ,1968
+ ,5
+ ,1
+ ,158
+ ,1969
+ ,6
+ ,2
+ ,124
+ ,1969
+ ,2
+ ,1
+ ,140
+ ,1969
+ ,1
+ ,2
+ ,109
+ ,1969
+ ,6
+ ,3
+ ,114
+ ,1969
+ ,4
+ ,3
+ ,77
+ ,1969
+ ,3
+ ,2
+ ,120
+ ,1969
+ ,2
+ ,3
+ ,133
+ ,1969
+ ,1
+ ,1
+ ,110
+ ,1969
+ ,2
+ ,3
+ ,92
+ ,1969
+ ,3
+ ,1
+ ,97
+ ,1969
+ ,5
+ ,2
+ ,78
+ ,1969
+ ,4
+ ,3
+ ,99
+ ,1970
+ ,6
+ ,2
+ ,107
+ ,1970
+ ,5
+ ,1
+ ,112
+ ,1970
+ ,2
+ ,2
+ ,90
+ ,1970
+ ,3
+ ,3
+ ,98
+ ,1970
+ ,1
+ ,2
+ ,125
+ ,1970
+ ,3
+ ,1
+ ,155
+ ,1970
+ ,2
+ ,2
+ ,190
+ ,1970
+ ,4
+ ,3
+ ,236
+ ,1970
+ ,5
+ ,2
+ ,189
+ ,1970
+ ,2
+ ,3
+ ,174
+ ,1970
+ ,3
+ ,2
+ ,178
+ ,1970
+ ,6
+ ,1
+ ,136
+ ,1971
+ ,4
+ ,2
+ ,161
+ ,1971
+ ,1
+ ,3
+ ,171
+ ,1971
+ ,3
+ ,2
+ ,149
+ ,1971
+ ,1
+ ,3
+ ,184
+ ,1971
+ ,2
+ ,1
+ ,155
+ ,1971
+ ,4
+ ,2
+ ,276
+ ,1971
+ ,2
+ ,3
+ ,224
+ ,1971
+ ,3
+ ,2
+ ,213
+ ,1971
+ ,4
+ ,1
+ ,279
+ ,1971
+ ,3
+ ,2
+ ,268
+ ,1971
+ ,5
+ ,3
+ ,287
+ ,1971
+ ,6
+ ,1
+ ,238
+ ,1972
+ ,6
+ ,2
+ ,213
+ ,1972
+ ,6
+ ,3
+ ,257
+ ,1972
+ ,3
+ ,1
+ ,293
+ ,1972
+ ,1
+ ,3
+ ,212
+ ,1972
+ ,1
+ ,2
+ ,246
+ ,1972
+ ,2
+ ,3
+ ,353
+ ,1972
+ ,4
+ ,2
+ ,339
+ ,1972
+ ,3
+ ,1
+ ,308
+ ,1972
+ ,2
+ ,2
+ ,247
+ ,1972
+ ,1
+ ,3
+ ,257
+ ,1972
+ ,2
+ ,2
+ ,322
+ ,1972
+ ,4
+ ,2
+ ,298
+ ,1973
+ ,4
+ ,3
+ ,273
+ ,1973
+ ,3
+ ,2
+ ,312
+ ,1973
+ ,5
+ ,3
+ ,249
+ ,1973
+ ,6
+ ,1
+ ,286
+ ,1973
+ ,2
+ ,2
+ ,279
+ ,1973
+ ,3
+ ,3
+ ,309
+ ,1973
+ ,4
+ ,2
+ ,401
+ ,1973
+ ,2
+ ,1
+ ,309
+ ,1973
+ ,3
+ ,2
+ ,328
+ ,1973
+ ,1
+ ,3
+ ,353
+ ,1973
+ ,2
+ ,2
+ ,354
+ ,1973
+ ,5
+ ,1
+ ,327
+ ,1974
+ ,3
+ ,2
+ ,324
+ ,1974
+ ,6
+ ,3
+ ,285
+ ,1974
+ ,3
+ ,2
+ ,243
+ ,1974
+ ,2
+ ,1
+ ,241
+ ,1974
+ ,1
+ ,2
+ ,287
+ ,1974
+ ,4
+ ,3
+ ,355
+ ,1974
+ ,2
+ ,2
+ ,460
+ ,1974
+ ,4
+ ,2
+ ,364
+ ,1974
+ ,6
+ ,2
+ ,487
+ ,1974
+ ,3
+ ,2
+ ,452
+ ,1974
+ ,5
+ ,1
+ ,391
+ ,1974
+ ,1
+ ,2
+ ,500
+ ,1975
+ ,3
+ ,3
+ ,451
+ ,1975
+ ,2
+ ,2
+ ,375
+ ,1975
+ ,4
+ ,3
+ ,372
+ ,1975
+ ,2
+ ,1
+ ,302
+ ,1975
+ ,3
+ ,3
+ ,316
+ ,1975
+ ,1
+ ,3
+ ,398
+ ,1975
+ ,4
+ ,3
+ ,394
+ ,1975
+ ,6
+ ,2
+ ,431
+ ,1975
+ ,2
+ ,1
+ ,431
+ ,1975
+ ,5
+ ,2)
+ ,dim=c(4
+ ,118)
+ ,dimnames=list(c('Kilometers'
+ ,'Bouwjaar'
+ ,'Model'
+ ,'Kleur')
+ ,1:118))
> y <- array(NA,dim=c(4,118),dimnames=list(c('Kilometers','Bouwjaar','Model','Kleur'),1:118))
> 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 = '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
> 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
Kilometers Bouwjaar Model Kleur
1 41 1966 4 3
2 39 1966 2 1
3 50 1966 3 2
4 40 1966 6 3
5 43 1966 5 1
6 38 1966 1 2
7 44 1966 3 3
8 35 1966 5 3
9 39 1966 2 2
10 35 1966 3 1
11 29 1966 6 2
12 49 1966 2 1
13 50 1967 5 2
14 59 1967 3 1
15 63 1967 1 3
16 32 1967 2 2
17 39 1967 4 1
18 47 1967 3 2
19 53 1967 4 3
20 60 1967 6 2
21 57 1967 2 1
22 52 1967 1 2
23 70 1967 4 3
24 90 1967 2 2
25 74 1968 1 3
26 62 1968 2 3
27 55 1968 5 2
28 84 1968 3 1
29 94 1968 6 2
30 70 1968 3 1
31 108 1968 1 2
32 139 1968 3 3
33 120 1968 5 2
34 97 1968 2 1
35 126 1968 3 1
36 149 1968 5 1
37 158 1969 6 2
38 124 1969 2 1
39 140 1969 1 2
40 109 1969 6 3
41 114 1969 4 3
42 77 1969 3 2
43 120 1969 2 3
44 133 1969 1 1
45 110 1969 2 3
46 92 1969 3 1
47 97 1969 5 2
48 78 1969 4 3
49 99 1970 6 2
50 107 1970 5 1
51 112 1970 2 2
52 90 1970 3 3
53 98 1970 1 2
54 125 1970 3 1
55 155 1970 2 2
56 190 1970 4 3
57 236 1970 5 2
58 189 1970 2 3
59 174 1970 3 2
60 178 1970 6 1
61 136 1971 4 2
62 161 1971 1 3
63 171 1971 3 2
64 149 1971 1 3
65 184 1971 2 1
66 155 1971 4 2
67 276 1971 2 3
68 224 1971 3 2
69 213 1971 4 1
70 279 1971 3 2
71 268 1971 5 3
72 287 1971 6 1
73 238 1972 6 2
74 213 1972 6 3
75 257 1972 3 1
76 293 1972 1 3
77 212 1972 1 2
78 246 1972 2 3
79 353 1972 4 2
80 339 1972 3 1
81 308 1972 2 2
82 247 1972 1 3
83 257 1972 2 2
84 322 1972 4 2
85 298 1973 4 3
86 273 1973 3 2
87 312 1973 5 3
88 249 1973 6 1
89 286 1973 2 2
90 279 1973 3 3
91 309 1973 4 2
92 401 1973 2 1
93 309 1973 3 2
94 328 1973 1 3
95 353 1973 2 2
96 354 1973 5 1
97 327 1974 3 2
98 324 1974 6 3
99 285 1974 3 2
100 243 1974 2 1
101 241 1974 1 2
102 287 1974 4 3
103 355 1974 2 2
104 460 1974 4 2
105 364 1974 6 2
106 487 1974 3 2
107 452 1974 5 1
108 391 1974 1 2
109 500 1975 3 3
110 451 1975 2 2
111 375 1975 4 3
112 372 1975 2 1
113 302 1975 3 3
114 316 1975 1 3
115 398 1975 4 3
116 394 1975 6 2
117 431 1975 2 1
118 431 1975 5 2
> k <- length(x[1,])
> df <- as.data.frame(x)
> (mylm <- lm(df))
Call:
lm(formula = df)
Coefficients:
(Intercept) Bouwjaar Model Kleur
-82371.921 41.907 2.756 -7.197
> (mysum <- summary(mylm))
Call:
lm(formula = df)
Residuals:
Min 1Q Median 3Q Max
-107.325 -27.189 -1.711 32.443 141.116
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) -82371.921 3077.104 -26.769 <2e-16 ***
Bouwjaar 41.907 1.562 26.827 <2e-16 ***
Model 2.756 2.786 0.989 0.325
Kleur -7.197 5.899 -1.220 0.225
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 47.92 on 114 degrees of freedom
Multiple R-squared: 0.8635, Adjusted R-squared: 0.8599
F-statistic: 240.4 on 3 and 114 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,] 2.204672e-03 4.409344e-03 0.9977953
[2,] 4.333911e-04 8.667821e-04 0.9995666
[3,] 4.940244e-05 9.880489e-05 0.9999506
[4,] 9.015985e-06 1.803197e-05 0.9999910
[5,] 3.543834e-06 7.087667e-06 0.9999965
[6,] 9.808138e-07 1.961628e-06 0.9999990
[7,] 1.168891e-07 2.337782e-07 0.9999999
[8,] 1.759890e-08 3.519779e-08 1.0000000
[9,] 2.230010e-09 4.460020e-09 1.0000000
[10,] 5.300151e-08 1.060030e-07 0.9999999
[11,] 1.410134e-08 2.820268e-08 1.0000000
[12,] 2.324850e-09 4.649699e-09 1.0000000
[13,] 4.205597e-10 8.411194e-10 1.0000000
[14,] 2.213562e-10 4.427125e-10 1.0000000
[15,] 4.608021e-11 9.216042e-11 1.0000000
[16,] 7.362652e-12 1.472530e-11 1.0000000
[17,] 8.745822e-12 1.749164e-11 1.0000000
[18,] 4.511055e-10 9.022110e-10 1.0000000
[19,] 9.913692e-11 1.982738e-10 1.0000000
[20,] 3.188853e-11 6.377706e-11 1.0000000
[21,] 9.474367e-12 1.894873e-11 1.0000000
[22,] 6.200344e-12 1.240069e-11 1.0000000
[23,] 1.109734e-11 2.219467e-11 1.0000000
[24,] 2.590486e-12 5.180973e-12 1.0000000
[25,] 1.166788e-11 2.333575e-11 1.0000000
[26,] 2.844151e-09 5.688301e-09 1.0000000
[27,] 7.353772e-09 1.470754e-08 1.0000000
[28,] 3.143040e-09 6.286079e-09 1.0000000
[29,] 8.219978e-09 1.643996e-08 1.0000000
[30,] 9.660535e-08 1.932107e-07 0.9999999
[31,] 8.565191e-08 1.713038e-07 0.9999999
[32,] 3.370413e-08 6.740826e-08 1.0000000
[33,] 1.752059e-08 3.504118e-08 1.0000000
[34,] 9.749589e-09 1.949918e-08 1.0000000
[35,] 4.093170e-09 8.186340e-09 1.0000000
[36,] 1.071497e-08 2.142995e-08 1.0000000
[37,] 4.361384e-09 8.722768e-09 1.0000000
[38,] 1.900457e-09 3.800914e-09 1.0000000
[39,] 7.678451e-10 1.535690e-09 1.0000000
[40,] 6.994112e-10 1.398822e-09 1.0000000
[41,] 4.220157e-10 8.440314e-10 1.0000000
[42,] 5.049735e-10 1.009947e-09 1.0000000
[43,] 1.083927e-09 2.167854e-09 1.0000000
[44,] 1.361481e-09 2.722962e-09 1.0000000
[45,] 9.375186e-10 1.875037e-09 1.0000000
[46,] 1.583160e-09 3.166320e-09 1.0000000
[47,] 1.728462e-09 3.456924e-09 1.0000000
[48,] 1.020898e-09 2.041797e-09 1.0000000
[49,] 7.312443e-10 1.462489e-09 1.0000000
[50,] 3.694038e-09 7.388076e-09 1.0000000
[51,] 2.896125e-07 5.792250e-07 0.9999997
[52,] 4.472446e-07 8.944893e-07 0.9999996
[53,] 3.244154e-07 6.488308e-07 0.9999997
[54,] 2.328527e-07 4.657055e-07 0.9999998
[55,] 3.814727e-07 7.629455e-07 0.9999996
[56,] 2.186896e-07 4.373793e-07 0.9999998
[57,] 1.458789e-07 2.917578e-07 0.9999999
[58,] 1.136829e-07 2.273657e-07 0.9999999
[59,] 8.977035e-08 1.795407e-07 0.9999999
[60,] 1.120824e-07 2.241649e-07 0.9999999
[61,] 3.535874e-06 7.071747e-06 0.9999965
[62,] 3.747758e-06 7.495517e-06 0.9999963
[63,] 3.582981e-06 7.165962e-06 0.9999964
[64,] 2.308436e-05 4.616872e-05 0.9999769
[65,] 5.792444e-05 1.158489e-04 0.9999421
[66,] 1.524622e-04 3.049245e-04 0.9998475
[67,] 1.113494e-04 2.226989e-04 0.9998887
[68,] 1.022304e-04 2.044608e-04 0.9998978
[69,] 8.440564e-05 1.688113e-04 0.9999156
[70,] 1.364941e-04 2.729882e-04 0.9998635
[71,] 1.195635e-04 2.391271e-04 0.9998804
[72,] 7.584013e-05 1.516803e-04 0.9999242
[73,] 4.762551e-04 9.525102e-04 0.9995237
[74,] 1.046161e-03 2.092322e-03 0.9989538
[75,] 1.202187e-03 2.404374e-03 0.9987978
[76,] 7.519750e-04 1.503950e-03 0.9992480
[77,] 4.729898e-04 9.459795e-04 0.9995270
[78,] 6.281992e-04 1.256398e-03 0.9993718
[79,] 3.827740e-04 7.655481e-04 0.9996172
[80,] 2.681549e-04 5.363099e-04 0.9997318
[81,] 1.657548e-04 3.315096e-04 0.9998342
[82,] 4.265049e-04 8.530099e-04 0.9995735
[83,] 2.731286e-04 5.462572e-04 0.9997269
[84,] 1.670615e-04 3.341229e-04 0.9998329
[85,] 1.083960e-04 2.167920e-04 0.9998916
[86,] 3.302370e-04 6.604739e-04 0.9996698
[87,] 1.954932e-04 3.909864e-04 0.9998045
[88,] 1.657577e-04 3.315155e-04 0.9998342
[89,] 1.957610e-04 3.915220e-04 0.9998042
[90,] 1.335628e-04 2.671257e-04 0.9998664
[91,] 7.427221e-05 1.485444e-04 0.9999257
[92,] 5.088964e-05 1.017793e-04 0.9999491
[93,] 6.703076e-05 1.340615e-04 0.9999330
[94,] 1.105956e-03 2.211912e-03 0.9988940
[95,] 1.068557e-02 2.137113e-02 0.9893144
[96,] 2.534860e-02 5.069720e-02 0.9746514
[97,] 2.761849e-02 5.523698e-02 0.9723815
[98,] 3.572714e-02 7.145428e-02 0.9642729
[99,] 5.375718e-02 1.075144e-01 0.9462428
[100,] 9.534648e-02 1.906930e-01 0.9046535
[101,] 7.309121e-02 1.461824e-01 0.9269088
[102,] 4.534000e-02 9.068000e-02 0.9546600
[103,] 3.724764e-01 7.449528e-01 0.6275236
[104,] 5.859742e-01 8.280516e-01 0.4140258
[105,] 4.331702e-01 8.663403e-01 0.5668298
> postscript(file="/var/wessaorg/rcomp/tmp/1fm2q1322152098.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/2ch4l1322152098.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/39mfk1322152098.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/4iuoc1322152098.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/5tgsk1322152098.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 = 118
Frequency = 1
1 2 3 4 5
34.81061098 23.92890178 39.36975638 28.29825765 19.66037178
6 7 8 9 10
32.88210972 40.56678765 26.05443432 31.12593305 17.17272511
11 12 13 14 15
10.10122638 33.92890178 -8.04935016 -0.73402809 23.17238778
16 17 18 19 20
-17.78082015 -23.49020476 -5.53699682 4.90385778 -0.80552682
21 22 23 24 25
0.02214858 4.97535651 21.90385778 40.21917985 -7.73436542
26 27 28 29 30
-22.49054209 -44.95610336 -17.64078129 -8.71228003 -31.64078129
31 32 33 34 35
19.06860331 51.75328125 20.04389664 -1.88460463 24.35921871
36 37 38 39 40
41.84686537 13.38096677 -16.79135783 9.16185011 -28.42200196
41 42 43 44 45
-17.90964862 -59.35050323 -6.39729529 -5.03518116 -16.39729529
46 47 48 49 50
-51.54753450 -44.86285656 -53.90964862 -87.52578643 -83.96664103
51 52 53 54 55
-63.50107976 -81.06022516 -74.74490309 -60.45428770 -20.50107976
56 57 58 59 60
16.18359817 52.23039024 20.69595151 -4.25725643 -15.72281770
61 62 63 64 65
-86.92018630 -46.45462503 -49.16400963 -58.45462503 -40.60486424
66 67 68 69 70
-67.92018630 65.78919830 3.83599037 -17.11721757 58.83599037
71 72 73 74 75
49.52066830 51.37042910 -32.33929284 -50.14226157 -12.26779411
76 77 78 79 80
43.63862177 -44.55840950 -6.11755490 88.17306050 69.73220589
81 82 83 84 85
48.68541383 -2.36137823 -2.31458617 57.17306050 -1.53666144
86 87 88 89 90
-30.97751604 9.70716190 -70.44307731 -15.22133937 -17.78048477
91 92 93 94 95
2.26630729 92.58162936 5.02248396 36.73186857 51.77866063
96 97 98 99 100
37.31309936 -18.88426924 -22.95576797 -60.88426924 -107.32512384
101 102 103 104 105
-99.37191591 -54.44341464 11.87190743 111.35955409 9.84720076
106 107 108 109 110
141.11573076 93.40634615 50.62808409 119.40600883 65.96515422
111 112 113 114 115
-8.35016784 -20.23187705 -78.59399117 -59.08163784 14.64983216
116 117 118
-2.05955245 38.76812295 37.69662422
> postscript(file="/var/wessaorg/rcomp/tmp/6sl1m1322152098.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 = 118
Frequency = 1
lag(myerror, k = 1) myerror
0 34.81061098 NA
1 23.92890178 34.81061098
2 39.36975638 23.92890178
3 28.29825765 39.36975638
4 19.66037178 28.29825765
5 32.88210972 19.66037178
6 40.56678765 32.88210972
7 26.05443432 40.56678765
8 31.12593305 26.05443432
9 17.17272511 31.12593305
10 10.10122638 17.17272511
11 33.92890178 10.10122638
12 -8.04935016 33.92890178
13 -0.73402809 -8.04935016
14 23.17238778 -0.73402809
15 -17.78082015 23.17238778
16 -23.49020476 -17.78082015
17 -5.53699682 -23.49020476
18 4.90385778 -5.53699682
19 -0.80552682 4.90385778
20 0.02214858 -0.80552682
21 4.97535651 0.02214858
22 21.90385778 4.97535651
23 40.21917985 21.90385778
24 -7.73436542 40.21917985
25 -22.49054209 -7.73436542
26 -44.95610336 -22.49054209
27 -17.64078129 -44.95610336
28 -8.71228003 -17.64078129
29 -31.64078129 -8.71228003
30 19.06860331 -31.64078129
31 51.75328125 19.06860331
32 20.04389664 51.75328125
33 -1.88460463 20.04389664
34 24.35921871 -1.88460463
35 41.84686537 24.35921871
36 13.38096677 41.84686537
37 -16.79135783 13.38096677
38 9.16185011 -16.79135783
39 -28.42200196 9.16185011
40 -17.90964862 -28.42200196
41 -59.35050323 -17.90964862
42 -6.39729529 -59.35050323
43 -5.03518116 -6.39729529
44 -16.39729529 -5.03518116
45 -51.54753450 -16.39729529
46 -44.86285656 -51.54753450
47 -53.90964862 -44.86285656
48 -87.52578643 -53.90964862
49 -83.96664103 -87.52578643
50 -63.50107976 -83.96664103
51 -81.06022516 -63.50107976
52 -74.74490309 -81.06022516
53 -60.45428770 -74.74490309
54 -20.50107976 -60.45428770
55 16.18359817 -20.50107976
56 52.23039024 16.18359817
57 20.69595151 52.23039024
58 -4.25725643 20.69595151
59 -15.72281770 -4.25725643
60 -86.92018630 -15.72281770
61 -46.45462503 -86.92018630
62 -49.16400963 -46.45462503
63 -58.45462503 -49.16400963
64 -40.60486424 -58.45462503
65 -67.92018630 -40.60486424
66 65.78919830 -67.92018630
67 3.83599037 65.78919830
68 -17.11721757 3.83599037
69 58.83599037 -17.11721757
70 49.52066830 58.83599037
71 51.37042910 49.52066830
72 -32.33929284 51.37042910
73 -50.14226157 -32.33929284
74 -12.26779411 -50.14226157
75 43.63862177 -12.26779411
76 -44.55840950 43.63862177
77 -6.11755490 -44.55840950
78 88.17306050 -6.11755490
79 69.73220589 88.17306050
80 48.68541383 69.73220589
81 -2.36137823 48.68541383
82 -2.31458617 -2.36137823
83 57.17306050 -2.31458617
84 -1.53666144 57.17306050
85 -30.97751604 -1.53666144
86 9.70716190 -30.97751604
87 -70.44307731 9.70716190
88 -15.22133937 -70.44307731
89 -17.78048477 -15.22133937
90 2.26630729 -17.78048477
91 92.58162936 2.26630729
92 5.02248396 92.58162936
93 36.73186857 5.02248396
94 51.77866063 36.73186857
95 37.31309936 51.77866063
96 -18.88426924 37.31309936
97 -22.95576797 -18.88426924
98 -60.88426924 -22.95576797
99 -107.32512384 -60.88426924
100 -99.37191591 -107.32512384
101 -54.44341464 -99.37191591
102 11.87190743 -54.44341464
103 111.35955409 11.87190743
104 9.84720076 111.35955409
105 141.11573076 9.84720076
106 93.40634615 141.11573076
107 50.62808409 93.40634615
108 119.40600883 50.62808409
109 65.96515422 119.40600883
110 -8.35016784 65.96515422
111 -20.23187705 -8.35016784
112 -78.59399117 -20.23187705
113 -59.08163784 -78.59399117
114 14.64983216 -59.08163784
115 -2.05955245 14.64983216
116 38.76812295 -2.05955245
117 37.69662422 38.76812295
118 NA 37.69662422
> dum1 <- dum[2:length(myerror),]
> dum1
lag(myerror, k = 1) myerror
[1,] 23.92890178 34.81061098
[2,] 39.36975638 23.92890178
[3,] 28.29825765 39.36975638
[4,] 19.66037178 28.29825765
[5,] 32.88210972 19.66037178
[6,] 40.56678765 32.88210972
[7,] 26.05443432 40.56678765
[8,] 31.12593305 26.05443432
[9,] 17.17272511 31.12593305
[10,] 10.10122638 17.17272511
[11,] 33.92890178 10.10122638
[12,] -8.04935016 33.92890178
[13,] -0.73402809 -8.04935016
[14,] 23.17238778 -0.73402809
[15,] -17.78082015 23.17238778
[16,] -23.49020476 -17.78082015
[17,] -5.53699682 -23.49020476
[18,] 4.90385778 -5.53699682
[19,] -0.80552682 4.90385778
[20,] 0.02214858 -0.80552682
[21,] 4.97535651 0.02214858
[22,] 21.90385778 4.97535651
[23,] 40.21917985 21.90385778
[24,] -7.73436542 40.21917985
[25,] -22.49054209 -7.73436542
[26,] -44.95610336 -22.49054209
[27,] -17.64078129 -44.95610336
[28,] -8.71228003 -17.64078129
[29,] -31.64078129 -8.71228003
[30,] 19.06860331 -31.64078129
[31,] 51.75328125 19.06860331
[32,] 20.04389664 51.75328125
[33,] -1.88460463 20.04389664
[34,] 24.35921871 -1.88460463
[35,] 41.84686537 24.35921871
[36,] 13.38096677 41.84686537
[37,] -16.79135783 13.38096677
[38,] 9.16185011 -16.79135783
[39,] -28.42200196 9.16185011
[40,] -17.90964862 -28.42200196
[41,] -59.35050323 -17.90964862
[42,] -6.39729529 -59.35050323
[43,] -5.03518116 -6.39729529
[44,] -16.39729529 -5.03518116
[45,] -51.54753450 -16.39729529
[46,] -44.86285656 -51.54753450
[47,] -53.90964862 -44.86285656
[48,] -87.52578643 -53.90964862
[49,] -83.96664103 -87.52578643
[50,] -63.50107976 -83.96664103
[51,] -81.06022516 -63.50107976
[52,] -74.74490309 -81.06022516
[53,] -60.45428770 -74.74490309
[54,] -20.50107976 -60.45428770
[55,] 16.18359817 -20.50107976
[56,] 52.23039024 16.18359817
[57,] 20.69595151 52.23039024
[58,] -4.25725643 20.69595151
[59,] -15.72281770 -4.25725643
[60,] -86.92018630 -15.72281770
[61,] -46.45462503 -86.92018630
[62,] -49.16400963 -46.45462503
[63,] -58.45462503 -49.16400963
[64,] -40.60486424 -58.45462503
[65,] -67.92018630 -40.60486424
[66,] 65.78919830 -67.92018630
[67,] 3.83599037 65.78919830
[68,] -17.11721757 3.83599037
[69,] 58.83599037 -17.11721757
[70,] 49.52066830 58.83599037
[71,] 51.37042910 49.52066830
[72,] -32.33929284 51.37042910
[73,] -50.14226157 -32.33929284
[74,] -12.26779411 -50.14226157
[75,] 43.63862177 -12.26779411
[76,] -44.55840950 43.63862177
[77,] -6.11755490 -44.55840950
[78,] 88.17306050 -6.11755490
[79,] 69.73220589 88.17306050
[80,] 48.68541383 69.73220589
[81,] -2.36137823 48.68541383
[82,] -2.31458617 -2.36137823
[83,] 57.17306050 -2.31458617
[84,] -1.53666144 57.17306050
[85,] -30.97751604 -1.53666144
[86,] 9.70716190 -30.97751604
[87,] -70.44307731 9.70716190
[88,] -15.22133937 -70.44307731
[89,] -17.78048477 -15.22133937
[90,] 2.26630729 -17.78048477
[91,] 92.58162936 2.26630729
[92,] 5.02248396 92.58162936
[93,] 36.73186857 5.02248396
[94,] 51.77866063 36.73186857
[95,] 37.31309936 51.77866063
[96,] -18.88426924 37.31309936
[97,] -22.95576797 -18.88426924
[98,] -60.88426924 -22.95576797
[99,] -107.32512384 -60.88426924
[100,] -99.37191591 -107.32512384
[101,] -54.44341464 -99.37191591
[102,] 11.87190743 -54.44341464
[103,] 111.35955409 11.87190743
[104,] 9.84720076 111.35955409
[105,] 141.11573076 9.84720076
[106,] 93.40634615 141.11573076
[107,] 50.62808409 93.40634615
[108,] 119.40600883 50.62808409
[109,] 65.96515422 119.40600883
[110,] -8.35016784 65.96515422
[111,] -20.23187705 -8.35016784
[112,] -78.59399117 -20.23187705
[113,] -59.08163784 -78.59399117
[114,] 14.64983216 -59.08163784
[115,] -2.05955245 14.64983216
[116,] 38.76812295 -2.05955245
[117,] 37.69662422 38.76812295
> z <- as.data.frame(dum1)
> z
lag(myerror, k = 1) myerror
1 23.92890178 34.81061098
2 39.36975638 23.92890178
3 28.29825765 39.36975638
4 19.66037178 28.29825765
5 32.88210972 19.66037178
6 40.56678765 32.88210972
7 26.05443432 40.56678765
8 31.12593305 26.05443432
9 17.17272511 31.12593305
10 10.10122638 17.17272511
11 33.92890178 10.10122638
12 -8.04935016 33.92890178
13 -0.73402809 -8.04935016
14 23.17238778 -0.73402809
15 -17.78082015 23.17238778
16 -23.49020476 -17.78082015
17 -5.53699682 -23.49020476
18 4.90385778 -5.53699682
19 -0.80552682 4.90385778
20 0.02214858 -0.80552682
21 4.97535651 0.02214858
22 21.90385778 4.97535651
23 40.21917985 21.90385778
24 -7.73436542 40.21917985
25 -22.49054209 -7.73436542
26 -44.95610336 -22.49054209
27 -17.64078129 -44.95610336
28 -8.71228003 -17.64078129
29 -31.64078129 -8.71228003
30 19.06860331 -31.64078129
31 51.75328125 19.06860331
32 20.04389664 51.75328125
33 -1.88460463 20.04389664
34 24.35921871 -1.88460463
35 41.84686537 24.35921871
36 13.38096677 41.84686537
37 -16.79135783 13.38096677
38 9.16185011 -16.79135783
39 -28.42200196 9.16185011
40 -17.90964862 -28.42200196
41 -59.35050323 -17.90964862
42 -6.39729529 -59.35050323
43 -5.03518116 -6.39729529
44 -16.39729529 -5.03518116
45 -51.54753450 -16.39729529
46 -44.86285656 -51.54753450
47 -53.90964862 -44.86285656
48 -87.52578643 -53.90964862
49 -83.96664103 -87.52578643
50 -63.50107976 -83.96664103
51 -81.06022516 -63.50107976
52 -74.74490309 -81.06022516
53 -60.45428770 -74.74490309
54 -20.50107976 -60.45428770
55 16.18359817 -20.50107976
56 52.23039024 16.18359817
57 20.69595151 52.23039024
58 -4.25725643 20.69595151
59 -15.72281770 -4.25725643
60 -86.92018630 -15.72281770
61 -46.45462503 -86.92018630
62 -49.16400963 -46.45462503
63 -58.45462503 -49.16400963
64 -40.60486424 -58.45462503
65 -67.92018630 -40.60486424
66 65.78919830 -67.92018630
67 3.83599037 65.78919830
68 -17.11721757 3.83599037
69 58.83599037 -17.11721757
70 49.52066830 58.83599037
71 51.37042910 49.52066830
72 -32.33929284 51.37042910
73 -50.14226157 -32.33929284
74 -12.26779411 -50.14226157
75 43.63862177 -12.26779411
76 -44.55840950 43.63862177
77 -6.11755490 -44.55840950
78 88.17306050 -6.11755490
79 69.73220589 88.17306050
80 48.68541383 69.73220589
81 -2.36137823 48.68541383
82 -2.31458617 -2.36137823
83 57.17306050 -2.31458617
84 -1.53666144 57.17306050
85 -30.97751604 -1.53666144
86 9.70716190 -30.97751604
87 -70.44307731 9.70716190
88 -15.22133937 -70.44307731
89 -17.78048477 -15.22133937
90 2.26630729 -17.78048477
91 92.58162936 2.26630729
92 5.02248396 92.58162936
93 36.73186857 5.02248396
94 51.77866063 36.73186857
95 37.31309936 51.77866063
96 -18.88426924 37.31309936
97 -22.95576797 -18.88426924
98 -60.88426924 -22.95576797
99 -107.32512384 -60.88426924
100 -99.37191591 -107.32512384
101 -54.44341464 -99.37191591
102 11.87190743 -54.44341464
103 111.35955409 11.87190743
104 9.84720076 111.35955409
105 141.11573076 9.84720076
106 93.40634615 141.11573076
107 50.62808409 93.40634615
108 119.40600883 50.62808409
109 65.96515422 119.40600883
110 -8.35016784 65.96515422
111 -20.23187705 -8.35016784
112 -78.59399117 -20.23187705
113 -59.08163784 -78.59399117
114 14.64983216 -59.08163784
115 -2.05955245 14.64983216
116 38.76812295 -2.05955245
117 37.69662422 38.76812295
> 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/7j1wm1322152098.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/8tyd91322152098.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/9lgzy1322152098.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/10x3j61322152098.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/11qyr91322152098.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/12tglm1322152098.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/13we6o1322152098.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/14z8bj1322152098.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/1598531322152098.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/166jcr1322152098.tab")
+ }
>
> try(system("convert tmp/1fm2q1322152098.ps tmp/1fm2q1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/2ch4l1322152098.ps tmp/2ch4l1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/39mfk1322152098.ps tmp/39mfk1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/4iuoc1322152098.ps tmp/4iuoc1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/5tgsk1322152098.ps tmp/5tgsk1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/6sl1m1322152098.ps tmp/6sl1m1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/7j1wm1322152098.ps tmp/7j1wm1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/8tyd91322152098.ps tmp/8tyd91322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/9lgzy1322152098.ps tmp/9lgzy1322152098.png",intern=TRUE))
character(0)
> try(system("convert tmp/10x3j61322152098.ps tmp/10x3j61322152098.png",intern=TRUE))
character(0)
>
>
> proc.time()
user system elapsed
3.980 0.530 4.648