R version 2.8.0 (2008-10-20) Copyright (C) 2008 The R Foundation for Statistical Computing ISBN 3-900051-07-0 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(6340.5 + ,0 + ,7901.5 + ,0 + ,8191.1 + ,0 + ,7181.7 + ,0 + ,7594.4 + ,0 + ,7384.7 + ,0 + ,7876.7 + ,0 + ,8463.4 + ,0 + ,8317.2 + ,0 + ,7778.7 + ,0 + ,8532.8 + ,0 + ,7272.2 + ,0 + ,6680.1 + ,0 + ,8427.6 + ,0 + ,8752.8 + ,0 + ,7952.7 + ,0 + ,8694.3 + ,0 + ,7787 + ,0 + ,8474.2 + ,0 + ,9154.7 + ,0 + ,8557.2 + ,0 + ,7951.1 + ,0 + ,9156.7 + ,0 + ,7865.7 + ,0 + ,7337.4 + ,0 + ,9131.7 + ,0 + ,8814.6 + ,0 + ,8598.8 + ,0 + ,8439.6 + ,0 + ,7451.8 + ,0 + ,8016.2 + ,0 + ,9544.1 + ,0 + ,8270.7 + ,0 + ,8102.2 + ,0 + ,9369 + ,0 + ,7657.7 + ,0 + ,7816.6 + ,0 + ,9391.3 + ,0 + ,9445.4 + ,0 + ,9533.1 + ,0 + ,10068.7 + ,0 + ,8955.5 + ,0 + ,10423.9 + ,0 + ,11617.2 + ,0 + ,9391.1 + ,0 + ,10872 + ,0 + ,10230.4 + ,0 + ,9221 + ,0 + ,9428.6 + ,0 + ,10934.5 + ,0 + ,10986 + ,0 + ,11724.6 + ,0 + ,11180.9 + ,0 + ,11163.2 + ,0 + ,11240.9 + ,0 + ,12107.1 + ,0 + ,10762.3 + ,0 + ,11340.4 + ,0 + ,11266.8 + ,0 + ,9542.7 + ,0 + ,9227.7 + ,0 + ,10571.9 + ,0 + ,10774.4 + ,0 + ,10392.8 + ,0 + ,9920.2 + ,0 + ,9884.9 + ,1 + ,10174.5 + ,1 + ,11395.4 + ,1 + ,10760.2 + ,1 + ,10570.1 + ,1 + ,10536 + ,1 + ,9902.6 + ,1 + ,8889 + ,1 + ,10837.3 + ,1 + ,11624.1 + ,1 + ,10509 + ,1 + ,10984.9 + ,1 + ,10649.1 + ,1 + ,10855.7 + ,1 + ,11677.4 + ,1 + ,10760.2 + ,1 + ,10046.2 + ,1 + ,10772.8 + ,1 + ,9987.7 + ,1 + ,8638.7 + ,1 + ,11063.7 + ,1 + ,11855.7 + ,1 + ,10684.5 + ,1 + ,11337.4 + ,1 + ,10478 + ,1 + ,11123.9 + ,1 + ,12909.3 + ,1 + ,11339.9 + ,1 + ,10462.2 + ,1 + ,12733.5 + ,1 + ,10519.2 + ,1 + ,10414.9 + ,1 + ,12476.8 + ,1 + ,12384.6 + ,1 + ,12266.7 + ,1 + ,12919.9 + ,1 + ,11497.3 + ,1 + ,12142 + ,1 + ,13919.4 + ,1 + ,12656.8 + ,1 + ,12034.1 + ,1 + ,13199.7 + ,1 + ,10881.3 + ,1 + ,11301.2 + ,1 + ,13643.9 + ,1 + ,12517 + ,1 + ,13981.1 + ,1 + ,14275.7 + ,1 + ,13435 + ,1 + ,13565.7 + ,1 + ,16216.3 + ,1 + ,12970 + ,1 + ,14079.9 + ,1 + ,14235 + ,1 + ,12213.4 + ,1 + ,12581 + ,1) + ,dim=c(2 + ,121) + ,dimnames=list(c('y' + ,'x') + ,1:121)) > y <- array(NA,dim=c(2,121),dimnames=list(c('y','x'),1:121)) > for (i in 1:dim(x)[1]) + { + for (j in 1:dim(x)[2]) + { + y[i,j] <- as.numeric(x[i,j]) + } + } > par3 = 'Linear Trend' > par2 = 'Include Monthly Dummies' > par1 = '1' > #'GNU S' R Code compiled by R2WASP v. 1.0.44 () > #Author: Prof. Dr. P. Wessa > #To cite this work: AUTHOR(S), (YEAR), YOUR SOFTWARE TITLE (vNUMBER) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_YOURPAGE.wasp/ > #Source of accompanying publication: Office for Research, Development, and Education > #Technical description: Write here your technical program description (don't use hard returns!) > library(lattice) > library(lmtest) Loading required package: zoo Attaching package: 'zoo' The following object(s) are masked from package:base : as.Date.numeric > n25 <- 25 #minimum number of obs. for Goldfeld-Quandt test > par1 <- as.numeric(par1) > x <- t(y) > k <- length(x[1,]) > n <- length(x[,1]) > x1 <- cbind(x[,par1], x[,1:k!=par1]) > mycolnames <- c(colnames(x)[par1], colnames(x)[1:k!=par1]) > colnames(x1) <- mycolnames #colnames(x)[par1] > x <- x1 > if (par3 == 'First Differences'){ + x2 <- array(0, dim=c(n-1,k), dimnames=list(1:(n-1), paste('(1-B)',colnames(x),sep=''))) + for (i in 1:n-1) { + for (j in 1:k) { + x2[i,j] <- x[i+1,j] - x[i,j] + } + } + x <- x2 + } > if (par2 == 'Include Monthly Dummies'){ + x2 <- array(0, dim=c(n,11), dimnames=list(1:n, paste('M', seq(1:11), sep =''))) + for (i in 1:11){ + x2[seq(i,n,12),i] <- 1 + } + x <- cbind(x, x2) + } > if (par2 == 'Include Quarterly Dummies'){ + x2 <- array(0, dim=c(n,3), dimnames=list(1:n, paste('Q', seq(1:3), sep =''))) + for (i in 1:3){ + x2[seq(i,n,4),i] <- 1 + } + x <- cbind(x, x2) + } > k <- length(x[1,]) > if (par3 == 'Linear Trend'){ + x <- cbind(x, c(1:n)) + colnames(x)[k+1] <- 't' + } > x y x M1 M2 M3 M4 M5 M6 M7 M8 M9 M10 M11 t 1 6340.5 0 1 0 0 0 0 0 0 0 0 0 0 1 2 7901.5 0 0 1 0 0 0 0 0 0 0 0 0 2 3 8191.1 0 0 0 1 0 0 0 0 0 0 0 0 3 4 7181.7 0 0 0 0 1 0 0 0 0 0 0 0 4 5 7594.4 0 0 0 0 0 1 0 0 0 0 0 0 5 6 7384.7 0 0 0 0 0 0 1 0 0 0 0 0 6 7 7876.7 0 0 0 0 0 0 0 1 0 0 0 0 7 8 8463.4 0 0 0 0 0 0 0 0 1 0 0 0 8 9 8317.2 0 0 0 0 0 0 0 0 0 1 0 0 9 10 7778.7 0 0 0 0 0 0 0 0 0 0 1 0 10 11 8532.8 0 0 0 0 0 0 0 0 0 0 0 1 11 12 7272.2 0 0 0 0 0 0 0 0 0 0 0 0 12 13 6680.1 0 1 0 0 0 0 0 0 0 0 0 0 13 14 8427.6 0 0 1 0 0 0 0 0 0 0 0 0 14 15 8752.8 0 0 0 1 0 0 0 0 0 0 0 0 15 16 7952.7 0 0 0 0 1 0 0 0 0 0 0 0 16 17 8694.3 0 0 0 0 0 1 0 0 0 0 0 0 17 18 7787.0 0 0 0 0 0 0 1 0 0 0 0 0 18 19 8474.2 0 0 0 0 0 0 0 1 0 0 0 0 19 20 9154.7 0 0 0 0 0 0 0 0 1 0 0 0 20 21 8557.2 0 0 0 0 0 0 0 0 0 1 0 0 21 22 7951.1 0 0 0 0 0 0 0 0 0 0 1 0 22 23 9156.7 0 0 0 0 0 0 0 0 0 0 0 1 23 24 7865.7 0 0 0 0 0 0 0 0 0 0 0 0 24 25 7337.4 0 1 0 0 0 0 0 0 0 0 0 0 25 26 9131.7 0 0 1 0 0 0 0 0 0 0 0 0 26 27 8814.6 0 0 0 1 0 0 0 0 0 0 0 0 27 28 8598.8 0 0 0 0 1 0 0 0 0 0 0 0 28 29 8439.6 0 0 0 0 0 1 0 0 0 0 0 0 29 30 7451.8 0 0 0 0 0 0 1 0 0 0 0 0 30 31 8016.2 0 0 0 0 0 0 0 1 0 0 0 0 31 32 9544.1 0 0 0 0 0 0 0 0 1 0 0 0 32 33 8270.7 0 0 0 0 0 0 0 0 0 1 0 0 33 34 8102.2 0 0 0 0 0 0 0 0 0 0 1 0 34 35 9369.0 0 0 0 0 0 0 0 0 0 0 0 1 35 36 7657.7 0 0 0 0 0 0 0 0 0 0 0 0 36 37 7816.6 0 1 0 0 0 0 0 0 0 0 0 0 37 38 9391.3 0 0 1 0 0 0 0 0 0 0 0 0 38 39 9445.4 0 0 0 1 0 0 0 0 0 0 0 0 39 40 9533.1 0 0 0 0 1 0 0 0 0 0 0 0 40 41 10068.7 0 0 0 0 0 1 0 0 0 0 0 0 41 42 8955.5 0 0 0 0 0 0 1 0 0 0 0 0 42 43 10423.9 0 0 0 0 0 0 0 1 0 0 0 0 43 44 11617.2 0 0 0 0 0 0 0 0 1 0 0 0 44 45 9391.1 0 0 0 0 0 0 0 0 0 1 0 0 45 46 10872.0 0 0 0 0 0 0 0 0 0 0 1 0 46 47 10230.4 0 0 0 0 0 0 0 0 0 0 0 1 47 48 9221.0 0 0 0 0 0 0 0 0 0 0 0 0 48 49 9428.6 0 1 0 0 0 0 0 0 0 0 0 0 49 50 10934.5 0 0 1 0 0 0 0 0 0 0 0 0 50 51 10986.0 0 0 0 1 0 0 0 0 0 0 0 0 51 52 11724.6 0 0 0 0 1 0 0 0 0 0 0 0 52 53 11180.9 0 0 0 0 0 1 0 0 0 0 0 0 53 54 11163.2 0 0 0 0 0 0 1 0 0 0 0 0 54 55 11240.9 0 0 0 0 0 0 0 1 0 0 0 0 55 56 12107.1 0 0 0 0 0 0 0 0 1 0 0 0 56 57 10762.3 0 0 0 0 0 0 0 0 0 1 0 0 57 58 11340.4 0 0 0 0 0 0 0 0 0 0 1 0 58 59 11266.8 0 0 0 0 0 0 0 0 0 0 0 1 59 60 9542.7 0 0 0 0 0 0 0 0 0 0 0 0 60 61 9227.7 0 1 0 0 0 0 0 0 0 0 0 0 61 62 10571.9 0 0 1 0 0 0 0 0 0 0 0 0 62 63 10774.4 0 0 0 1 0 0 0 0 0 0 0 0 63 64 10392.8 0 0 0 0 1 0 0 0 0 0 0 0 64 65 9920.2 0 0 0 0 0 1 0 0 0 0 0 0 65 66 9884.9 1 0 0 0 0 0 1 0 0 0 0 0 66 67 10174.5 1 0 0 0 0 0 0 1 0 0 0 0 67 68 11395.4 1 0 0 0 0 0 0 0 1 0 0 0 68 69 10760.2 1 0 0 0 0 0 0 0 0 1 0 0 69 70 10570.1 1 0 0 0 0 0 0 0 0 0 1 0 70 71 10536.0 1 0 0 0 0 0 0 0 0 0 0 1 71 72 9902.6 1 0 0 0 0 0 0 0 0 0 0 0 72 73 8889.0 1 1 0 0 0 0 0 0 0 0 0 0 73 74 10837.3 1 0 1 0 0 0 0 0 0 0 0 0 74 75 11624.1 1 0 0 1 0 0 0 0 0 0 0 0 75 76 10509.0 1 0 0 0 1 0 0 0 0 0 0 0 76 77 10984.9 1 0 0 0 0 1 0 0 0 0 0 0 77 78 10649.1 1 0 0 0 0 0 1 0 0 0 0 0 78 79 10855.7 1 0 0 0 0 0 0 1 0 0 0 0 79 80 11677.4 1 0 0 0 0 0 0 0 1 0 0 0 80 81 10760.2 1 0 0 0 0 0 0 0 0 1 0 0 81 82 10046.2 1 0 0 0 0 0 0 0 0 0 1 0 82 83 10772.8 1 0 0 0 0 0 0 0 0 0 0 1 83 84 9987.7 1 0 0 0 0 0 0 0 0 0 0 0 84 85 8638.7 1 1 0 0 0 0 0 0 0 0 0 0 85 86 11063.7 1 0 1 0 0 0 0 0 0 0 0 0 86 87 11855.7 1 0 0 1 0 0 0 0 0 0 0 0 87 88 10684.5 1 0 0 0 1 0 0 0 0 0 0 0 88 89 11337.4 1 0 0 0 0 1 0 0 0 0 0 0 89 90 10478.0 1 0 0 0 0 0 1 0 0 0 0 0 90 91 11123.9 1 0 0 0 0 0 0 1 0 0 0 0 91 92 12909.3 1 0 0 0 0 0 0 0 1 0 0 0 92 93 11339.9 1 0 0 0 0 0 0 0 0 1 0 0 93 94 10462.2 1 0 0 0 0 0 0 0 0 0 1 0 94 95 12733.5 1 0 0 0 0 0 0 0 0 0 0 1 95 96 10519.2 1 0 0 0 0 0 0 0 0 0 0 0 96 97 10414.9 1 1 0 0 0 0 0 0 0 0 0 0 97 98 12476.8 1 0 1 0 0 0 0 0 0 0 0 0 98 99 12384.6 1 0 0 1 0 0 0 0 0 0 0 0 99 100 12266.7 1 0 0 0 1 0 0 0 0 0 0 0 100 101 12919.9 1 0 0 0 0 1 0 0 0 0 0 0 101 102 11497.3 1 0 0 0 0 0 1 0 0 0 0 0 102 103 12142.0 1 0 0 0 0 0 0 1 0 0 0 0 103 104 13919.4 1 0 0 0 0 0 0 0 1 0 0 0 104 105 12656.8 1 0 0 0 0 0 0 0 0 1 0 0 105 106 12034.1 1 0 0 0 0 0 0 0 0 0 1 0 106 107 13199.7 1 0 0 0 0 0 0 0 0 0 0 1 107 108 10881.3 1 0 0 0 0 0 0 0 0 0 0 0 108 109 11301.2 1 1 0 0 0 0 0 0 0 0 0 0 109 110 13643.9 1 0 1 0 0 0 0 0 0 0 0 0 110 111 12517.0 1 0 0 1 0 0 0 0 0 0 0 0 111 112 13981.1 1 0 0 0 1 0 0 0 0 0 0 0 112 113 14275.7 1 0 0 0 0 1 0 0 0 0 0 0 113 114 13435.0 1 0 0 0 0 0 1 0 0 0 0 0 114 115 13565.7 1 0 0 0 0 0 0 1 0 0 0 0 115 116 16216.3 1 0 0 0 0 0 0 0 1 0 0 0 116 117 12970.0 1 0 0 0 0 0 0 0 0 1 0 0 117 118 14079.9 1 0 0 0 0 0 0 0 0 0 1 0 118 119 14235.0 1 0 0 0 0 0 0 0 0 0 0 1 119 120 12213.4 1 0 0 0 0 0 0 0 0 0 0 0 120 121 12581.0 1 1 0 0 0 0 0 0 0 0 0 0 121 > k <- length(x[1,]) > df <- as.data.frame(x) > (mylm <- lm(df)) Call: lm(formula = df) Coefficients: (Intercept) x M1 M2 M3 M4 5906.22 -1277.30 -274.59 1446.18 1478.51 1162.21 M5 M6 M7 M8 M9 M10 1357.09 747.64 1204.14 2450.98 1064.88 945.79 M11 t 1561.14 64.22 > (mysum <- summary(mylm)) Call: lm(formula = df) Residuals: Min 1Q Median 3Q Max -1517.665 -348.343 9.971 370.902 1686.429 Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) 5906.222 224.516 26.306 < 2e-16 *** x -1277.304 216.050 -5.912 4.09e-08 *** M1 -274.590 259.807 -1.057 0.292939 M2 1446.179 266.279 5.431 3.54e-07 *** M3 1478.505 266.156 5.555 2.05e-07 *** M4 1162.211 266.069 4.368 2.91e-05 *** M5 1357.087 266.017 5.102 1.47e-06 *** M6 747.644 266.421 2.806 0.005956 ** M7 1204.140 266.225 4.523 1.58e-05 *** M8 2450.976 266.064 9.212 3.10e-15 *** M9 1064.882 265.939 4.004 0.000115 *** M10 945.788 265.850 3.558 0.000559 *** M11 1561.144 265.796 5.873 4.88e-08 *** t 64.224 3.083 20.835 < 2e-16 *** --- Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 Residual standard error: 594.3 on 107 degrees of freedom Multiple R-squared: 0.9157, Adjusted R-squared: 0.9054 F-statistic: 89.38 on 13 and 107 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,] 7.220724e-02 1.444145e-01 0.9277928 [2,] 2.968931e-02 5.937862e-02 0.9703107 [3,] 9.097970e-03 1.819594e-02 0.9909020 [4,] 2.656654e-03 5.313307e-03 0.9973433 [5,] 1.803323e-03 3.606647e-03 0.9981967 [6,] 1.273638e-03 2.547276e-03 0.9987264 [7,] 4.103731e-04 8.207462e-04 0.9995896 [8,] 1.299169e-04 2.598337e-04 0.9998701 [9,] 3.723305e-05 7.446610e-05 0.9999628 [10,] 1.213697e-05 2.427394e-05 0.9999879 [11,] 2.496240e-05 4.992479e-05 0.9999750 [12,] 1.157674e-05 2.315348e-05 0.9999884 [13,] 1.955786e-05 3.911572e-05 0.9999804 [14,] 2.631757e-04 5.263515e-04 0.9997368 [15,] 9.792892e-04 1.958578e-03 0.9990207 [16,] 5.824541e-04 1.164908e-03 0.9994175 [17,] 1.248729e-03 2.497458e-03 0.9987513 [18,] 9.440721e-04 1.888144e-03 0.9990559 [19,] 4.697381e-04 9.394761e-04 0.9995303 [20,] 3.705778e-04 7.411557e-04 0.9996294 [21,] 2.526683e-04 5.053365e-04 0.9997473 [22,] 1.384033e-04 2.768065e-04 0.9998616 [23,] 7.137003e-05 1.427401e-04 0.9999286 [24,] 2.460022e-04 4.920043e-04 0.9997540 [25,] 9.519929e-04 1.903986e-03 0.9990480 [26,] 9.408564e-04 1.881713e-03 0.9990591 [27,] 7.156611e-03 1.431322e-02 0.9928434 [28,] 3.585347e-02 7.170694e-02 0.9641465 [29,] 2.689678e-02 5.379355e-02 0.9731032 [30,] 1.392767e-01 2.785533e-01 0.8607233 [31,] 1.089326e-01 2.178652e-01 0.8910674 [32,] 9.037702e-02 1.807540e-01 0.9096230 [33,] 1.086520e-01 2.173040e-01 0.8913480 [34,] 1.022763e-01 2.045526e-01 0.8977237 [35,] 9.182705e-02 1.836541e-01 0.9081730 [36,] 2.872796e-01 5.745592e-01 0.7127204 [37,] 2.908812e-01 5.817624e-01 0.7091188 [38,] 4.508175e-01 9.016350e-01 0.5491825 [39,] 4.757491e-01 9.514983e-01 0.5242509 [40,] 4.361673e-01 8.723347e-01 0.5638327 [41,] 3.943838e-01 7.887676e-01 0.6056162 [42,] 5.009267e-01 9.981466e-01 0.4990733 [43,] 4.739253e-01 9.478506e-01 0.5260747 [44,] 4.609799e-01 9.219597e-01 0.5390201 [45,] 4.850744e-01 9.701489e-01 0.5149256 [46,] 4.877674e-01 9.755348e-01 0.5122326 [47,] 4.841288e-01 9.682575e-01 0.5158712 [48,] 5.053946e-01 9.892108e-01 0.4946054 [49,] 5.735370e-01 8.529260e-01 0.4264630 [50,] 5.368241e-01 9.263518e-01 0.4631759 [51,] 4.971057e-01 9.942114e-01 0.5028943 [52,] 4.381049e-01 8.762099e-01 0.5618951 [53,] 4.788304e-01 9.576607e-01 0.5211696 [54,] 5.445989e-01 9.108022e-01 0.4554011 [55,] 4.980805e-01 9.961610e-01 0.5019195 [56,] 6.279354e-01 7.441292e-01 0.3720646 [57,] 6.255216e-01 7.489568e-01 0.3744784 [58,] 5.881222e-01 8.237555e-01 0.4118778 [59,] 7.442517e-01 5.114965e-01 0.2557483 [60,] 7.068838e-01 5.862323e-01 0.2931162 [61,] 6.596706e-01 6.806589e-01 0.3403294 [62,] 7.172547e-01 5.654907e-01 0.2827453 [63,] 7.404629e-01 5.190742e-01 0.2595371 [64,] 7.089623e-01 5.820754e-01 0.2910377 [65,] 7.172478e-01 5.655044e-01 0.2827522 [66,] 7.094096e-01 5.811809e-01 0.2905904 [67,] 6.785502e-01 6.428995e-01 0.3214498 [68,] 7.824824e-01 4.350352e-01 0.2175176 [69,] 7.919592e-01 4.160816e-01 0.2080408 [70,] 7.460459e-01 5.079081e-01 0.2539541 [71,] 8.513979e-01 2.972042e-01 0.1486021 [72,] 8.472345e-01 3.055310e-01 0.1527655 [73,] 8.199860e-01 3.600280e-01 0.1800140 [74,] 7.766644e-01 4.466712e-01 0.2233356 [75,] 7.174793e-01 5.650415e-01 0.2825207 [76,] 6.733345e-01 6.533310e-01 0.3266655 [77,] 6.077469e-01 7.845062e-01 0.3922531 [78,] 6.845931e-01 6.308138e-01 0.3154069 [79,] 7.086799e-01 5.826403e-01 0.2913201 [80,] 7.427573e-01 5.144854e-01 0.2572427 [81,] 6.935597e-01 6.128807e-01 0.3064403 [82,] 6.075232e-01 7.849535e-01 0.3924768 [83,] 7.839183e-01 4.321634e-01 0.2160817 [84,] 7.029277e-01 5.941445e-01 0.2970723 [85,] 6.024273e-01 7.951453e-01 0.3975727 [86,] 5.270876e-01 9.458249e-01 0.4729124 [87,] 3.825451e-01 7.650902e-01 0.6174549 [88,] 4.668709e-01 9.337417e-01 0.5331291 > postscript(file="/var/www/html/rcomp/tmp/1ihxa1229176166.ps",horizontal=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/html/rcomp/tmp/2snzw1229176166.ps",horizontal=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/html/rcomp/tmp/3ca5i1229176166.ps",horizontal=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/html/rcomp/tmp/41z8e1229176166.ps",horizontal=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/html/rcomp/tmp/5mzdf1229176166.ps",horizontal=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 = 121 Frequency = 1 1 2 3 4 5 6 644.643649 420.651139 613.701139 -143.628861 9.971139 345.490738 7 8 9 10 11 12 316.770738 -407.589262 768.080738 284.450738 358.970738 595.290738 13 14 15 16 17 18 213.556373 176.063863 404.713863 -143.316137 339.183863 -22.896538 19 20 21 22 23 24 143.583462 -486.976538 237.393462 -313.836538 212.183462 418.103462 25 26 27 28 29 30 100.169097 109.476586 -304.173414 -267.903414 -686.203414 -1128.783815 31 32 33 34 35 36 -1085.103815 -868.263815 -819.793815 -933.423815 -346.203815 -560.583815 37 38 39 40 41 42 -191.318180 -401.610690 -444.060690 -104.290690 172.209310 -395.771091 43 44 45 46 47 48 551.908909 434.148909 -470.081091 1065.688909 -255.491091 232.028909 49 50 51 52 53 54 649.994544 370.902034 325.852034 1316.522034 513.722034 1041.241633 55 56 57 58 59 60 598.221633 153.361633 130.431633 763.401633 10.221633 -216.958367 61 62 63 64 65 66 -321.592732 -762.385242 -656.435242 -785.965242 -1517.665242 269.558367 67 68 69 70 71 72 38.438367 -51.721633 634.948367 499.718367 -213.961633 649.558367 73 74 75 76 77 78 -153.675998 9.631492 699.881492 -163.148508 53.651492 263.071091 79 80 81 82 83 84 -51.048909 -540.408909 -135.738909 -794.868909 -747.848909 -36.028909 85 86 87 88 89 90 -1174.663274 -534.655784 160.794216 -758.335784 -364.535784 -678.716185 91 92 93 94 95 96 -553.536185 -79.196185 -326.726185 -1149.556185 442.163815 -275.216185 97 98 99 100 101 102 -169.150550 107.756939 -80.993061 53.176939 447.276939 -430.103462 103 104 105 106 107 108 -306.123462 160.216538 219.486538 -348.343462 137.676538 -683.803462 109 110 111 112 113 114 -53.537827 504.169663 -719.280337 996.889663 1032.389663 736.909262 115 116 117 118 119 120 346.889262 1686.429262 -238.000738 926.769262 402.289262 -122.390738 121 455.574897 > postscript(file="/var/www/html/rcomp/tmp/6wxmd1229176166.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > dum <- cbind(lag(myerror,k=1),myerror) > dum Time Series: Start = 0 End = 121 Frequency = 1 lag(myerror, k = 1) myerror 0 644.643649 NA 1 420.651139 644.643649 2 613.701139 420.651139 3 -143.628861 613.701139 4 9.971139 -143.628861 5 345.490738 9.971139 6 316.770738 345.490738 7 -407.589262 316.770738 8 768.080738 -407.589262 9 284.450738 768.080738 10 358.970738 284.450738 11 595.290738 358.970738 12 213.556373 595.290738 13 176.063863 213.556373 14 404.713863 176.063863 15 -143.316137 404.713863 16 339.183863 -143.316137 17 -22.896538 339.183863 18 143.583462 -22.896538 19 -486.976538 143.583462 20 237.393462 -486.976538 21 -313.836538 237.393462 22 212.183462 -313.836538 23 418.103462 212.183462 24 100.169097 418.103462 25 109.476586 100.169097 26 -304.173414 109.476586 27 -267.903414 -304.173414 28 -686.203414 -267.903414 29 -1128.783815 -686.203414 30 -1085.103815 -1128.783815 31 -868.263815 -1085.103815 32 -819.793815 -868.263815 33 -933.423815 -819.793815 34 -346.203815 -933.423815 35 -560.583815 -346.203815 36 -191.318180 -560.583815 37 -401.610690 -191.318180 38 -444.060690 -401.610690 39 -104.290690 -444.060690 40 172.209310 -104.290690 41 -395.771091 172.209310 42 551.908909 -395.771091 43 434.148909 551.908909 44 -470.081091 434.148909 45 1065.688909 -470.081091 46 -255.491091 1065.688909 47 232.028909 -255.491091 48 649.994544 232.028909 49 370.902034 649.994544 50 325.852034 370.902034 51 1316.522034 325.852034 52 513.722034 1316.522034 53 1041.241633 513.722034 54 598.221633 1041.241633 55 153.361633 598.221633 56 130.431633 153.361633 57 763.401633 130.431633 58 10.221633 763.401633 59 -216.958367 10.221633 60 -321.592732 -216.958367 61 -762.385242 -321.592732 62 -656.435242 -762.385242 63 -785.965242 -656.435242 64 -1517.665242 -785.965242 65 269.558367 -1517.665242 66 38.438367 269.558367 67 -51.721633 38.438367 68 634.948367 -51.721633 69 499.718367 634.948367 70 -213.961633 499.718367 71 649.558367 -213.961633 72 -153.675998 649.558367 73 9.631492 -153.675998 74 699.881492 9.631492 75 -163.148508 699.881492 76 53.651492 -163.148508 77 263.071091 53.651492 78 -51.048909 263.071091 79 -540.408909 -51.048909 80 -135.738909 -540.408909 81 -794.868909 -135.738909 82 -747.848909 -794.868909 83 -36.028909 -747.848909 84 -1174.663274 -36.028909 85 -534.655784 -1174.663274 86 160.794216 -534.655784 87 -758.335784 160.794216 88 -364.535784 -758.335784 89 -678.716185 -364.535784 90 -553.536185 -678.716185 91 -79.196185 -553.536185 92 -326.726185 -79.196185 93 -1149.556185 -326.726185 94 442.163815 -1149.556185 95 -275.216185 442.163815 96 -169.150550 -275.216185 97 107.756939 -169.150550 98 -80.993061 107.756939 99 53.176939 -80.993061 100 447.276939 53.176939 101 -430.103462 447.276939 102 -306.123462 -430.103462 103 160.216538 -306.123462 104 219.486538 160.216538 105 -348.343462 219.486538 106 137.676538 -348.343462 107 -683.803462 137.676538 108 -53.537827 -683.803462 109 504.169663 -53.537827 110 -719.280337 504.169663 111 996.889663 -719.280337 112 1032.389663 996.889663 113 736.909262 1032.389663 114 346.889262 736.909262 115 1686.429262 346.889262 116 -238.000738 1686.429262 117 926.769262 -238.000738 118 402.289262 926.769262 119 -122.390738 402.289262 120 455.574897 -122.390738 121 NA 455.574897 > dum1 <- dum[2:length(myerror),] > dum1 lag(myerror, k = 1) myerror [1,] 420.651139 644.643649 [2,] 613.701139 420.651139 [3,] -143.628861 613.701139 [4,] 9.971139 -143.628861 [5,] 345.490738 9.971139 [6,] 316.770738 345.490738 [7,] -407.589262 316.770738 [8,] 768.080738 -407.589262 [9,] 284.450738 768.080738 [10,] 358.970738 284.450738 [11,] 595.290738 358.970738 [12,] 213.556373 595.290738 [13,] 176.063863 213.556373 [14,] 404.713863 176.063863 [15,] -143.316137 404.713863 [16,] 339.183863 -143.316137 [17,] -22.896538 339.183863 [18,] 143.583462 -22.896538 [19,] -486.976538 143.583462 [20,] 237.393462 -486.976538 [21,] -313.836538 237.393462 [22,] 212.183462 -313.836538 [23,] 418.103462 212.183462 [24,] 100.169097 418.103462 [25,] 109.476586 100.169097 [26,] -304.173414 109.476586 [27,] -267.903414 -304.173414 [28,] -686.203414 -267.903414 [29,] -1128.783815 -686.203414 [30,] -1085.103815 -1128.783815 [31,] -868.263815 -1085.103815 [32,] -819.793815 -868.263815 [33,] -933.423815 -819.793815 [34,] -346.203815 -933.423815 [35,] -560.583815 -346.203815 [36,] -191.318180 -560.583815 [37,] -401.610690 -191.318180 [38,] -444.060690 -401.610690 [39,] -104.290690 -444.060690 [40,] 172.209310 -104.290690 [41,] -395.771091 172.209310 [42,] 551.908909 -395.771091 [43,] 434.148909 551.908909 [44,] -470.081091 434.148909 [45,] 1065.688909 -470.081091 [46,] -255.491091 1065.688909 [47,] 232.028909 -255.491091 [48,] 649.994544 232.028909 [49,] 370.902034 649.994544 [50,] 325.852034 370.902034 [51,] 1316.522034 325.852034 [52,] 513.722034 1316.522034 [53,] 1041.241633 513.722034 [54,] 598.221633 1041.241633 [55,] 153.361633 598.221633 [56,] 130.431633 153.361633 [57,] 763.401633 130.431633 [58,] 10.221633 763.401633 [59,] -216.958367 10.221633 [60,] -321.592732 -216.958367 [61,] -762.385242 -321.592732 [62,] -656.435242 -762.385242 [63,] -785.965242 -656.435242 [64,] -1517.665242 -785.965242 [65,] 269.558367 -1517.665242 [66,] 38.438367 269.558367 [67,] -51.721633 38.438367 [68,] 634.948367 -51.721633 [69,] 499.718367 634.948367 [70,] -213.961633 499.718367 [71,] 649.558367 -213.961633 [72,] -153.675998 649.558367 [73,] 9.631492 -153.675998 [74,] 699.881492 9.631492 [75,] -163.148508 699.881492 [76,] 53.651492 -163.148508 [77,] 263.071091 53.651492 [78,] -51.048909 263.071091 [79,] -540.408909 -51.048909 [80,] -135.738909 -540.408909 [81,] -794.868909 -135.738909 [82,] -747.848909 -794.868909 [83,] -36.028909 -747.848909 [84,] -1174.663274 -36.028909 [85,] -534.655784 -1174.663274 [86,] 160.794216 -534.655784 [87,] -758.335784 160.794216 [88,] -364.535784 -758.335784 [89,] -678.716185 -364.535784 [90,] -553.536185 -678.716185 [91,] -79.196185 -553.536185 [92,] -326.726185 -79.196185 [93,] -1149.556185 -326.726185 [94,] 442.163815 -1149.556185 [95,] -275.216185 442.163815 [96,] -169.150550 -275.216185 [97,] 107.756939 -169.150550 [98,] -80.993061 107.756939 [99,] 53.176939 -80.993061 [100,] 447.276939 53.176939 [101,] -430.103462 447.276939 [102,] -306.123462 -430.103462 [103,] 160.216538 -306.123462 [104,] 219.486538 160.216538 [105,] -348.343462 219.486538 [106,] 137.676538 -348.343462 [107,] -683.803462 137.676538 [108,] -53.537827 -683.803462 [109,] 504.169663 -53.537827 [110,] -719.280337 504.169663 [111,] 996.889663 -719.280337 [112,] 1032.389663 996.889663 [113,] 736.909262 1032.389663 [114,] 346.889262 736.909262 [115,] 1686.429262 346.889262 [116,] -238.000738 1686.429262 [117,] 926.769262 -238.000738 [118,] 402.289262 926.769262 [119,] -122.390738 402.289262 [120,] 455.574897 -122.390738 > z <- as.data.frame(dum1) > z lag(myerror, k = 1) myerror 1 420.651139 644.643649 2 613.701139 420.651139 3 -143.628861 613.701139 4 9.971139 -143.628861 5 345.490738 9.971139 6 316.770738 345.490738 7 -407.589262 316.770738 8 768.080738 -407.589262 9 284.450738 768.080738 10 358.970738 284.450738 11 595.290738 358.970738 12 213.556373 595.290738 13 176.063863 213.556373 14 404.713863 176.063863 15 -143.316137 404.713863 16 339.183863 -143.316137 17 -22.896538 339.183863 18 143.583462 -22.896538 19 -486.976538 143.583462 20 237.393462 -486.976538 21 -313.836538 237.393462 22 212.183462 -313.836538 23 418.103462 212.183462 24 100.169097 418.103462 25 109.476586 100.169097 26 -304.173414 109.476586 27 -267.903414 -304.173414 28 -686.203414 -267.903414 29 -1128.783815 -686.203414 30 -1085.103815 -1128.783815 31 -868.263815 -1085.103815 32 -819.793815 -868.263815 33 -933.423815 -819.793815 34 -346.203815 -933.423815 35 -560.583815 -346.203815 36 -191.318180 -560.583815 37 -401.610690 -191.318180 38 -444.060690 -401.610690 39 -104.290690 -444.060690 40 172.209310 -104.290690 41 -395.771091 172.209310 42 551.908909 -395.771091 43 434.148909 551.908909 44 -470.081091 434.148909 45 1065.688909 -470.081091 46 -255.491091 1065.688909 47 232.028909 -255.491091 48 649.994544 232.028909 49 370.902034 649.994544 50 325.852034 370.902034 51 1316.522034 325.852034 52 513.722034 1316.522034 53 1041.241633 513.722034 54 598.221633 1041.241633 55 153.361633 598.221633 56 130.431633 153.361633 57 763.401633 130.431633 58 10.221633 763.401633 59 -216.958367 10.221633 60 -321.592732 -216.958367 61 -762.385242 -321.592732 62 -656.435242 -762.385242 63 -785.965242 -656.435242 64 -1517.665242 -785.965242 65 269.558367 -1517.665242 66 38.438367 269.558367 67 -51.721633 38.438367 68 634.948367 -51.721633 69 499.718367 634.948367 70 -213.961633 499.718367 71 649.558367 -213.961633 72 -153.675998 649.558367 73 9.631492 -153.675998 74 699.881492 9.631492 75 -163.148508 699.881492 76 53.651492 -163.148508 77 263.071091 53.651492 78 -51.048909 263.071091 79 -540.408909 -51.048909 80 -135.738909 -540.408909 81 -794.868909 -135.738909 82 -747.848909 -794.868909 83 -36.028909 -747.848909 84 -1174.663274 -36.028909 85 -534.655784 -1174.663274 86 160.794216 -534.655784 87 -758.335784 160.794216 88 -364.535784 -758.335784 89 -678.716185 -364.535784 90 -553.536185 -678.716185 91 -79.196185 -553.536185 92 -326.726185 -79.196185 93 -1149.556185 -326.726185 94 442.163815 -1149.556185 95 -275.216185 442.163815 96 -169.150550 -275.216185 97 107.756939 -169.150550 98 -80.993061 107.756939 99 53.176939 -80.993061 100 447.276939 53.176939 101 -430.103462 447.276939 102 -306.123462 -430.103462 103 160.216538 -306.123462 104 219.486538 160.216538 105 -348.343462 219.486538 106 137.676538 -348.343462 107 -683.803462 137.676538 108 -53.537827 -683.803462 109 504.169663 -53.537827 110 -719.280337 504.169663 111 996.889663 -719.280337 112 1032.389663 996.889663 113 736.909262 1032.389663 114 346.889262 736.909262 115 1686.429262 346.889262 116 -238.000738 1686.429262 117 926.769262 -238.000738 118 402.289262 926.769262 119 -122.390738 402.289262 120 455.574897 -122.390738 > 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/html/rcomp/tmp/712kr1229176166.ps",horizontal=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/html/rcomp/tmp/88z9x1229176166.ps",horizontal=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/html/rcomp/tmp/91iiq1229176166.ps",horizontal=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/www/html/rcomp/tmp/10910i1229176166.ps",horizontal=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/html/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/www/html/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/html/rcomp/tmp/11x68v1229176166.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/html/rcomp/tmp/12sv071229176166.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/html/rcomp/tmp/13s7eg1229176167.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/html/rcomp/tmp/14jpx81229176167.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/html/rcomp/tmp/15ovhg1229176167.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/html/rcomp/tmp/160lpj1229176167.tab") + } > > system("convert tmp/1ihxa1229176166.ps tmp/1ihxa1229176166.png") > system("convert tmp/2snzw1229176166.ps tmp/2snzw1229176166.png") > system("convert tmp/3ca5i1229176166.ps tmp/3ca5i1229176166.png") > system("convert tmp/41z8e1229176166.ps tmp/41z8e1229176166.png") > system("convert tmp/5mzdf1229176166.ps tmp/5mzdf1229176166.png") > system("convert tmp/6wxmd1229176166.ps tmp/6wxmd1229176166.png") > system("convert tmp/712kr1229176166.ps tmp/712kr1229176166.png") > system("convert tmp/88z9x1229176166.ps tmp/88z9x1229176166.png") > system("convert tmp/91iiq1229176166.ps tmp/91iiq1229176166.png") > system("convert tmp/10910i1229176166.ps tmp/10910i1229176166.png") > > > proc.time() user system elapsed 3.392 1.722 3.970