R version 2.13.0 (2011-04-13) Copyright (C) 2011 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i486-pc-linux-gnu (32-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > x <- c(30,28,38,30,22,26,25,18,11,26,25,38,44,30,40,34,47,30,31,23,36,36,30,25,39,34,31,31,33,25,33,35,42,43,30,33,13,32,36,0,28,14,17,32,30,35,20,28,28,39,34,26,39,39,33,28,4,39,18,14,29,44,21,16,28,35,28,38,23,36,32,29,25,27,36,28,23,40,23,40,28,34,33,28,34,30,33,22,38,26,35,8,24,29,20,29,45,37,33,33,25,32,29,28,28,31,52,21,24,41,33,32,19,20,31,31,32,18,23,17,20,12,17,30,31,10,13,22,42,1,9,32,11,25,36,31,0,24,13,8,13,19,18,33,40,22,38,24,8,35,43,43,14,41,38,45,31,13,28,31,40,30,16,37,30,35,32,27,20,18,31,31,21,39,41,13,32,18,39,14,7,17,0,30,37,0,5,1,16,32,24,17,11,24,22,12,19,13,17,15,16,24,15,17,18,20,16,16,18,22,8,17,18,16,23,22,13,13,16,16,20,22,17,18,17,12,7,17,14,23,17,14,15,17,21,18,18,17,17,16,15,21,16,14,15,17,15,15,10,6,22,21,1,18,17,4,10,16,16,9,16,17,7,15,14,14,18,12,16,21,19,16,1,16,10,19,12,2,14,17,19,14,11,4,16,20,12,15,16) > ylimmax = '' > ylimmin = '' > main = 'Robustness of Central Tendency' > #'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!) > geomean <- function(x) { + return(exp(mean(log(x)))) + } > harmean <- function(x) { + return(1/mean(1/x)) + } > quamean <- function(x) { + return(sqrt(mean(x*x))) + } > winmean <- function(x) { + x <-sort(x[!is.na(x)]) + n<-length(x) + denom <- 3 + nodenom <- n/denom + if (nodenom>40) denom <- n/40 + sqrtn = sqrt(n) + roundnodenom = floor(nodenom) + win <- array(NA,dim=c(roundnodenom,2)) + for (j in 1:roundnodenom) { + win[j,1] <- (j*x[j+1]+sum(x[(j+1):(n-j)])+j*x[n-j])/n + win[j,2] <- sd(c(rep(x[j+1],j),x[(j+1):(n-j)],rep(x[n-j],j)))/sqrtn + } + return(win) + } > trimean <- function(x) { + x <-sort(x[!is.na(x)]) + n<-length(x) + denom <- 3 + nodenom <- n/denom + if (nodenom>40) denom <- n/40 + sqrtn = sqrt(n) + roundnodenom = floor(nodenom) + tri <- array(NA,dim=c(roundnodenom,2)) + for (j in 1:roundnodenom) { + tri[j,1] <- mean(x,trim=j/n) + tri[j,2] <- sd(x[(j+1):(n-j)]) / sqrt(n-j*2) + } + return(tri) + } > midrange <- function(x) { + return((max(x)+min(x))/2) + } > q1 <- function(data,n,p,i,f) { + np <- n*p; + i <<- floor(np) + f <<- np - i + qvalue <- (1-f)*data[i] + f*data[i+1] + } > q2 <- function(data,n,p,i,f) { + np <- (n+1)*p + i <<- floor(np) + f <<- np - i + qvalue <- (1-f)*data[i] + f*data[i+1] + } > q3 <- function(data,n,p,i,f) { + np <- n*p + i <<- floor(np) + f <<- np - i + if (f==0) { + qvalue <- data[i] + } else { + qvalue <- data[i+1] + } + } > q4 <- function(data,n,p,i,f) { + np <- n*p + i <<- floor(np) + f <<- np - i + if (f==0) { + qvalue <- (data[i]+data[i+1])/2 + } else { + qvalue <- data[i+1] + } + } > q5 <- function(data,n,p,i,f) { + np <- (n-1)*p + i <<- floor(np) + f <<- np - i + if (f==0) { + qvalue <- data[i+1] + } else { + qvalue <- data[i+1] + f*(data[i+2]-data[i+1]) + } + } > q6 <- function(data,n,p,i,f) { + np <- n*p+0.5 + i <<- floor(np) + f <<- np - i + qvalue <- data[i] + } > q7 <- function(data,n,p,i,f) { + np <- (n+1)*p + i <<- floor(np) + f <<- np - i + if (f==0) { + qvalue <- data[i] + } else { + qvalue <- f*data[i] + (1-f)*data[i+1] + } + } > q8 <- function(data,n,p,i,f) { + np <- (n+1)*p + i <<- floor(np) + f <<- np - i + if (f==0) { + qvalue <- data[i] + } else { + if (f == 0.5) { + qvalue <- (data[i]+data[i+1])/2 + } else { + if (f < 0.5) { + qvalue <- data[i] + } else { + qvalue <- data[i+1] + } + } + } + } > midmean <- function(x,def) { + x <-sort(x[!is.na(x)]) + n<-length(x) + if (def==1) { + qvalue1 <- q1(x,n,0.25,i,f) + qvalue3 <- q1(x,n,0.75,i,f) + } + if (def==2) { + qvalue1 <- q2(x,n,0.25,i,f) + qvalue3 <- q2(x,n,0.75,i,f) + } + if (def==3) { + qvalue1 <- q3(x,n,0.25,i,f) + qvalue3 <- q3(x,n,0.75,i,f) + } + if (def==4) { + qvalue1 <- q4(x,n,0.25,i,f) + qvalue3 <- q4(x,n,0.75,i,f) + } + if (def==5) { + qvalue1 <- q5(x,n,0.25,i,f) + qvalue3 <- q5(x,n,0.75,i,f) + } + if (def==6) { + qvalue1 <- q6(x,n,0.25,i,f) + qvalue3 <- q6(x,n,0.75,i,f) + } + if (def==7) { + qvalue1 <- q7(x,n,0.25,i,f) + qvalue3 <- q7(x,n,0.75,i,f) + } + if (def==8) { + qvalue1 <- q8(x,n,0.25,i,f) + qvalue3 <- q8(x,n,0.75,i,f) + } + midm <- 0 + myn <- 0 + roundno4 <- round(n/4) + round3no4 <- round(3*n/4) + for (i in 1:n) { + if ((x[i]>=qvalue1) & (x[i]<=qvalue3)){ + midm = midm + x[i] + myn = myn + 1 + } + } + midm = midm / myn + return(midm) + } > (arm <- mean(x)) [1] 23.30104 > sqrtn <- sqrt(length(x)) > (armse <- sd(x) / sqrtn) [1] 0.6232512 > (armose <- arm / armse) [1] 37.38627 > (geo <- geomean(x)) [1] 0 > (har <- harmean(x)) [1] 0 > (qua <- quamean(x)) [1] 25.58925 > (win <- winmean(x)) [,1] [,2] [1,] 23.28374 0.6207200 [2,] 23.26990 0.6189582 [3,] 23.26990 0.6189582 [4,] 23.26990 0.6155324 [5,] 23.26990 0.6155324 [6,] 23.24913 0.6131573 [7,] 23.24913 0.6131573 [8,] 23.27682 0.6097363 [9,] 23.30796 0.5990388 [10,] 23.30796 0.5990388 [11,] 23.26990 0.5950075 [12,] 23.31142 0.5904368 [13,] 23.35640 0.5857001 [14,] 23.35640 0.5758530 [15,] 23.35640 0.5758530 [16,] 23.35640 0.5758530 [17,] 23.41522 0.5701907 [18,] 23.41522 0.5701907 [19,] 23.34948 0.5637010 [20,] 23.34948 0.5637010 [21,] 23.42215 0.5569984 [22,] 23.42215 0.5569984 [23,] 23.50173 0.5500281 [24,] 23.50173 0.5500281 [25,] 23.50173 0.5500281 [26,] 23.41176 0.5414171 [27,] 23.50519 0.5335964 [28,] 23.50519 0.5335964 [29,] 23.50519 0.5335964 [30,] 23.50519 0.5335964 [31,] 23.61246 0.5251118 [32,] 23.50173 0.5148022 [33,] 23.50173 0.5148022 [34,] 23.50173 0.5148022 [35,] 23.38062 0.5040223 [36,] 23.38062 0.5040223 [37,] 23.50865 0.4942750 [38,] 23.50865 0.4942750 [39,] 23.50865 0.4942750 [40,] 23.50865 0.4942750 [41,] 23.36678 0.4821038 [42,] 23.36678 0.4821038 [43,] 23.36678 0.4821038 [44,] 23.36678 0.4821038 [45,] 23.36678 0.4821038 [46,] 23.52595 0.4705634 [47,] 23.36332 0.4571042 [48,] 23.36332 0.4571042 [49,] 23.36332 0.4571042 [50,] 23.36332 0.4571042 [51,] 23.36332 0.4571042 [52,] 23.18339 0.4429062 [53,] 23.18339 0.4429062 [54,] 23.18339 0.4429062 [55,] 23.18339 0.4429062 [56,] 23.18339 0.4429062 [57,] 23.38062 0.4291124 [58,] 23.38062 0.4291124 [59,] 23.38062 0.4291124 [60,] 23.38062 0.4291124 [61,] 23.38062 0.4291124 [62,] 23.16609 0.4127851 [63,] 23.16609 0.4127851 [64,] 23.16609 0.4127851 [65,] 23.16609 0.4127851 [66,] 23.39446 0.3975583 [67,] 23.39446 0.3975583 [68,] 23.39446 0.3975583 [69,] 23.39446 0.3975583 [70,] 23.39446 0.3975583 [71,] 23.39446 0.3975583 [72,] 23.14533 0.3792277 [73,] 23.14533 0.3792277 [74,] 23.14533 0.3792277 [75,] 23.14533 0.3792277 [76,] 23.14533 0.3792277 [77,] 23.14533 0.3792277 [78,] 23.14533 0.3792277 [79,] 23.14533 0.3792277 [80,] 23.14533 0.3792277 [81,] 23.14533 0.3792277 [82,] 23.14533 0.3792277 [83,] 23.14533 0.3792277 [84,] 22.85467 0.3587133 [85,] 23.14879 0.3396992 [86,] 23.14879 0.3396992 [87,] 23.14879 0.3396992 [88,] 23.14879 0.3396992 [89,] 23.14879 0.3396992 [90,] 23.14879 0.3396992 [91,] 23.14879 0.3396992 [92,] 23.14879 0.3396992 [93,] 23.14879 0.3396992 [94,] 23.14879 0.3396992 [95,] 23.14879 0.3396992 [96,] 22.81661 0.3167987 > (tri <- trimean(x)) [,1] [,2] [1,] 23.28223 0.6141940 [2,] 23.28070 0.6073793 [3,] 23.28622 0.6012065 [4,] 23.29181 0.5947584 [5,] 23.29749 0.5889827 [6,] 23.30325 0.5829476 [7,] 23.31273 0.5771024 [8,] 23.32234 0.5709898 [9,] 23.32841 0.5651219 [10,] 23.33086 0.5604643 [11,] 23.33333 0.5555931 [12,] 23.33962 0.5509677 [13,] 23.34221 0.5466272 [14,] 23.34100 0.5425683 [15,] 23.33977 0.5392624 [16,] 23.33852 0.5357982 [17,] 23.33725 0.5321673 [18,] 23.33202 0.5288305 [19,] 23.32669 0.5253299 [20,] 23.32530 0.5221585 [21,] 23.32389 0.5188284 [22,] 23.31837 0.5158117 [23,] 23.31276 0.5126405 [24,] 23.30290 0.5097746 [25,] 23.30290 0.5067579 [26,] 23.28270 0.5035819 [27,] 23.27660 0.5007908 [28,] 23.26609 0.4983230 [29,] 23.25541 0.4957172 [30,] 23.24454 0.4929656 [31,] 23.23348 0.4900600 [32,] 23.21778 0.4874685 [33,] 23.20628 0.4853219 [34,] 23.19457 0.4830452 [35,] 23.18265 0.4806310 [36,] 23.17512 0.4786655 [37,] 23.16744 0.4765752 [38,] 23.15493 0.4748500 [39,] 23.14218 0.4730072 [40,] 23.12919 0.4710400 [41,] 23.11594 0.4689410 [42,] 23.10732 0.4673367 [43,] 23.09852 0.4656160 [44,] 23.08955 0.4637718 [45,] 23.08040 0.4617965 [46,] 23.07107 0.4596820 [47,] 23.05641 0.4579714 [48,] 23.04663 0.4568072 [49,] 23.03665 0.4555389 [50,] 23.03665 0.4541597 [51,] 23.01604 0.4526626 [52,] 23.00541 0.4510399 [53,] 23.00000 0.4499845 [54,] 22.99448 0.4488234 [55,] 22.98883 0.4475495 [56,] 22.98305 0.4461554 [57,] 22.97714 0.4446326 [58,] 22.96532 0.4436143 [59,] 22.95322 0.4424820 [60,] 22.94083 0.4412277 [61,] 22.94083 0.4398425 [62,] 22.91515 0.4383168 [63,] 22.90798 0.4374717 [64,] 22.90062 0.4365133 [65,] 22.89308 0.4354332 [66,] 22.88535 0.4342220 [67,] 22.87097 0.4335829 [68,] 22.85621 0.4328308 [69,] 22.84106 0.4319567 [70,] 22.82550 0.4309506 [71,] 22.80952 0.4298018 [72,] 22.79310 0.4284983 [73,] 22.78322 0.4280314 [74,] 22.77305 0.4274484 [75,] 22.76259 0.4267393 [76,] 22.75182 0.4258930 [77,] 22.75182 0.4248972 [78,] 22.72932 0.4237385 [79,] 22.71756 0.4224019 [80,] 22.70543 0.4208707 [81,] 22.69291 0.4191265 [82,] 22.68000 0.4171485 [83,] 22.66667 0.4149137 [84,] 22.65289 0.4123959 [85,] 22.64706 0.4109296 [86,] 22.63248 0.4103362 [87,] 22.61739 0.4095695 [88,] 22.60177 0.4086107 [89,] 22.58559 0.4074387 [90,] 22.56881 0.4060298 [91,] 22.55140 0.4043568 [92,] 22.53333 0.4023891 [93,] 22.51456 0.4000914 [94,] 22.49505 0.3974233 [95,] 22.47475 0.3943383 [96,] 22.45361 0.3907821 > (midr <- midrange(x)) [1] 26 > midm <- array(NA,dim=8) > for (j in 1:8) midm[j] <- midmean(x,j) > midm [1] 22.52318 22.52318 22.52318 22.52318 22.52318 22.52318 22.52318 22.52318 > postscript(file="/var/wessaorg/rcomp/tmp/1e8pp1324120027.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > lb <- win[,1] - 2*win[,2] > ub <- win[,1] + 2*win[,2] > if ((ylimmin == '') | (ylimmax == '')) plot(win[,1],type='b',main=main, xlab='j', pch=19, ylab='Winsorized Mean(j/n)', ylim=c(min(lb),max(ub))) else plot(win[,1],type='l',main=main, xlab='j', pch=19, ylab='Winsorized Mean(j/n)', ylim=c(ylimmin,ylimmax)) > lines(ub,lty=3) > lines(lb,lty=3) > grid() > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/235ud1324120027.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > lb <- tri[,1] - 2*tri[,2] > ub <- tri[,1] + 2*tri[,2] > if ((ylimmin == '') | (ylimmax == '')) plot(tri[,1],type='b',main=main, xlab='j', pch=19, ylab='Trimmed Mean(j/n)', ylim=c(min(lb),max(ub))) else plot(tri[,1],type='l',main=main, xlab='j', pch=19, ylab='Trimmed Mean(j/n)', ylim=c(ylimmin,ylimmax)) > lines(ub,lty=3) > lines(lb,lty=3) > 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,'Central Tendency - Ungrouped Data',4,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Measure',header=TRUE) > a<-table.element(a,'Value',header=TRUE) > a<-table.element(a,'S.E.',header=TRUE) > a<-table.element(a,'Value/S.E.',header=TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/arithmetic_mean.htm', 'Arithmetic Mean', 'click to view the definition of the Arithmetic Mean'),header=TRUE) > a<-table.element(a,arm) > a<-table.element(a,hyperlink('http://www.xycoon.com/arithmetic_mean_standard_error.htm', armse, 'click to view the definition of the Standard Error of the Arithmetic Mean')) > a<-table.element(a,armose) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/geometric_mean.htm', 'Geometric Mean', 'click to view the definition of the Geometric Mean'),header=TRUE) > a<-table.element(a,geo) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/harmonic_mean.htm', 'Harmonic Mean', 'click to view the definition of the Harmonic Mean'),header=TRUE) > a<-table.element(a,har) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/quadratic_mean.htm', 'Quadratic Mean', 'click to view the definition of the Quadratic Mean'),header=TRUE) > a<-table.element(a,qua) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > for (j in 1:length(win[,1])) { + a<-table.row.start(a) + mylabel <- paste('Winsorized Mean (',j) + mylabel <- paste(mylabel,'/') + mylabel <- paste(mylabel,length(win[,1])) + mylabel <- paste(mylabel,')') + a<-table.element(a,hyperlink('http://www.xycoon.com/winsorized_mean.htm', mylabel, 'click to view the definition of the Winsorized Mean'),header=TRUE) + a<-table.element(a,win[j,1]) + a<-table.element(a,win[j,2]) + a<-table.element(a,win[j,1]/win[j,2]) + a<-table.row.end(a) + } > for (j in 1:length(tri[,1])) { + a<-table.row.start(a) + mylabel <- paste('Trimmed Mean (',j) + mylabel <- paste(mylabel,'/') + mylabel <- paste(mylabel,length(tri[,1])) + mylabel <- paste(mylabel,')') + a<-table.element(a,hyperlink('http://www.xycoon.com/arithmetic_mean.htm', mylabel, 'click to view the definition of the Trimmed Mean'),header=TRUE) + a<-table.element(a,tri[j,1]) + a<-table.element(a,tri[j,2]) + a<-table.element(a,tri[j,1]/tri[j,2]) + a<-table.row.end(a) + } > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/median_1.htm', 'Median', 'click to view the definition of the Median'),header=TRUE) > a<-table.element(a,median(x)) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/midrange.htm', 'Midrange', 'click to view the definition of the Midrange'),header=TRUE) > a<-table.element(a,midr) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_1.htm','Weighted Average at Xnp',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[1]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_2.htm','Weighted Average at X(n+1)p',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[2]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_3.htm','Empirical Distribution Function',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[3]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_4.htm','Empirical Distribution Function - Averaging',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[4]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_5.htm','Empirical Distribution Function - Interpolation',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[5]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_6.htm','Closest Observation',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[6]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_7.htm','True Basic - Statistics Graphics Toolkit',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[7]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > mymid <- hyperlink('http://www.xycoon.com/midmean.htm', 'Midmean', 'click to view the definition of the Midmean') > mylabel <- paste(mymid,hyperlink('http://www.xycoon.com/method_8.htm','MS Excel (old versions)',''),sep=' - ') > a<-table.element(a,mylabel,header=TRUE) > a<-table.element(a,midm[8]) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Number of observations',header=TRUE) > a<-table.element(a,length(x)) > a<-table.element(a,'') > a<-table.element(a,'') > a<-table.row.end(a) > a<-table.end(a) > table.save(a,file="/var/wessaorg/rcomp/tmp/3csvp1324120027.tab") > > try(system("convert tmp/1e8pp1324120027.ps tmp/1e8pp1324120027.png",intern=TRUE)) character(0) > try(system("convert tmp/235ud1324120027.ps tmp/235ud1324120027.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.623 0.165 1.776