R version 2.9.0 (2009-04-17) Copyright (C) 2009 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 <- c(15 + ,14.4 + ,13.5 + ,12.8 + ,12.3 + ,12.2 + ,14.5 + ,17.2 + ,18 + ,18.1 + ,18 + ,18.3 + ,18.7 + ,18.6 + ,18.3 + ,17.9 + ,17.4 + ,17.4 + ,20.1 + ,23.2 + ,24.2 + ,24.2 + ,23.9 + ,23.8 + ,23.8 + ,23.3 + ,22.4 + ,21.5 + ,20.5 + ,19.9 + ,22 + ,24.9 + ,25.7 + ,25.3 + ,24.4 + ,23.8 + ,23.5 + ,23 + ,22.2 + ,21.4 + ,20.3 + ,19.5 + ,21.7 + ,24.7 + ,25.3 + ,24.9 + ,24.1 + ,23.4 + ,23.1 + ,22.4 + ,21.3 + ,20.3 + ,19.3 + ,18.7 + ,21 + ,24 + ,24.8 + ,24.2 + ,23.3 + ,22.7 + ,22.3 + ,21.8 + ,21.2 + ,20.5 + ,19.7 + ,19.2 + ,21.2 + ,23.9 + ,24.8 + ,24.2 + ,23 + ,22.2 + ,21.8 + ,21.2 + ,20.5 + ,19.7 + ,19 + ,18.4 + ,20.7 + ,24.5 + ,26 + ,25.2 + ,24.1 + ,23.7 + ,23.5 + ,23.1 + ,22.7 + ,22.5 + ,21.7 + ,20.5 + ,21.9 + ,22.9 + ,21.5 + ,19 + ,17 + ,16.1 + ,15.9 + ,15.7 + ,15.1 + ,14.8 + ,14.3 + ,14.5 + ,18.9 + ,21.6 + ,20.4 + ,17.9 + ,15.7 + ,14.5 + ,14 + ,13.9 + ,14.4 + ,15.8 + ,15.6 + ,14.7 + ,16.7 + ,17.9 + ,18.7 + ,20.1 + ,19.5 + ,19.4 + ,18.6 + ,17.8 + ,17.1 + ,16.5 + ,15.5 + ,14.9 + ,18.6 + ,19.1 + ,18.8 + ,18.2 + ,18 + ,19 + ,20.7 + ,21.2 + ,20.7 + ,19.6 + ,18.6 + ,18.7 + ,23.8 + ,24.9 + ,24.8 + ,23.8 + ,22.3 + ,21.7 + ,20.7 + ,19.7 + ,18.4 + ,17.4 + ,17 + ,18 + ,23.8 + ,25.5 + ,25.6 + ,23.7 + ,22 + ,21.3 + ,20.7 + ,20.4 + ,20.3 + ,20.4 + ,19.8 + ,19.5 + ,23.1 + ,23.5 + ,23.5 + ,22.9 + ,21.9 + ,21.5 + ,20.5 + ,20.2 + ,19.4 + ,19.2 + ,18.8 + ,18.8 + ,22.6 + ,23.3 + ,23 + ,21.4 + ,19.9 + ,18.8 + ,18.6 + ,18.4 + ,18.6 + ,19.9 + ,19.2 + ,18.4 + ,21.1 + ,20.5 + ,19.1 + ,18.1 + ,17 + ,17.1 + ,17.4 + ,16.8 + ,15.3 + ,14.3 + ,13.4 + ,15.3 + ,22.1 + ,23.7 + ,22.2 + ,19.5 + ,16.6 + ,17.3 + ,19.8 + ,21.2 + ,21.5 + ,20.6 + ,19.1 + ,19.6 + ,23.5 + ,24 + ,23.2 + ,21.2) > 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] 20.15327 > sqrtn <- sqrt(length(x)) > (armse <- sd(x) / sqrtn) [1] 0.2154131 > (armose <- arm / armse) [1] 93.55638 > (geo <- geomean(x)) [1] 19.89257 > (har <- harmean(x)) [1] 19.61541 > (qua <- quamean(x)) [1] 20.39701 > (win <- winmean(x)) [,1] [,2] [1,] 20.15234 0.21515840 [2,] 20.15607 0.21426913 [3,] 20.16308 0.21279744 [4,] 20.16121 0.21208746 [5,] 20.17056 0.21074554 [6,] 20.17056 0.21003856 [7,] 20.17056 0.20763394 [8,] 20.17056 0.20763394 [9,] 20.17477 0.20707950 [10,] 20.17009 0.20658336 [11,] 20.17523 0.20591377 [12,] 20.17523 0.20591377 [13,] 20.16916 0.20527874 [14,] 20.16916 0.20226420 [15,] 20.16916 0.20067984 [16,] 20.16168 0.19828948 [17,] 20.16963 0.19730605 [18,] 20.17804 0.19627788 [19,] 20.19579 0.19414820 [20,] 20.18645 0.19325143 [21,] 20.20607 0.19095090 [22,] 20.20607 0.18879022 [23,] 20.21682 0.18756711 [24,] 20.20561 0.18651463 [25,] 20.21729 0.18519806 [26,] 20.21729 0.18271748 [27,] 20.24252 0.17995406 [28,] 20.29486 0.17445103 [29,] 20.30841 0.17307741 [30,] 20.32243 0.17167792 [31,] 20.33692 0.17025395 [32,] 20.35187 0.16595484 [33,] 20.35187 0.16595484 [34,] 20.35187 0.16595484 [35,] 20.33551 0.16135383 [36,] 20.33551 0.16135383 [37,] 20.35280 0.15973886 [38,] 20.37056 0.15810657 [39,] 20.38879 0.15645845 [40,] 20.37009 0.15472666 [41,] 20.35093 0.15297890 [42,] 20.35093 0.15297890 [43,] 20.43131 0.14593194 [44,] 20.43131 0.14231519 [45,] 20.43131 0.14231519 [46,] 20.40981 0.14036638 [47,] 20.43178 0.13853948 [48,] 20.43178 0.13853948 [49,] 20.40888 0.13648376 [50,] 20.40888 0.13648376 [51,] 20.43271 0.13452620 [52,] 20.40841 0.13236382 [53,] 20.43318 0.13035379 [54,] 20.40794 0.12389625 [55,] 20.40794 0.12389625 [56,] 20.40794 0.11955636 [57,] 20.38131 0.11728029 [58,] 20.35421 0.11499898 [59,] 20.35421 0.11499898 [60,] 20.38224 0.10825606 [61,] 20.38224 0.10825606 [62,] 20.35327 0.10586470 [63,] 20.35327 0.10586470 [64,] 20.35327 0.10586470 [65,] 20.32290 0.10339524 [66,] 20.32290 0.09851891 [67,] 20.32290 0.09851891 [68,] 20.29112 0.09599879 [69,] 20.29112 0.09599879 [70,] 20.29112 0.09090455 [71,] 20.29112 0.09090455 > (tri <- trimean(x)) [,1] [,2] [1,] 20.15327 0.2123813 [2,] 20.16321 0.2094357 [3,] 20.18365 0.2067989 [4,] 20.18365 0.2045558 [5,] 20.19853 0.2023806 [6,] 20.20446 0.2003916 [7,] 20.20446 0.1984227 [8,] 20.21050 0.1967572 [9,] 20.22296 0.1949860 [10,] 20.22887 0.1931827 [11,] 20.23542 0.1913287 [12,] 20.24158 0.1894386 [13,] 20.24787 0.1874238 [14,] 20.24787 0.1853451 [15,] 20.25484 0.1834500 [16,] 20.26196 0.1815873 [17,] 20.27722 0.1798282 [18,] 20.28483 0.1780404 [19,] 20.29205 0.1762220 [20,] 20.29828 0.1744673 [21,] 20.30523 0.1726610 [22,] 20.31118 0.1709221 [23,] 20.31726 0.1692332 [24,] 20.32289 0.1675188 [25,] 20.32927 0.1657556 [26,] 20.33519 0.1639635 [27,] 20.33519 0.1622255 [28,] 20.34125 0.1605683 [29,] 20.34620 0.1591995 [30,] 20.34872 0.1578204 [31,] 20.35065 0.1564295 [32,] 20.35197 0.1550253 [33,] 20.35270 0.1538094 [34,] 20.35274 0.1524859 [35,] 20.35278 0.1510451 [36,] 20.35352 0.1498031 [37,] 20.35429 0.1484465 [38,] 20.35435 0.1470796 [39,] 20.35368 0.1457006 [40,] 20.35224 0.1443070 [41,] 20.35152 0.1429040 [42,] 20.35154 0.1414898 [43,] 20.35156 0.1399345 [44,] 20.34841 0.1387277 [45,] 20.34516 0.1376499 [46,] 20.34180 0.1364522 [47,] 20.33917 0.1352676 [48,] 20.33559 0.1340783 [49,] 20.33190 0.1327520 [50,] 20.32895 0.1314338 [51,] 20.32589 0.1299610 [52,] 20.32182 0.1284629 [53,] 20.31852 0.1269646 [54,] 20.31852 0.1254386 [55,] 20.31415 0.1242522 [56,] 20.31058 0.1229077 [57,] 20.30686 0.1217420 [58,] 20.30300 0.1206093 [59,] 20.30000 0.1195109 [60,] 20.29792 0.1182492 [61,] 20.29574 0.1173773 [62,] 20.29239 0.1163580 [63,] 20.28889 0.1153929 [64,] 20.28636 0.1142616 [65,] 20.28095 0.1129391 [66,] 20.27927 0.1116483 [67,] 20.27750 0.1106222 [68,] 20.27564 0.1094013 [69,] 20.27500 0.1082253 [70,] 20.27432 0.1068214 [71,] 20.27361 0.1057241 > (midr <- midrange(x)) [1] 19.1 > midm <- array(NA,dim=8) > for (j in 1:8) midm[j] <- midmean(x,j) > midm [1] 20.29439 20.34220 20.34220 20.34220 20.31415 20.34220 20.34220 20.34220 > postscript(file="/var/www/html/rcomp/tmp/12oxh1262121730.ps",horizontal=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/www/html/rcomp/tmp/27fme1262121730.ps",horizontal=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/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,'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/www/html/rcomp/tmp/3hqw81262121730.tab") > try(system("convert tmp/12oxh1262121730.ps tmp/12oxh1262121730.png",intern=TRUE)) character(0) > try(system("convert tmp/27fme1262121730.ps tmp/27fme1262121730.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.210 0.378 2.829