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(1998,1073,965,1178,1999,1141,1094,1192,2000,1239,1158,1200,2001,1323,1152,1244,2002,1274,1140,1280,2003,1317,1151,1325,2004,1390,1289,1305,2005,1318,1305,1409,2006,1472,1379,1379,2007,1436,1299,1465,1998,5281,4944,5500,1999,5055,4819,5484,2000,5219,4966,5451,2001,5230,4604,5389,2002,5200,4772,5192,2003,5139,4567,5028,2004,5215,4924,5366,2005,5344,4922,5618,2006,5550,4990,5725,2007,5729,5253,5662,1998,3138,2732,3115,1999,3019,2921,3322,2000,3311,3197,3288,2001,3375,2930,3210,2002,3185,2992,3283,2003,3220,2924,3049,2004,3224,2912,3111,2005,3187,2945,3286,2006,3136,2856,3370,2007,3246,2959,3275,1998,63,61,54,1999,60,55,55,2000,51,57,50,2001,58,51,50,2002,50,54,47,2003,55,51,51,2004,60,56,62,2005,56,40,50,2006,44,43,43,2007,47,37,46),dim=c(4,40),dimnames=list(c('Jaar','Januari','Februari','Maart'),1:40))
> y <- array(NA,dim=c(4,40),dimnames=list(c('Jaar','Januari','Februari','Maart'),1:40))
> 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
Jaar Januari Februari Maart
1 1998 1073 965 1178
2 1999 1141 1094 1192
3 2000 1239 1158 1200
4 2001 1323 1152 1244
5 2002 1274 1140 1280
6 2003 1317 1151 1325
7 2004 1390 1289 1305
8 2005 1318 1305 1409
9 2006 1472 1379 1379
10 2007 1436 1299 1465
11 1998 5281 4944 5500
12 1999 5055 4819 5484
13 2000 5219 4966 5451
14 2001 5230 4604 5389
15 2002 5200 4772 5192
16 2003 5139 4567 5028
17 2004 5215 4924 5366
18 2005 5344 4922 5618
19 2006 5550 4990 5725
20 2007 5729 5253 5662
21 1998 3138 2732 3115
22 1999 3019 2921 3322
23 2000 3311 3197 3288
24 2001 3375 2930 3210
25 2002 3185 2992 3283
26 2003 3220 2924 3049
27 2004 3224 2912 3111
28 2005 3187 2945 3286
29 2006 3136 2856 3370
30 2007 3246 2959 3275
31 1998 63 61 54
32 1999 60 55 55
33 2000 51 57 50
34 2001 58 51 50
35 2002 50 54 47
36 2003 55 51 51
37 2004 60 56 62
38 2005 56 40 50
39 2006 44 43 43
40 2007 47 37 46
> k <- length(x[1,])
> df <- as.data.frame(x)
> (mylm <- lm(df))
Call:
lm(formula = df)
Coefficients:
(Intercept) Januari Februari Maart
2.002e+03 6.154e-03 -2.678e-03 -3.551e-03
> (mysum <- summary(mylm))
Call:
lm(formula = df)
Residuals:
Min 1Q Median 3Q Max
-5.2339 -2.2666 -0.3782 2.7177 4.6717
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 2.002e+03 7.537e-01 2656.648 <2e-16 ***
Januari 6.154e-03 5.315e-03 1.158 0.255
Februari -2.678e-03 6.477e-03 -0.413 0.682
Maart -3.551e-03 4.667e-03 -0.761 0.452
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 2.965 on 36 degrees of freedom
Multiple R-squared: 0.04114, Adjusted R-squared: -0.03877
F-statistic: 0.5149 on 3 and 36 DF, p-value: 0.6747
> if (n > n25) {
+ kp3 <- k + 3
+ nmkm3 <- n - k - 3
+ gqarr <- array(NA, dim=c(nmkm3-kp3+1,3))
+ numgqtests <- 0
+ numsignificant1 <- 0
+ numsignificant5 <- 0
+ numsignificant10 <- 0
+ for (mypoint in kp3:nmkm3) {
+ j <- 0
+ numgqtests <- numgqtests + 1
+ for (myalt in c('greater', 'two.sided', 'less')) {
+ j <- j + 1
+ gqarr[mypoint-kp3+1,j] <- gqtest(mylm, point=mypoint, alternative=myalt)$p.value
+ }
+ if (gqarr[mypoint-kp3+1,2] < 0.01) numsignificant1 <- numsignificant1 + 1
+ if (gqarr[mypoint-kp3+1,2] < 0.05) numsignificant5 <- numsignificant5 + 1
+ if (gqarr[mypoint-kp3+1,2] < 0.10) numsignificant10 <- numsignificant10 + 1
+ }
+ gqarr
+ }
[,1] [,2] [,3]
[1,] 7.184219e-04 1.436844e-03 0.999281578
[2,] 3.567776e-04 7.135553e-04 0.999643222
[3,] 3.840438e-05 7.680876e-05 0.999961596
[4,] 4.247605e-06 8.495210e-06 0.999995752
[5,] 6.694196e-01 6.611608e-01 0.330580388
[6,] 6.098179e-01 7.803642e-01 0.390182092
[7,] 5.335072e-01 9.329856e-01 0.466492779
[8,] 5.072483e-01 9.855035e-01 0.492751738
[9,] 4.095274e-01 8.190548e-01 0.590472611
[10,] 3.138369e-01 6.276737e-01 0.686163132
[11,] 2.768689e-01 5.537377e-01 0.723131127
[12,] 3.427094e-01 6.854188e-01 0.657290586
[13,] 3.550546e-01 7.101092e-01 0.644945405
[14,] 3.675588e-01 7.351176e-01 0.632441202
[15,] 6.117297e-01 7.765405e-01 0.388270254
[16,] 6.480370e-01 7.039260e-01 0.351962983
[17,] 6.112618e-01 7.774765e-01 0.388738231
[18,] 6.877153e-01 6.245695e-01 0.312284729
[19,] 5.867114e-01 8.265773e-01 0.413288646
[20,] 4.817134e-01 9.634268e-01 0.518286597
[21,] 4.429339e-01 8.858679e-01 0.557066060
[22,] 4.741367e-01 9.482735e-01 0.525863251
[23,] 9.135847e-01 1.728305e-01 0.086415273
[24,] 9.901751e-01 1.964979e-02 0.009824895
[25,] 9.795847e-01 4.083060e-02 0.020415301
[26,] 9.832608e-01 3.347849e-02 0.016739243
[27,] 9.973406e-01 5.318790e-03 0.002659395
> postscript(file="/var/wessaorg/rcomp/tmp/1qeur1322062114.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/21nr31322062114.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/320ru1322062114.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/4nuvn1322062114.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/5yfek1322062114.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 = 40
Frequency = 1
1 2 3 4 5 6 7
-4.1369972 -3.1602822 -2.5635495 -1.9402775 -0.5430397 0.3816098 1.2309185
8 9 10 11 12 13 14
3.0861511 3.2301120 4.5428110 -4.0283028 -2.0291234 -1.7618654 -2.0191318
15 16 17 18 19 20 21
-1.0842075 -0.8401920 1.8484295 2.9441353 3.2385433 3.6175992 -5.2339484
22 23 24 25 26 27 28
-2.2604445 -2.4389609 -2.8247902 -0.2303222 -0.4587685 0.7046529 2.6421619
29 30 31 32 33 34 35
4.0159630 4.2775216 -4.3340807 -3.3281359 -2.2851525 -1.3442959 -0.2976859
36 37 38 39 40
0.6777164 1.6994001 2.6385545 3.6955746 4.6716995
> postscript(file="/var/wessaorg/rcomp/tmp/6u9ul1322062114.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 = 40
Frequency = 1
lag(myerror, k = 1) myerror
0 -4.1369972 NA
1 -3.1602822 -4.1369972
2 -2.5635495 -3.1602822
3 -1.9402775 -2.5635495
4 -0.5430397 -1.9402775
5 0.3816098 -0.5430397
6 1.2309185 0.3816098
7 3.0861511 1.2309185
8 3.2301120 3.0861511
9 4.5428110 3.2301120
10 -4.0283028 4.5428110
11 -2.0291234 -4.0283028
12 -1.7618654 -2.0291234
13 -2.0191318 -1.7618654
14 -1.0842075 -2.0191318
15 -0.8401920 -1.0842075
16 1.8484295 -0.8401920
17 2.9441353 1.8484295
18 3.2385433 2.9441353
19 3.6175992 3.2385433
20 -5.2339484 3.6175992
21 -2.2604445 -5.2339484
22 -2.4389609 -2.2604445
23 -2.8247902 -2.4389609
24 -0.2303222 -2.8247902
25 -0.4587685 -0.2303222
26 0.7046529 -0.4587685
27 2.6421619 0.7046529
28 4.0159630 2.6421619
29 4.2775216 4.0159630
30 -4.3340807 4.2775216
31 -3.3281359 -4.3340807
32 -2.2851525 -3.3281359
33 -1.3442959 -2.2851525
34 -0.2976859 -1.3442959
35 0.6777164 -0.2976859
36 1.6994001 0.6777164
37 2.6385545 1.6994001
38 3.6955746 2.6385545
39 4.6716995 3.6955746
40 NA 4.6716995
> dum1 <- dum[2:length(myerror),]
> dum1
lag(myerror, k = 1) myerror
[1,] -3.1602822 -4.1369972
[2,] -2.5635495 -3.1602822
[3,] -1.9402775 -2.5635495
[4,] -0.5430397 -1.9402775
[5,] 0.3816098 -0.5430397
[6,] 1.2309185 0.3816098
[7,] 3.0861511 1.2309185
[8,] 3.2301120 3.0861511
[9,] 4.5428110 3.2301120
[10,] -4.0283028 4.5428110
[11,] -2.0291234 -4.0283028
[12,] -1.7618654 -2.0291234
[13,] -2.0191318 -1.7618654
[14,] -1.0842075 -2.0191318
[15,] -0.8401920 -1.0842075
[16,] 1.8484295 -0.8401920
[17,] 2.9441353 1.8484295
[18,] 3.2385433 2.9441353
[19,] 3.6175992 3.2385433
[20,] -5.2339484 3.6175992
[21,] -2.2604445 -5.2339484
[22,] -2.4389609 -2.2604445
[23,] -2.8247902 -2.4389609
[24,] -0.2303222 -2.8247902
[25,] -0.4587685 -0.2303222
[26,] 0.7046529 -0.4587685
[27,] 2.6421619 0.7046529
[28,] 4.0159630 2.6421619
[29,] 4.2775216 4.0159630
[30,] -4.3340807 4.2775216
[31,] -3.3281359 -4.3340807
[32,] -2.2851525 -3.3281359
[33,] -1.3442959 -2.2851525
[34,] -0.2976859 -1.3442959
[35,] 0.6777164 -0.2976859
[36,] 1.6994001 0.6777164
[37,] 2.6385545 1.6994001
[38,] 3.6955746 2.6385545
[39,] 4.6716995 3.6955746
> z <- as.data.frame(dum1)
> z
lag(myerror, k = 1) myerror
1 -3.1602822 -4.1369972
2 -2.5635495 -3.1602822
3 -1.9402775 -2.5635495
4 -0.5430397 -1.9402775
5 0.3816098 -0.5430397
6 1.2309185 0.3816098
7 3.0861511 1.2309185
8 3.2301120 3.0861511
9 4.5428110 3.2301120
10 -4.0283028 4.5428110
11 -2.0291234 -4.0283028
12 -1.7618654 -2.0291234
13 -2.0191318 -1.7618654
14 -1.0842075 -2.0191318
15 -0.8401920 -1.0842075
16 1.8484295 -0.8401920
17 2.9441353 1.8484295
18 3.2385433 2.9441353
19 3.6175992 3.2385433
20 -5.2339484 3.6175992
21 -2.2604445 -5.2339484
22 -2.4389609 -2.2604445
23 -2.8247902 -2.4389609
24 -0.2303222 -2.8247902
25 -0.4587685 -0.2303222
26 0.7046529 -0.4587685
27 2.6421619 0.7046529
28 4.0159630 2.6421619
29 4.2775216 4.0159630
30 -4.3340807 4.2775216
31 -3.3281359 -4.3340807
32 -2.2851525 -3.3281359
33 -1.3442959 -2.2851525
34 -0.2976859 -1.3442959
35 0.6777164 -0.2976859
36 1.6994001 0.6777164
37 2.6385545 1.6994001
38 3.6955746 2.6385545
39 4.6716995 3.6955746
> 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/7wd3c1322062114.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/8a8r11322062114.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/9nmso1322062114.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/109jsb1322062114.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/11kk571322062114.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/12f1vd1322062114.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/13g9ya1322062114.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/14itvf1322062115.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/156yrh1322062115.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/167iiu1322062115.tab")
+ }
>
> try(system("convert tmp/1qeur1322062114.ps tmp/1qeur1322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/21nr31322062114.ps tmp/21nr31322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/320ru1322062114.ps tmp/320ru1322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/4nuvn1322062114.ps tmp/4nuvn1322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/5yfek1322062114.ps tmp/5yfek1322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/6u9ul1322062114.ps tmp/6u9ul1322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/7wd3c1322062114.ps tmp/7wd3c1322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/8a8r11322062114.ps tmp/8a8r11322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/9nmso1322062114.ps tmp/9nmso1322062114.png",intern=TRUE))
character(0)
> try(system("convert tmp/109jsb1322062114.ps tmp/109jsb1322062114.png",intern=TRUE))
character(0)
>
>
> proc.time()
user system elapsed
3.143 0.491 3.665