R version 2.12.0 (2010-10-15)
Copyright (C) 2010 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(1,1,6.3,2.1,3.5,0.075,1.2,42,1,2,2,6.6,4.1,6,0.785,3.5,42,2,2,2,9.5,1.2,10.4,0.2,5,120,2,5,5,3.3,0.5,20,27.66,115,148,5,1,2,11,3.4,3.9,0.12,1,16,3,3,1,4.7,1.5,41,85,325,310,1,1,3,10.4,3.4,9,0.101,4,28,5,3,4,7.4,0.8,7.6,1.04,5.5,68,5,5,5,2.1,0.8,46,521,655,336,5,1,1,17.9,2,24,0.01,0.25,50,1,1,1,6.1,1.9,100,62,1320,267,1,1,3,11.9,1.3,3.2,0.023,0.4,19,4,1,1,13.8,5.6,5,1.7,6.3,12,2,1,1,14.3,3.1,6.5,3.5,10.8,120,2,2,2,15.2,1.8,12,0.48,15.5,140,2,4,4,10,0.9,20.2,10,115,170,4,1,2,11.9,1.8,13,1.62,11.4,17,2,4,4,6.5,1.9,27,192,180,115,4,5,5,7.5,0.9,18,2.5,12.1,31,5,1,3,10.6,2.6,4.7,0.28,1.9,21,3,1,1,7.4,2.4,9.8,4.235,50.4,52,1,3,2,8.4,1.2,29,6.8,179,164,2,2,2,5.7,0.9,7,0.75,12.3,225,2,2,3,4.9,0.5,6,3.6,21,225,3,5,5,3.2,0.6,20,55.5,175,151,5,1,2,11,2.3,4.5,0.9,2.6,60,2,1,3,4.9,0.5,7.5,2,12.3,200,3,2,2,13.2,2.6,2.3,0.104,2.5,46,3,3,4,9.7,0.6,24,4.19,58,210,4,1,1,12.8,6.6,3,3.5,3.9,14,2),dim=c(9,30),dimnames=list(c('S','D','SWS','PS','L','WB','Wbr','Tg','p'),1:30))
> y <- array(NA,dim=c(9,30),dimnames=list(c('S','D','SWS','PS','L','WB','Wbr','Tg','p'),1:30))
> 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'
> #'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
D S SWS PS L WB Wbr Tg p
1 1 1 6.3 2.1 3.5 0.075 1.20 42 1
2 2 2 6.6 4.1 6.0 0.785 3.50 42 2
3 2 2 9.5 1.2 10.4 0.200 5.00 120 2
4 5 5 3.3 0.5 20.0 27.660 115.00 148 5
5 2 1 11.0 3.4 3.9 0.120 1.00 16 3
6 1 3 4.7 1.5 41.0 85.000 325.00 310 1
7 3 1 10.4 3.4 9.0 0.101 4.00 28 5
8 4 3 7.4 0.8 7.6 1.040 5.50 68 5
9 5 5 2.1 0.8 46.0 521.000 655.00 336 5
10 1 1 17.9 2.0 24.0 0.010 0.25 50 1
11 1 1 6.1 1.9 100.0 62.000 1320.00 267 1
12 3 1 11.9 1.3 3.2 0.023 0.40 19 4
13 1 1 13.8 5.6 5.0 1.700 6.30 12 2
14 1 1 14.3 3.1 6.5 3.500 10.80 120 2
15 2 2 15.2 1.8 12.0 0.480 15.50 140 2
16 4 4 10.0 0.9 20.2 10.000 115.00 170 4
17 2 1 11.9 1.8 13.0 1.620 11.40 17 2
18 4 4 6.5 1.9 27.0 192.000 180.00 115 4
19 5 5 7.5 0.9 18.0 2.500 12.10 31 5
20 3 1 10.6 2.6 4.7 0.280 1.90 21 3
21 1 1 7.4 2.4 9.8 4.235 50.40 52 1
22 2 3 8.4 1.2 29.0 6.800 179.00 164 2
23 2 2 5.7 0.9 7.0 0.750 12.30 225 2
24 3 2 4.9 0.5 6.0 3.600 21.00 225 3
25 5 5 3.2 0.6 20.0 55.500 175.00 151 5
26 2 1 11.0 2.3 4.5 0.900 2.60 60 2
27 3 1 4.9 0.5 7.5 2.000 12.30 200 3
28 2 2 13.2 2.6 2.3 0.104 2.50 46 3
29 4 3 9.7 0.6 24.0 4.190 58.00 210 4
30 1 1 12.8 6.6 3.0 3.500 3.90 14 2
> k <- length(x[1,])
> df <- as.data.frame(x)
> (mylm <- lm(df))
Call:
lm(formula = df)
Coefficients:
(Intercept) S SWS PS L WB
1.0109440 0.2069333 -0.0292189 -0.2020254 0.0045022 0.0008010
Wbr Tg p
-0.0003947 -0.0014294 0.6523805
> (mysum <- summary(mylm))
Call:
lm(formula = df)
Residuals:
Min 1Q Median 3Q Max
-0.52505 -0.19341 0.03226 0.18304 0.66935
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 1.0109440 0.4130912 2.447 0.02328 *
S 0.2069333 0.0873309 2.370 0.02747 *
SWS -0.0292189 0.0254615 -1.148 0.26405
PS -0.2020254 0.0642046 -3.147 0.00487 **
L 0.0045022 0.0150516 0.299 0.76779
WB 0.0008010 0.0009305 0.861 0.39905
Wbr -0.0003947 0.0011308 -0.349 0.73053
Tg -0.0014294 0.0011876 -1.204 0.24214
p 0.6523805 0.0710716 9.179 8.5e-09 ***
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 0.3341 on 21 degrees of freedom
Multiple R-squared: 0.9577, Adjusted R-squared: 0.9415
F-statistic: 59.36 on 8 and 21 DF, p-value: 1.097e-12
> 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.2797204 0.5594409 0.7202796
[2,] 0.2756951 0.5513902 0.7243049
[3,] 0.2440943 0.4881885 0.7559057
[4,] 0.3351188 0.6702377 0.6648812
[5,] 0.3222944 0.6445888 0.6777056
[6,] 0.2314450 0.4628900 0.7685550
[7,] 0.1541158 0.3082316 0.8458842
> postscript(file="/var/www/rcomp/tmp/16d1n1292351149.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/www/rcomp/tmp/26d1n1292351149.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/www/rcomp/tmp/3gmi81292351149.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/www/rcomp/tmp/4gmi81292351149.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/www/rcomp/tmp/5gmi81292351149.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 = 30
Frequency = 1
1 2 3 4 5 6
-0.217235185 0.325350890 -0.083044502 0.034661401 -0.161114314 -0.525046747
7 8 9 10 11 12
-0.488016066 -0.451486853 0.029848838 0.020318688 0.094582605 -0.204170454
13 14 15 16 17 18
0.007691311 -0.334807545 0.230022833 0.215243766 0.157685238 0.085646910
19 20 21 22 23 24
0.059495999 0.669350071 -0.122470107 -0.279576947 -0.086849927 0.162237474
25 26 27 28 29 30
0.057612240 0.329236869 0.324530515 -0.414696209 0.375027301 0.189971910
> postscript(file="/var/www/rcomp/tmp/6rvzt1292351149.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 = 30
Frequency = 1
lag(myerror, k = 1) myerror
0 -0.217235185 NA
1 0.325350890 -0.217235185
2 -0.083044502 0.325350890
3 0.034661401 -0.083044502
4 -0.161114314 0.034661401
5 -0.525046747 -0.161114314
6 -0.488016066 -0.525046747
7 -0.451486853 -0.488016066
8 0.029848838 -0.451486853
9 0.020318688 0.029848838
10 0.094582605 0.020318688
11 -0.204170454 0.094582605
12 0.007691311 -0.204170454
13 -0.334807545 0.007691311
14 0.230022833 -0.334807545
15 0.215243766 0.230022833
16 0.157685238 0.215243766
17 0.085646910 0.157685238
18 0.059495999 0.085646910
19 0.669350071 0.059495999
20 -0.122470107 0.669350071
21 -0.279576947 -0.122470107
22 -0.086849927 -0.279576947
23 0.162237474 -0.086849927
24 0.057612240 0.162237474
25 0.329236869 0.057612240
26 0.324530515 0.329236869
27 -0.414696209 0.324530515
28 0.375027301 -0.414696209
29 0.189971910 0.375027301
30 NA 0.189971910
> dum1 <- dum[2:length(myerror),]
> dum1
lag(myerror, k = 1) myerror
[1,] 0.325350890 -0.217235185
[2,] -0.083044502 0.325350890
[3,] 0.034661401 -0.083044502
[4,] -0.161114314 0.034661401
[5,] -0.525046747 -0.161114314
[6,] -0.488016066 -0.525046747
[7,] -0.451486853 -0.488016066
[8,] 0.029848838 -0.451486853
[9,] 0.020318688 0.029848838
[10,] 0.094582605 0.020318688
[11,] -0.204170454 0.094582605
[12,] 0.007691311 -0.204170454
[13,] -0.334807545 0.007691311
[14,] 0.230022833 -0.334807545
[15,] 0.215243766 0.230022833
[16,] 0.157685238 0.215243766
[17,] 0.085646910 0.157685238
[18,] 0.059495999 0.085646910
[19,] 0.669350071 0.059495999
[20,] -0.122470107 0.669350071
[21,] -0.279576947 -0.122470107
[22,] -0.086849927 -0.279576947
[23,] 0.162237474 -0.086849927
[24,] 0.057612240 0.162237474
[25,] 0.329236869 0.057612240
[26,] 0.324530515 0.329236869
[27,] -0.414696209 0.324530515
[28,] 0.375027301 -0.414696209
[29,] 0.189971910 0.375027301
> z <- as.data.frame(dum1)
> z
lag(myerror, k = 1) myerror
1 0.325350890 -0.217235185
2 -0.083044502 0.325350890
3 0.034661401 -0.083044502
4 -0.161114314 0.034661401
5 -0.525046747 -0.161114314
6 -0.488016066 -0.525046747
7 -0.451486853 -0.488016066
8 0.029848838 -0.451486853
9 0.020318688 0.029848838
10 0.094582605 0.020318688
11 -0.204170454 0.094582605
12 0.007691311 -0.204170454
13 -0.334807545 0.007691311
14 0.230022833 -0.334807545
15 0.215243766 0.230022833
16 0.157685238 0.215243766
17 0.085646910 0.157685238
18 0.059495999 0.085646910
19 0.669350071 0.059495999
20 -0.122470107 0.669350071
21 -0.279576947 -0.122470107
22 -0.086849927 -0.279576947
23 0.162237474 -0.086849927
24 0.057612240 0.162237474
25 0.329236869 0.057612240
26 0.324530515 0.329236869
27 -0.414696209 0.324530515
28 0.375027301 -0.414696209
29 0.189971910 0.375027301
> plot(z,main=paste('Residual Lag plot, lowess, and regression line'), ylab='values of Residuals', xlab='lagged values of Residuals')
> lines(lowess(z))
> abline(lm(z))
> grid()
> dev.off()
null device
1
> postscript(file="/var/www/rcomp/tmp/724gv1292351149.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/www/rcomp/tmp/824gv1292351149.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/www/rcomp/tmp/924gv1292351149.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')
Warning messages:
1: In sqrt(crit * p * (1 - hh)/hh) : NaNs produced
2: In sqrt(crit * p * (1 - hh)/hh) : NaNs produced
> par(opar)
> dev.off()
null device
1
> if (n > n25) {
+ postscript(file="/var/www/rcomp/tmp/10ddgy1292351149.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/www/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab
> load(file="/var/www/rcomp/createtable")
>
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Estimated Regression Equation', 1, TRUE)
> a<-table.row.end(a)
> myeq <- colnames(x)[1]
> myeq <- paste(myeq, '[t] = ', sep='')
> for (i in 1:k){
+ if (mysum$coefficients[i,1] > 0) myeq <- paste(myeq, '+', '')
+ myeq <- paste(myeq, mysum$coefficients[i,1], sep=' ')
+ if (rownames(mysum$coefficients)[i] != '(Intercept)') {
+ myeq <- paste(myeq, rownames(mysum$coefficients)[i], sep='')
+ if (rownames(mysum$coefficients)[i] != 't') myeq <- paste(myeq, '[t]', sep='')
+ }
+ }
> myeq <- paste(myeq, ' + e[t]')
> a<-table.row.start(a)
> a<-table.element(a, myeq)
> a<-table.row.end(a)
> a<-table.end(a)
> table.save(a,file="/var/www/rcomp/tmp/11gewm1292351149.tab")
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a,hyperlink('http://www.xycoon.com/ols1.htm','Multiple Linear Regression - Ordinary Least Squares',''), 6, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a,'Variable',header=TRUE)
> a<-table.element(a,'Parameter',header=TRUE)
> a<-table.element(a,'S.D.',header=TRUE)
> a<-table.element(a,'T-STAT
H0: parameter = 0',header=TRUE)
> a<-table.element(a,'2-tail p-value',header=TRUE)
> a<-table.element(a,'1-tail p-value',header=TRUE)
> a<-table.row.end(a)
> for (i in 1:k){
+ a<-table.row.start(a)
+ a<-table.element(a,rownames(mysum$coefficients)[i],header=TRUE)
+ a<-table.element(a,mysum$coefficients[i,1])
+ a<-table.element(a, round(mysum$coefficients[i,2],6))
+ a<-table.element(a, round(mysum$coefficients[i,3],4))
+ a<-table.element(a, round(mysum$coefficients[i,4],6))
+ a<-table.element(a, round(mysum$coefficients[i,4]/2,6))
+ a<-table.row.end(a)
+ }
> a<-table.end(a)
> table.save(a,file="/var/www/rcomp/tmp/121fva1292351149.tab")
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Regression Statistics', 2, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple R',1,TRUE)
> a<-table.element(a, sqrt(mysum$r.squared))
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'R-squared',1,TRUE)
> a<-table.element(a, mysum$r.squared)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Adjusted R-squared',1,TRUE)
> a<-table.element(a, mysum$adj.r.squared)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'F-TEST (value)',1,TRUE)
> a<-table.element(a, mysum$fstatistic[1])
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'F-TEST (DF numerator)',1,TRUE)
> a<-table.element(a, mysum$fstatistic[2])
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'F-TEST (DF denominator)',1,TRUE)
> a<-table.element(a, mysum$fstatistic[3])
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'p-value',1,TRUE)
> a<-table.element(a, 1-pf(mysum$fstatistic[1],mysum$fstatistic[2],mysum$fstatistic[3]))
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Residual Statistics', 2, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Residual Standard Deviation',1,TRUE)
> a<-table.element(a, mysum$sigma)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Sum Squared Residuals',1,TRUE)
> a<-table.element(a, sum(myerror*myerror))
> a<-table.row.end(a)
> a<-table.end(a)
> table.save(a,file="/var/www/rcomp/tmp/13y6t11292351149.tab")
> a<-table.start()
> a<-table.row.start(a)
> a<-table.element(a, 'Multiple Linear Regression - Actuals, Interpolation, and Residuals', 4, TRUE)
> a<-table.row.end(a)
> a<-table.row.start(a)
> a<-table.element(a, 'Time or Index', 1, TRUE)
> a<-table.element(a, 'Actuals', 1, TRUE)
> a<-table.element(a, 'Interpolation
Forecast', 1, TRUE)
> a<-table.element(a, 'Residuals
Prediction Error', 1, TRUE)
> a<-table.row.end(a)
> for (i in 1:n) {
+ a<-table.row.start(a)
+ a<-table.element(a,i, 1, TRUE)
+ a<-table.element(a,x[i])
+ a<-table.element(a,x[i]-mysum$resid[i])
+ a<-table.element(a,mysum$resid[i])
+ a<-table.row.end(a)
+ }
> a<-table.end(a)
> table.save(a,file="/var/www/rcomp/tmp/14j7rp1292351149.tab")
> if (n > n25) {
+ a<-table.start()
+ a<-table.row.start(a)
+ a<-table.element(a,'Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'p-values',header=TRUE)
+ a<-table.element(a,'Alternative Hypothesis',3,header=TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'breakpoint index',header=TRUE)
+ a<-table.element(a,'greater',header=TRUE)
+ a<-table.element(a,'2-sided',header=TRUE)
+ a<-table.element(a,'less',header=TRUE)
+ a<-table.row.end(a)
+ for (mypoint in kp3:nmkm3) {
+ a<-table.row.start(a)
+ a<-table.element(a,mypoint,header=TRUE)
+ a<-table.element(a,gqarr[mypoint-kp3+1,1])
+ a<-table.element(a,gqarr[mypoint-kp3+1,2])
+ a<-table.element(a,gqarr[mypoint-kp3+1,3])
+ a<-table.row.end(a)
+ }
+ a<-table.end(a)
+ table.save(a,file="/var/www/rcomp/tmp/1547pc1292351149.tab")
+ a<-table.start()
+ a<-table.row.start(a)
+ a<-table.element(a,'Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'Description',header=TRUE)
+ a<-table.element(a,'# significant tests',header=TRUE)
+ a<-table.element(a,'% significant tests',header=TRUE)
+ a<-table.element(a,'OK/NOK',header=TRUE)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'1% type I error level',header=TRUE)
+ a<-table.element(a,numsignificant1)
+ a<-table.element(a,numsignificant1/numgqtests)
+ if (numsignificant1/numgqtests < 0.01) dum <- 'OK' else dum <- 'NOK'
+ a<-table.element(a,dum)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'5% type I error level',header=TRUE)
+ a<-table.element(a,numsignificant5)
+ a<-table.element(a,numsignificant5/numgqtests)
+ if (numsignificant5/numgqtests < 0.05) dum <- 'OK' else dum <- 'NOK'
+ a<-table.element(a,dum)
+ a<-table.row.end(a)
+ a<-table.row.start(a)
+ a<-table.element(a,'10% type I error level',header=TRUE)
+ a<-table.element(a,numsignificant10)
+ a<-table.element(a,numsignificant10/numgqtests)
+ if (numsignificant10/numgqtests < 0.1) dum <- 'OK' else dum <- 'NOK'
+ a<-table.element(a,dum)
+ a<-table.row.end(a)
+ a<-table.end(a)
+ table.save(a,file="/var/www/rcomp/tmp/168q6i1292351149.tab")
+ }
>
> try(system("convert tmp/16d1n1292351149.ps tmp/16d1n1292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/26d1n1292351149.ps tmp/26d1n1292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/3gmi81292351149.ps tmp/3gmi81292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/4gmi81292351149.ps tmp/4gmi81292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/5gmi81292351149.ps tmp/5gmi81292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/6rvzt1292351149.ps tmp/6rvzt1292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/724gv1292351149.ps tmp/724gv1292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/824gv1292351149.ps tmp/824gv1292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/924gv1292351149.ps tmp/924gv1292351149.png",intern=TRUE))
character(0)
> try(system("convert tmp/10ddgy1292351149.ps tmp/10ddgy1292351149.png",intern=TRUE))
character(0)
>
>
> proc.time()
user system elapsed
2.90 1.55 4.43