R version 2.15.2 (2012-10-26) -- "Trick or Treat" Copyright (C) 2012 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i686-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,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,1,0,1,1,1,0,0,0,1,1,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,0,0,0,1,0,0,1,0,0,0,0,0,0,0,1,1,1,0,0,0,0,0,1,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,0,1,1,0,0,0,0,0,0,0,1,0,1,0,1,0,0,0,0,0,0,0,0,1,0,1,0,0),dim=c(2,154),dimnames=list(c('Treatment','CorrectAnalysis'),1:154)) > y <- array(NA,dim=c(2,154),dimnames=list(c('Treatment','CorrectAnalysis'),1:154)) > 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' > 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 Attaching package: 'zoo' The following object(s) are masked from 'package:base': as.Date, 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 CorrectAnalysis Treatment 1 0 1 2 0 0 3 0 0 4 0 0 5 0 0 6 0 0 7 0 0 8 0 1 9 0 0 10 0 0 11 0 1 12 0 0 13 0 0 14 0 1 15 0 0 16 0 1 17 1 1 18 0 1 19 0 0 20 1 1 21 0 0 22 0 0 23 0 0 24 0 0 25 0 1 26 0 0 27 0 0 28 0 0 29 0 0 30 0 0 31 0 0 32 0 0 33 0 0 34 0 1 35 0 0 36 0 0 37 0 1 38 0 0 39 0 0 40 0 1 41 1 0 42 0 0 43 0 0 44 0 1 45 0 0 46 0 0 47 0 0 48 0 0 49 0 0 50 0 0 51 0 1 52 1 1 53 0 0 54 1 0 55 0 0 56 0 1 57 0 0 58 0 0 59 0 0 60 1 1 61 0 1 62 0 0 63 0 0 64 0 1 65 0 0 66 0 0 67 1 1 68 0 0 69 0 0 70 0 0 71 0 0 72 0 0 73 0 0 74 0 0 75 0 0 76 0 1 77 0 0 78 0 0 79 1 1 80 0 1 81 0 0 82 0 0 83 0 0 84 1 0 85 0 0 86 0 0 87 0 0 88 0 1 89 0 0 90 0 0 91 0 0 92 0 1 93 0 0 94 0 0 95 0 1 96 0 0 97 0 1 98 0 0 99 0 0 100 0 0 101 0 0 102 0 0 103 0 0 104 0 0 105 0 1 106 0 0 107 0 0 108 0 1 109 0 0 110 0 0 111 0 1 112 0 1 113 0 0 114 0 1 115 0 0 116 0 0 117 0 0 118 0 0 119 0 0 120 0 0 121 0 0 122 0 0 123 0 1 124 0 0 125 0 0 126 0 1 127 0 0 128 0 0 129 0 0 130 0 0 131 0 0 132 0 0 133 0 0 134 0 0 135 0 0 136 0 0 137 0 0 138 0 1 139 0 1 140 0 0 141 1 0 142 0 1 143 0 0 144 0 0 145 0 0 146 0 1 147 0 1 148 0 1 149 0 0 150 0 0 151 0 0 152 1 0 153 1 0 154 0 0 > k <- length(x[1,]) > df <- as.data.frame(x) > (mylm <- lm(df)) Call: lm(formula = df) Coefficients: (Intercept) Treatment 0.05263 0.09737 > (mysum <- summary(mylm)) Call: lm(formula = df) Residuals: Min 1Q Median 3Q Max -0.15000 -0.05263 -0.05263 -0.05263 0.94737 Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) 0.05263 0.02495 2.110 0.0365 * Treatment 0.09737 0.04895 1.989 0.0485 * --- Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 Residual standard error: 0.2664 on 152 degrees of freedom Multiple R-squared: 0.02537, Adjusted R-squared: 0.01896 F-statistic: 3.957 on 1 and 152 DF, p-value: 0.04848 > 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.0000000000 0.0000000000 1.0000000000 [2,] 0.0000000000 0.0000000000 1.0000000000 [3,] 0.0000000000 0.0000000000 1.0000000000 [4,] 0.0000000000 0.0000000000 1.0000000000 [5,] 0.0000000000 0.0000000000 1.0000000000 [6,] 0.0000000000 0.0000000000 1.0000000000 [7,] 0.0000000000 0.0000000000 1.0000000000 [8,] 0.0000000000 0.0000000000 1.0000000000 [9,] 0.0000000000 0.0000000000 1.0000000000 [10,] 0.0000000000 0.0000000000 1.0000000000 [11,] 0.0000000000 0.0000000000 1.0000000000 [12,] 0.0000000000 0.0000000000 1.0000000000 [13,] 0.2769984396 0.5539968792 0.7230015604 [14,] 0.2360283048 0.4720566095 0.7639716952 [15,] 0.1801315917 0.3602631835 0.8198684083 [16,] 0.7319990405 0.5360019190 0.2680009595 [17,] 0.6718749321 0.6562501358 0.3281250679 [18,] 0.6079768716 0.7840462568 0.3920231284 [19,] 0.5420291324 0.9159417352 0.4579708676 [20,] 0.4758484800 0.9516969599 0.5241515200 [21,] 0.4564318029 0.9128636059 0.5435681971 [22,] 0.3933802403 0.7867604806 0.6066197597 [23,] 0.3337252892 0.6674505784 0.6662747108 [24,] 0.2786273676 0.5572547352 0.7213726324 [25,] 0.2289101964 0.4578203929 0.7710898036 [26,] 0.1850492886 0.3700985771 0.8149507114 [27,] 0.1471926098 0.2943852196 0.8528073902 [28,] 0.1152056153 0.2304112307 0.8847943847 [29,] 0.0887313680 0.1774627360 0.9112686320 [30,] 0.0805981450 0.1611962900 0.9194018550 [31,] 0.0609010650 0.1218021300 0.9390989350 [32,] 0.0453042922 0.0906085844 0.9546957078 [33,] 0.0394608303 0.0789216605 0.9605391697 [34,] 0.0287650670 0.0575301341 0.9712349330 [35,] 0.0206529587 0.0413059174 0.9793470413 [36,] 0.0172731832 0.0345463664 0.9827268168 [37,] 0.3946317187 0.7892634375 0.6053682813 [38,] 0.3456168899 0.6912337797 0.6543831101 [39,] 0.2993054104 0.5986108208 0.7006945896 [40,] 0.2703576914 0.5407153829 0.7296423086 [41,] 0.2298143064 0.4596286127 0.7701856936 [42,] 0.1930920887 0.3861841773 0.8069079113 [43,] 0.1603433740 0.3206867480 0.8396566260 [44,] 0.1315820301 0.2631640602 0.8684179699 [45,] 0.1067013259 0.2134026518 0.8932986741 [46,] 0.0854962465 0.1709924931 0.9145037535 [47,] 0.0729956050 0.1459912099 0.9270043950 [48,] 0.3817635362 0.7635270724 0.6182364638 [49,] 0.3367784462 0.6735568923 0.6632215538 [50,] 0.8377203390 0.3245593219 0.1622796610 [51,] 0.8075549317 0.3848901367 0.1924450683 [52,] 0.7866907315 0.4266185370 0.2133092685 [53,] 0.7515558911 0.4968882177 0.2484441089 [54,] 0.7136357917 0.5727284166 0.2863642083 [55,] 0.6732545710 0.6534908580 0.3267454290 [56,] 0.9287495040 0.1425009919 0.0712504960 [57,] 0.9191824035 0.1616351931 0.0808175965 [58,] 0.9008128863 0.1983742274 0.0991871137 [59,] 0.8795981854 0.2408036292 0.1204018146 [60,] 0.8648029739 0.2703940522 0.1351970261 [61,] 0.8387385359 0.3225229281 0.1612614641 [62,] 0.8096414237 0.3807171525 0.1903585763 [63,] 0.9748590754 0.0502818491 0.0251409246 [64,] 0.9675371132 0.0649257737 0.0324628868 [65,] 0.9585499389 0.0829001221 0.0414500611 [66,] 0.9476574509 0.1046850983 0.0523425491 [67,] 0.9346210360 0.1307579280 0.0653789640 [68,] 0.9192134551 0.1615730898 0.0807865449 [69,] 0.9012299980 0.1975400041 0.0987700020 [70,] 0.8805004032 0.2389991936 0.1194995968 [71,] 0.8569008895 0.2861982209 0.1430991105 [72,] 0.8407764711 0.3184470578 0.1592235289 [73,] 0.8123882581 0.3752234839 0.1876117419 [74,] 0.7810961539 0.4378076922 0.2189038461 [75,] 0.9784853276 0.0430293448 0.0215146724 [76,] 0.9746515912 0.0506968176 0.0253484088 [77,] 0.9673669301 0.0652661399 0.0326330699 [78,] 0.9584422854 0.0831154292 0.0415577146 [79,] 0.9476425275 0.1047149450 0.0523574725 [80,] 0.9992596656 0.0014806689 0.0007403344 [81,] 0.9989116974 0.0021766053 0.0010883026 [82,] 0.9984188072 0.0031623856 0.0015811928 [83,] 0.9977293962 0.0045412077 0.0022706038 [84,] 0.9970533925 0.0058932149 0.0029466075 [85,] 0.9958504183 0.0082991634 0.0041495817 [86,] 0.9942239591 0.0115520818 0.0057760409 [87,] 0.9920528521 0.0158942957 0.0079471479 [88,] 0.9898969771 0.0202060459 0.0101030229 [89,] 0.9863714181 0.0272571638 0.0136285819 [90,] 0.9818265393 0.0363469214 0.0181734607 [91,] 0.9772612965 0.0454774069 0.0227387035 [92,] 0.9702775368 0.0594449265 0.0297224632 [93,] 0.9631741501 0.0736516997 0.0368258499 [94,] 0.9528235754 0.0943528492 0.0471764246 [95,] 0.9402459203 0.1195081595 0.0597540797 [96,] 0.9251639556 0.1496720887 0.0748360444 [97,] 0.9073192170 0.1853615659 0.0926807830 [98,] 0.8864874057 0.2270251886 0.1135125943 [99,] 0.8624947333 0.2750105335 0.1375052667 [100,] 0.8352341619 0.3295316762 0.1647658381 [101,] 0.8085509212 0.3828981575 0.1914490788 [102,] 0.7749770654 0.4500458692 0.2250229346 [103,] 0.7382769908 0.5234460184 0.2617230092 [104,] 0.7025465313 0.5949069374 0.2974534687 [105,] 0.6604507142 0.6790985716 0.3395492858 [106,] 0.6162337355 0.7675325290 0.3837662645 [107,] 0.5735678081 0.8528643838 0.4264321919 [108,] 0.5291305603 0.9417388795 0.4708694397 [109,] 0.4814017383 0.9628034766 0.5185982617 [110,] 0.4356581737 0.8713163473 0.5643418263 [111,] 0.3887244453 0.7774488905 0.6112755547 [112,] 0.3433455241 0.6866910481 0.6566544759 [113,] 0.3001208115 0.6002416230 0.6998791885 [114,] 0.2595613304 0.5191226608 0.7404386696 [115,] 0.2220714026 0.4441428052 0.7779285974 [116,] 0.1879374959 0.3758749918 0.8120625041 [117,] 0.1573246877 0.3146493754 0.8426753123 [118,] 0.1302804936 0.2605609873 0.8697195064 [119,] 0.1054155922 0.2108311844 0.8945844078 [120,] 0.0850903383 0.1701806767 0.9149096617 [121,] 0.0679462957 0.1358925913 0.9320537043 [122,] 0.0523161698 0.1046323396 0.9476838302 [123,] 0.0406545858 0.0813091716 0.9593454142 [124,] 0.0312749996 0.0625499992 0.9687250004 [125,] 0.0238424541 0.0476849082 0.9761575459 [126,] 0.0180380482 0.0360760965 0.9819619518 [127,] 0.0135691775 0.0271383550 0.9864308225 [128,] 0.0101760744 0.0203521488 0.9898239256 [129,] 0.0076350455 0.0152700911 0.9923649545 [130,] 0.0057590359 0.0115180717 0.9942409641 [131,] 0.0043963096 0.0087926192 0.9956036904 [132,] 0.0034281739 0.0068563478 0.9965718261 [133,] 0.0027669402 0.0055338804 0.9972330598 [134,] 0.0016567746 0.0033135493 0.9983432254 [135,] 0.0009534765 0.0019069530 0.9990465235 [136,] 0.0007728636 0.0015457273 0.9992271364 [137,] 0.0164201174 0.0328402348 0.9835798826 [138,] 0.0098814084 0.0197628167 0.9901185916 [139,] 0.0072845756 0.0145691512 0.9927154244 [140,] 0.0056541193 0.0113082385 0.9943458807 [141,] 0.0048596286 0.0097192572 0.9951403714 [142,] 0.0023816618 0.0047633236 0.9976183382 [143,] 0.0010572863 0.0021145725 0.9989427137 [144,] 0.0004147927 0.0008295855 0.9995852073 [145,] 0.0003384572 0.0006769145 0.9996615428 > postscript(file="/var/wessaorg/rcomp/tmp/1q8oc1355496697.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/2hluz1355496697.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/3q21f1355496697.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/4n0o21355496697.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/57dzt1355496697.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 = 154 Frequency = 1 1 2 3 4 5 6 -0.15000000 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 7 8 9 10 11 12 -0.05263158 -0.15000000 -0.05263158 -0.05263158 -0.15000000 -0.05263158 13 14 15 16 17 18 -0.05263158 -0.15000000 -0.05263158 -0.15000000 0.85000000 -0.15000000 19 20 21 22 23 24 -0.05263158 0.85000000 -0.05263158 -0.05263158 -0.05263158 -0.05263158 25 26 27 28 29 30 -0.15000000 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 31 32 33 34 35 36 -0.05263158 -0.05263158 -0.05263158 -0.15000000 -0.05263158 -0.05263158 37 38 39 40 41 42 -0.15000000 -0.05263158 -0.05263158 -0.15000000 0.94736842 -0.05263158 43 44 45 46 47 48 -0.05263158 -0.15000000 -0.05263158 -0.05263158 -0.05263158 -0.05263158 49 50 51 52 53 54 -0.05263158 -0.05263158 -0.15000000 0.85000000 -0.05263158 0.94736842 55 56 57 58 59 60 -0.05263158 -0.15000000 -0.05263158 -0.05263158 -0.05263158 0.85000000 61 62 63 64 65 66 -0.15000000 -0.05263158 -0.05263158 -0.15000000 -0.05263158 -0.05263158 67 68 69 70 71 72 0.85000000 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 73 74 75 76 77 78 -0.05263158 -0.05263158 -0.05263158 -0.15000000 -0.05263158 -0.05263158 79 80 81 82 83 84 0.85000000 -0.15000000 -0.05263158 -0.05263158 -0.05263158 0.94736842 85 86 87 88 89 90 -0.05263158 -0.05263158 -0.05263158 -0.15000000 -0.05263158 -0.05263158 91 92 93 94 95 96 -0.05263158 -0.15000000 -0.05263158 -0.05263158 -0.15000000 -0.05263158 97 98 99 100 101 102 -0.15000000 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 103 104 105 106 107 108 -0.05263158 -0.05263158 -0.15000000 -0.05263158 -0.05263158 -0.15000000 109 110 111 112 113 114 -0.05263158 -0.05263158 -0.15000000 -0.15000000 -0.05263158 -0.15000000 115 116 117 118 119 120 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 121 122 123 124 125 126 -0.05263158 -0.05263158 -0.15000000 -0.05263158 -0.05263158 -0.15000000 127 128 129 130 131 132 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 133 134 135 136 137 138 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.05263158 -0.15000000 139 140 141 142 143 144 -0.15000000 -0.05263158 0.94736842 -0.15000000 -0.05263158 -0.05263158 145 146 147 148 149 150 -0.05263158 -0.15000000 -0.15000000 -0.15000000 -0.05263158 -0.05263158 151 152 153 154 -0.05263158 0.94736842 0.94736842 -0.05263158 > postscript(file="/var/wessaorg/rcomp/tmp/6pe7e1355496697.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 = 154 Frequency = 1 lag(myerror, k = 1) myerror 0 -0.15000000 NA 1 -0.05263158 -0.15000000 2 -0.05263158 -0.05263158 3 -0.05263158 -0.05263158 4 -0.05263158 -0.05263158 5 -0.05263158 -0.05263158 6 -0.05263158 -0.05263158 7 -0.15000000 -0.05263158 8 -0.05263158 -0.15000000 9 -0.05263158 -0.05263158 10 -0.15000000 -0.05263158 11 -0.05263158 -0.15000000 12 -0.05263158 -0.05263158 13 -0.15000000 -0.05263158 14 -0.05263158 -0.15000000 15 -0.15000000 -0.05263158 16 0.85000000 -0.15000000 17 -0.15000000 0.85000000 18 -0.05263158 -0.15000000 19 0.85000000 -0.05263158 20 -0.05263158 0.85000000 21 -0.05263158 -0.05263158 22 -0.05263158 -0.05263158 23 -0.05263158 -0.05263158 24 -0.15000000 -0.05263158 25 -0.05263158 -0.15000000 26 -0.05263158 -0.05263158 27 -0.05263158 -0.05263158 28 -0.05263158 -0.05263158 29 -0.05263158 -0.05263158 30 -0.05263158 -0.05263158 31 -0.05263158 -0.05263158 32 -0.05263158 -0.05263158 33 -0.15000000 -0.05263158 34 -0.05263158 -0.15000000 35 -0.05263158 -0.05263158 36 -0.15000000 -0.05263158 37 -0.05263158 -0.15000000 38 -0.05263158 -0.05263158 39 -0.15000000 -0.05263158 40 0.94736842 -0.15000000 41 -0.05263158 0.94736842 42 -0.05263158 -0.05263158 43 -0.15000000 -0.05263158 44 -0.05263158 -0.15000000 45 -0.05263158 -0.05263158 46 -0.05263158 -0.05263158 47 -0.05263158 -0.05263158 48 -0.05263158 -0.05263158 49 -0.05263158 -0.05263158 50 -0.15000000 -0.05263158 51 0.85000000 -0.15000000 52 -0.05263158 0.85000000 53 0.94736842 -0.05263158 54 -0.05263158 0.94736842 55 -0.15000000 -0.05263158 56 -0.05263158 -0.15000000 57 -0.05263158 -0.05263158 58 -0.05263158 -0.05263158 59 0.85000000 -0.05263158 60 -0.15000000 0.85000000 61 -0.05263158 -0.15000000 62 -0.05263158 -0.05263158 63 -0.15000000 -0.05263158 64 -0.05263158 -0.15000000 65 -0.05263158 -0.05263158 66 0.85000000 -0.05263158 67 -0.05263158 0.85000000 68 -0.05263158 -0.05263158 69 -0.05263158 -0.05263158 70 -0.05263158 -0.05263158 71 -0.05263158 -0.05263158 72 -0.05263158 -0.05263158 73 -0.05263158 -0.05263158 74 -0.05263158 -0.05263158 75 -0.15000000 -0.05263158 76 -0.05263158 -0.15000000 77 -0.05263158 -0.05263158 78 0.85000000 -0.05263158 79 -0.15000000 0.85000000 80 -0.05263158 -0.15000000 81 -0.05263158 -0.05263158 82 -0.05263158 -0.05263158 83 0.94736842 -0.05263158 84 -0.05263158 0.94736842 85 -0.05263158 -0.05263158 86 -0.05263158 -0.05263158 87 -0.15000000 -0.05263158 88 -0.05263158 -0.15000000 89 -0.05263158 -0.05263158 90 -0.05263158 -0.05263158 91 -0.15000000 -0.05263158 92 -0.05263158 -0.15000000 93 -0.05263158 -0.05263158 94 -0.15000000 -0.05263158 95 -0.05263158 -0.15000000 96 -0.15000000 -0.05263158 97 -0.05263158 -0.15000000 98 -0.05263158 -0.05263158 99 -0.05263158 -0.05263158 100 -0.05263158 -0.05263158 101 -0.05263158 -0.05263158 102 -0.05263158 -0.05263158 103 -0.05263158 -0.05263158 104 -0.15000000 -0.05263158 105 -0.05263158 -0.15000000 106 -0.05263158 -0.05263158 107 -0.15000000 -0.05263158 108 -0.05263158 -0.15000000 109 -0.05263158 -0.05263158 110 -0.15000000 -0.05263158 111 -0.15000000 -0.15000000 112 -0.05263158 -0.15000000 113 -0.15000000 -0.05263158 114 -0.05263158 -0.15000000 115 -0.05263158 -0.05263158 116 -0.05263158 -0.05263158 117 -0.05263158 -0.05263158 118 -0.05263158 -0.05263158 119 -0.05263158 -0.05263158 120 -0.05263158 -0.05263158 121 -0.05263158 -0.05263158 122 -0.15000000 -0.05263158 123 -0.05263158 -0.15000000 124 -0.05263158 -0.05263158 125 -0.15000000 -0.05263158 126 -0.05263158 -0.15000000 127 -0.05263158 -0.05263158 128 -0.05263158 -0.05263158 129 -0.05263158 -0.05263158 130 -0.05263158 -0.05263158 131 -0.05263158 -0.05263158 132 -0.05263158 -0.05263158 133 -0.05263158 -0.05263158 134 -0.05263158 -0.05263158 135 -0.05263158 -0.05263158 136 -0.05263158 -0.05263158 137 -0.15000000 -0.05263158 138 -0.15000000 -0.15000000 139 -0.05263158 -0.15000000 140 0.94736842 -0.05263158 141 -0.15000000 0.94736842 142 -0.05263158 -0.15000000 143 -0.05263158 -0.05263158 144 -0.05263158 -0.05263158 145 -0.15000000 -0.05263158 146 -0.15000000 -0.15000000 147 -0.15000000 -0.15000000 148 -0.05263158 -0.15000000 149 -0.05263158 -0.05263158 150 -0.05263158 -0.05263158 151 0.94736842 -0.05263158 152 0.94736842 0.94736842 153 -0.05263158 0.94736842 154 NA -0.05263158 > dum1 <- dum[2:length(myerror),] > dum1 lag(myerror, k = 1) myerror [1,] -0.05263158 -0.15000000 [2,] -0.05263158 -0.05263158 [3,] -0.05263158 -0.05263158 [4,] -0.05263158 -0.05263158 [5,] -0.05263158 -0.05263158 [6,] -0.05263158 -0.05263158 [7,] -0.15000000 -0.05263158 [8,] -0.05263158 -0.15000000 [9,] -0.05263158 -0.05263158 [10,] -0.15000000 -0.05263158 [11,] -0.05263158 -0.15000000 [12,] -0.05263158 -0.05263158 [13,] -0.15000000 -0.05263158 [14,] -0.05263158 -0.15000000 [15,] -0.15000000 -0.05263158 [16,] 0.85000000 -0.15000000 [17,] -0.15000000 0.85000000 [18,] -0.05263158 -0.15000000 [19,] 0.85000000 -0.05263158 [20,] -0.05263158 0.85000000 [21,] -0.05263158 -0.05263158 [22,] -0.05263158 -0.05263158 [23,] -0.05263158 -0.05263158 [24,] -0.15000000 -0.05263158 [25,] -0.05263158 -0.15000000 [26,] -0.05263158 -0.05263158 [27,] -0.05263158 -0.05263158 [28,] -0.05263158 -0.05263158 [29,] -0.05263158 -0.05263158 [30,] -0.05263158 -0.05263158 [31,] -0.05263158 -0.05263158 [32,] -0.05263158 -0.05263158 [33,] -0.15000000 -0.05263158 [34,] -0.05263158 -0.15000000 [35,] -0.05263158 -0.05263158 [36,] -0.15000000 -0.05263158 [37,] -0.05263158 -0.15000000 [38,] -0.05263158 -0.05263158 [39,] -0.15000000 -0.05263158 [40,] 0.94736842 -0.15000000 [41,] -0.05263158 0.94736842 [42,] -0.05263158 -0.05263158 [43,] -0.15000000 -0.05263158 [44,] -0.05263158 -0.15000000 [45,] -0.05263158 -0.05263158 [46,] -0.05263158 -0.05263158 [47,] -0.05263158 -0.05263158 [48,] -0.05263158 -0.05263158 [49,] -0.05263158 -0.05263158 [50,] -0.15000000 -0.05263158 [51,] 0.85000000 -0.15000000 [52,] -0.05263158 0.85000000 [53,] 0.94736842 -0.05263158 [54,] -0.05263158 0.94736842 [55,] -0.15000000 -0.05263158 [56,] -0.05263158 -0.15000000 [57,] -0.05263158 -0.05263158 [58,] -0.05263158 -0.05263158 [59,] 0.85000000 -0.05263158 [60,] -0.15000000 0.85000000 [61,] -0.05263158 -0.15000000 [62,] -0.05263158 -0.05263158 [63,] -0.15000000 -0.05263158 [64,] -0.05263158 -0.15000000 [65,] -0.05263158 -0.05263158 [66,] 0.85000000 -0.05263158 [67,] -0.05263158 0.85000000 [68,] -0.05263158 -0.05263158 [69,] -0.05263158 -0.05263158 [70,] -0.05263158 -0.05263158 [71,] -0.05263158 -0.05263158 [72,] -0.05263158 -0.05263158 [73,] -0.05263158 -0.05263158 [74,] -0.05263158 -0.05263158 [75,] -0.15000000 -0.05263158 [76,] -0.05263158 -0.15000000 [77,] -0.05263158 -0.05263158 [78,] 0.85000000 -0.05263158 [79,] -0.15000000 0.85000000 [80,] -0.05263158 -0.15000000 [81,] -0.05263158 -0.05263158 [82,] -0.05263158 -0.05263158 [83,] 0.94736842 -0.05263158 [84,] -0.05263158 0.94736842 [85,] -0.05263158 -0.05263158 [86,] -0.05263158 -0.05263158 [87,] -0.15000000 -0.05263158 [88,] -0.05263158 -0.15000000 [89,] -0.05263158 -0.05263158 [90,] -0.05263158 -0.05263158 [91,] -0.15000000 -0.05263158 [92,] -0.05263158 -0.15000000 [93,] -0.05263158 -0.05263158 [94,] -0.15000000 -0.05263158 [95,] -0.05263158 -0.15000000 [96,] -0.15000000 -0.05263158 [97,] -0.05263158 -0.15000000 [98,] -0.05263158 -0.05263158 [99,] -0.05263158 -0.05263158 [100,] -0.05263158 -0.05263158 [101,] -0.05263158 -0.05263158 [102,] -0.05263158 -0.05263158 [103,] -0.05263158 -0.05263158 [104,] -0.15000000 -0.05263158 [105,] -0.05263158 -0.15000000 [106,] -0.05263158 -0.05263158 [107,] -0.15000000 -0.05263158 [108,] -0.05263158 -0.15000000 [109,] -0.05263158 -0.05263158 [110,] -0.15000000 -0.05263158 [111,] -0.15000000 -0.15000000 [112,] -0.05263158 -0.15000000 [113,] -0.15000000 -0.05263158 [114,] -0.05263158 -0.15000000 [115,] -0.05263158 -0.05263158 [116,] -0.05263158 -0.05263158 [117,] -0.05263158 -0.05263158 [118,] -0.05263158 -0.05263158 [119,] -0.05263158 -0.05263158 [120,] -0.05263158 -0.05263158 [121,] -0.05263158 -0.05263158 [122,] -0.15000000 -0.05263158 [123,] -0.05263158 -0.15000000 [124,] -0.05263158 -0.05263158 [125,] -0.15000000 -0.05263158 [126,] -0.05263158 -0.15000000 [127,] -0.05263158 -0.05263158 [128,] -0.05263158 -0.05263158 [129,] -0.05263158 -0.05263158 [130,] -0.05263158 -0.05263158 [131,] -0.05263158 -0.05263158 [132,] -0.05263158 -0.05263158 [133,] -0.05263158 -0.05263158 [134,] -0.05263158 -0.05263158 [135,] -0.05263158 -0.05263158 [136,] -0.05263158 -0.05263158 [137,] -0.15000000 -0.05263158 [138,] -0.15000000 -0.15000000 [139,] -0.05263158 -0.15000000 [140,] 0.94736842 -0.05263158 [141,] -0.15000000 0.94736842 [142,] -0.05263158 -0.15000000 [143,] -0.05263158 -0.05263158 [144,] -0.05263158 -0.05263158 [145,] -0.15000000 -0.05263158 [146,] -0.15000000 -0.15000000 [147,] -0.15000000 -0.15000000 [148,] -0.05263158 -0.15000000 [149,] -0.05263158 -0.05263158 [150,] -0.05263158 -0.05263158 [151,] 0.94736842 -0.05263158 [152,] 0.94736842 0.94736842 [153,] -0.05263158 0.94736842 > z <- as.data.frame(dum1) > z lag(myerror, k = 1) myerror 1 -0.05263158 -0.15000000 2 -0.05263158 -0.05263158 3 -0.05263158 -0.05263158 4 -0.05263158 -0.05263158 5 -0.05263158 -0.05263158 6 -0.05263158 -0.05263158 7 -0.15000000 -0.05263158 8 -0.05263158 -0.15000000 9 -0.05263158 -0.05263158 10 -0.15000000 -0.05263158 11 -0.05263158 -0.15000000 12 -0.05263158 -0.05263158 13 -0.15000000 -0.05263158 14 -0.05263158 -0.15000000 15 -0.15000000 -0.05263158 16 0.85000000 -0.15000000 17 -0.15000000 0.85000000 18 -0.05263158 -0.15000000 19 0.85000000 -0.05263158 20 -0.05263158 0.85000000 21 -0.05263158 -0.05263158 22 -0.05263158 -0.05263158 23 -0.05263158 -0.05263158 24 -0.15000000 -0.05263158 25 -0.05263158 -0.15000000 26 -0.05263158 -0.05263158 27 -0.05263158 -0.05263158 28 -0.05263158 -0.05263158 29 -0.05263158 -0.05263158 30 -0.05263158 -0.05263158 31 -0.05263158 -0.05263158 32 -0.05263158 -0.05263158 33 -0.15000000 -0.05263158 34 -0.05263158 -0.15000000 35 -0.05263158 -0.05263158 36 -0.15000000 -0.05263158 37 -0.05263158 -0.15000000 38 -0.05263158 -0.05263158 39 -0.15000000 -0.05263158 40 0.94736842 -0.15000000 41 -0.05263158 0.94736842 42 -0.05263158 -0.05263158 43 -0.15000000 -0.05263158 44 -0.05263158 -0.15000000 45 -0.05263158 -0.05263158 46 -0.05263158 -0.05263158 47 -0.05263158 -0.05263158 48 -0.05263158 -0.05263158 49 -0.05263158 -0.05263158 50 -0.15000000 -0.05263158 51 0.85000000 -0.15000000 52 -0.05263158 0.85000000 53 0.94736842 -0.05263158 54 -0.05263158 0.94736842 55 -0.15000000 -0.05263158 56 -0.05263158 -0.15000000 57 -0.05263158 -0.05263158 58 -0.05263158 -0.05263158 59 0.85000000 -0.05263158 60 -0.15000000 0.85000000 61 -0.05263158 -0.15000000 62 -0.05263158 -0.05263158 63 -0.15000000 -0.05263158 64 -0.05263158 -0.15000000 65 -0.05263158 -0.05263158 66 0.85000000 -0.05263158 67 -0.05263158 0.85000000 68 -0.05263158 -0.05263158 69 -0.05263158 -0.05263158 70 -0.05263158 -0.05263158 71 -0.05263158 -0.05263158 72 -0.05263158 -0.05263158 73 -0.05263158 -0.05263158 74 -0.05263158 -0.05263158 75 -0.15000000 -0.05263158 76 -0.05263158 -0.15000000 77 -0.05263158 -0.05263158 78 0.85000000 -0.05263158 79 -0.15000000 0.85000000 80 -0.05263158 -0.15000000 81 -0.05263158 -0.05263158 82 -0.05263158 -0.05263158 83 0.94736842 -0.05263158 84 -0.05263158 0.94736842 85 -0.05263158 -0.05263158 86 -0.05263158 -0.05263158 87 -0.15000000 -0.05263158 88 -0.05263158 -0.15000000 89 -0.05263158 -0.05263158 90 -0.05263158 -0.05263158 91 -0.15000000 -0.05263158 92 -0.05263158 -0.15000000 93 -0.05263158 -0.05263158 94 -0.15000000 -0.05263158 95 -0.05263158 -0.15000000 96 -0.15000000 -0.05263158 97 -0.05263158 -0.15000000 98 -0.05263158 -0.05263158 99 -0.05263158 -0.05263158 100 -0.05263158 -0.05263158 101 -0.05263158 -0.05263158 102 -0.05263158 -0.05263158 103 -0.05263158 -0.05263158 104 -0.15000000 -0.05263158 105 -0.05263158 -0.15000000 106 -0.05263158 -0.05263158 107 -0.15000000 -0.05263158 108 -0.05263158 -0.15000000 109 -0.05263158 -0.05263158 110 -0.15000000 -0.05263158 111 -0.15000000 -0.15000000 112 -0.05263158 -0.15000000 113 -0.15000000 -0.05263158 114 -0.05263158 -0.15000000 115 -0.05263158 -0.05263158 116 -0.05263158 -0.05263158 117 -0.05263158 -0.05263158 118 -0.05263158 -0.05263158 119 -0.05263158 -0.05263158 120 -0.05263158 -0.05263158 121 -0.05263158 -0.05263158 122 -0.15000000 -0.05263158 123 -0.05263158 -0.15000000 124 -0.05263158 -0.05263158 125 -0.15000000 -0.05263158 126 -0.05263158 -0.15000000 127 -0.05263158 -0.05263158 128 -0.05263158 -0.05263158 129 -0.05263158 -0.05263158 130 -0.05263158 -0.05263158 131 -0.05263158 -0.05263158 132 -0.05263158 -0.05263158 133 -0.05263158 -0.05263158 134 -0.05263158 -0.05263158 135 -0.05263158 -0.05263158 136 -0.05263158 -0.05263158 137 -0.15000000 -0.05263158 138 -0.15000000 -0.15000000 139 -0.05263158 -0.15000000 140 0.94736842 -0.05263158 141 -0.15000000 0.94736842 142 -0.05263158 -0.15000000 143 -0.05263158 -0.05263158 144 -0.05263158 -0.05263158 145 -0.15000000 -0.05263158 146 -0.15000000 -0.15000000 147 -0.15000000 -0.15000000 148 -0.05263158 -0.15000000 149 -0.05263158 -0.05263158 150 -0.05263158 -0.05263158 151 0.94736842 -0.05263158 152 0.94736842 0.94736842 153 -0.05263158 0.94736842 > 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/7uwr91355496697.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/8wee01355496697.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/9oh301355496697.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/10ti771355496697.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/11wlqf1355496697.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/126r2s1355496697.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/13f4091355496698.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/14i5mx1355496698.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/154qiz1355496698.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/162jve1355496698.tab") + } > > try(system("convert tmp/1q8oc1355496697.ps tmp/1q8oc1355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/2hluz1355496697.ps tmp/2hluz1355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/3q21f1355496697.ps tmp/3q21f1355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/4n0o21355496697.ps tmp/4n0o21355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/57dzt1355496697.ps tmp/57dzt1355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/6pe7e1355496697.ps tmp/6pe7e1355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/7uwr91355496697.ps tmp/7uwr91355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/8wee01355496697.ps tmp/8wee01355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/9oh301355496697.ps tmp/9oh301355496697.png",intern=TRUE)) character(0) > try(system("convert tmp/10ti771355496697.ps tmp/10ti771355496697.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 13.222 2.154 15.436