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 <- c(-183.9235445 + ,-177.0726091 + ,-228.6351091 + ,-237.4476091 + ,-127.7601091 + ,-193.0101091 + ,-220.6351091 + ,-164.5101091 + ,-268.3226091 + ,-333.6976091 + ,-34.26010911 + ,-154.8851091 + ,-97.74528053 + ,101.1056549 + ,2.543154874 + ,-43.26934513 + ,-163.5818451 + ,-162.8318451 + ,46.54315487 + ,26.66815487 + ,-107.1443451 + ,42.48065487 + ,76.91815487 + ,196.2931549 + ,201.4329835 + ,12.28391886 + ,-0.278581137 + ,42.90891886 + ,87.59641886 + ,84.34641886 + ,57.72141886 + ,173.8464189 + ,-185.9660811 + ,47.65891886 + ,89.09641886 + ,-68.52858114 + ,272.6112475 + ,146.4621829 + ,162.8996829 + ,10.08718285 + ,279.7746829 + ,212.5246829 + ,248.8996829 + ,-41.97531715 + ,-5.787817149 + ,52.83718285 + ,274.2746829 + ,414.6496829 + ,310.7895114 + ,362.6404468 + ,26.07794684 + ,403.2654468 + ,327.9529468 + ,193.7029468 + ,317.0779468 + ,202.2029468 + ,321.3904468 + ,178.0154468 + ,16.45294684 + ,-68.17205316 + ,-157.0322246 + ,-76.18128917 + ,-81.74378917 + ,-134.5562892 + ,77.13121083 + ,199.8812108 + ,105.2562108 + ,198.3812108 + ,262.5687108 + ,196.1937108 + ,11.63121083 + ,-145.9937892 + ,-166.8539606 + ,-202.0030252 + ,43.43447482 + ,-113.3780252 + ,-113.6905252 + ,-155.9405252 + ,-210.5655252 + ,-124.4405252 + ,-64.25302518 + ,-298.6280252 + ,-154.1905252 + ,23.18447482 + ,-249.6756966 + ,118.1752388 + ,-180.3872612 + ,-79.19976119 + ,-81.51226119 + ,-246.7622612 + ,-105.3872612 + ,-319.2622612 + ,-72.07476119 + ,-90.44976119 + ,-80.01226119 + ,119.3627388 + ,-53.49743261 + ,-114.6464972 + ,-155.2089972 + ,-50.02149721 + ,-196.3339972 + ,-14.58399721 + ,-82.20899721 + ,17.91600279 + ,-162.8964972 + ,-132.2714972 + ,-16.83399721 + ,81.54100279 + ,275.6808314 + ,-32.46823322 + ,17.96926678 + ,27.15676678 + ,-123.1557332 + ,108.5942668 + ,67.96926678 + ,34.09426678 + ,-13.71823322 + ,-113.0932332 + ,54.34426678 + ,149.7192668 + ,153.8590954 + ,-28.28996923 + ,238.1475308 + ,50.33503077 + ,8.022530771 + ,-61.22746923 + ,-140.8524692 + ,-28.72746923 + ,9.460030771 + ,-121.9149692 + ,41.52253077 + ,115.8975308 + ,27.03735936 + ,-91.11170524 + ,3.325794759 + ,-29.48670524 + ,-73.79920524 + ,50.95079476 + ,-86.67420524 + ,-9.54920524 + ,-66.36170524 + ,73.26329476 + ,-216.2992052 + ,-128.9242052 + ,-142.7843767 + ,27.06655875 + ,60.50405875 + ,35.69155875 + ,16.37905875 + ,-64.87094125 + ,115.5040587 + ,-30.37094125 + ,87.81655875 + ,205.4415587 + ,-64.12094125 + ,-322.7459413 + ,-139.6061127 + ,35.24482274 + ,-4.317677263 + ,17.86982274 + ,2.557322737 + ,129.3073227 + ,-16.31767726 + ,164.8073227 + ,21.99482274 + ,138.6198227 + ,87.05732274 + ,51.43232274 + ,-80.42784867 + ,-105.1918797 + ,5.245620328 + ,68.43312033 + ,-0.879379672 + ,-105.1293797 + ,-82.75437967 + ,-132.6293797 + ,102.5581203 + ,23.18312033 + ,-180.3793797 + ,-267.0043797 + ,30.13544892 + ,23.98638432 + ,90.42388432 + ,31.61138432 + ,81.29888432 + ,25.04888432 + ,-13.57611568 + ,33.54888432 + ,140.7363843 + ,132.3613843 + ,94.79888432 + ,4.173884316) > 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] -8.072926e-10 > sqrtn <- sqrt(length(x)) > (armse <- sd(x) / sqrtn) [1] 10.61887 > (armose <- arm / armse) [1] -7.602434e-11 > (geo <- geomean(x)) [1] NaN Warning message: In log(x) : NaNs produced > (har <- harmean(x)) [1] -66.34536 > (qua <- quamean(x)) [1] 146.7557 > (win <- winmean(x)) [,1] [,2] [1,] -0.002252961 10.597662 [2,] -0.389141710 10.511457 [3,] -0.608723960 10.367590 [4,] -0.114079874 10.254262 [5,] -0.192055671 10.231234 [6,] 0.152952070 10.127553 [7,] -0.871577887 9.939375 [8,] -0.654044529 9.864732 [9,] -0.306871802 9.803922 [10,] 0.023157604 9.741110 [11,] -0.303784900 9.628517 [12,] -0.799744144 9.466618 [13,] -0.948001838 9.300903 [14,] -2.402967873 9.011702 [15,] -2.696658193 8.914183 [16,] -2.379540185 8.816482 [17,] -2.266864424 8.788561 [18,] -2.080816555 8.735274 [19,] -2.228474115 8.717265 [20,] -2.101524667 8.654449 [21,] -0.994736686 8.537128 [22,] -1.011570410 8.475485 [23,] -2.779603889 8.243205 [24,] -3.215063889 8.174980 [25,] -4.383611298 8.042551 [26,] -3.856572245 7.933909 [27,] -4.974384634 7.780441 [28,] -5.471428471 7.705499 [29,] -5.914463253 7.648922 [30,] -6.700590550 7.545410 [31,] -5.718895725 7.376806 [32,] -6.227066709 7.217817 [33,] -6.419936945 7.132453 [34,] -7.960248047 6.938235 [35,] -7.256178659 6.826758 [36,] -7.321953377 6.750616 [37,] -7.328811790 6.736674 [38,] -8.033889895 6.543360 [39,] -8.475475500 6.457589 [40,] -8.345997708 6.339329 [41,] -8.381802965 6.284710 [42,] -9.489991905 6.134379 [43,] -8.841974738 5.892917 [44,] -8.927108656 5.845573 [45,] -9.153833682 5.812430 [46,] -9.138344114 5.801421 [47,] -7.814072119 5.654573 [48,] -8.052527114 5.554944 [49,] -8.718629686 5.488362 [50,] -8.765405329 5.481437 [51,] -7.911042258 5.207604 [52,] -6.172151606 5.042260 [53,] -6.998321144 4.939680 [54,] -7.294932591 4.731352 [55,] -6.304940606 4.622255 [56,] -8.323223064 4.428173 [57,] -9.011210645 4.349298 [58,] -9.961451258 4.261883 [59,] -10.091334660 4.196141 [60,] -10.400482357 4.150382 [61,] -10.295329788 4.115809 [62,] -9.519455320 4.015219 [63,] -9.615933251 3.879181 [64,] -9.413039898 3.800766 > (tri <- trimean(x)) [,1] [,2] [1,] -0.4260635 10.356801 [2,] -0.8588914 10.098127 [3,] -1.1013428 9.868962 [4,] -1.2726885 9.679170 [5,] -1.5782556 9.509815 [6,] -1.8739783 9.334054 [7,] -2.2383703 9.167682 [8,] -2.4513769 9.024919 [9,] -2.6992848 8.884428 [10,] -2.9960182 8.743022 [11,] -3.3370074 8.600100 [12,] -3.6521474 8.461753 [13,] -3.9270779 8.333669 [14,] -4.1953624 8.215794 [15,] -4.3470995 8.121891 [16,] -4.4791348 8.031224 [17,] -4.6385977 7.943492 [18,] -4.8103069 7.851554 [19,] -4.9993625 7.757384 [20,] -5.1835767 7.657273 [21,] -5.3808280 7.554779 [22,] -5.6517834 7.454287 [23,] -5.9291561 7.350825 [24,] -6.1117388 7.259543 [25,] -6.2749318 7.166304 [26,] -6.3786842 7.076398 [27,] -6.5136467 6.987594 [28,] -6.5941310 6.903728 [29,] -6.6515827 6.818353 [30,] -6.6885542 6.729664 [31,] -6.6879617 6.641136 [32,] -6.7348520 6.557940 [33,] -6.7590322 6.479553 [34,] -6.7749428 6.400208 [35,] -6.7200782 6.328449 [36,] -6.6955707 6.258139 [37,] -6.6672597 6.186405 [38,] -6.6376655 6.107946 [39,] -6.5757830 6.036700 [40,] -6.4922800 5.964352 [41,] -6.4113905 5.893447 [42,] -6.3259526 5.818705 [43,] -6.1894981 5.747504 [44,] -6.0756171 5.687990 [45,] -5.9536282 5.624706 [46,] -5.8170861 5.555895 [47,] -5.6756306 5.478922 [48,] -5.5846331 5.405291 [49,] -5.4796163 5.330653 [50,] -5.3416636 5.251607 [51,] -5.1955840 5.161904 [52,] -5.0794146 5.086557 [53,] -5.0324993 5.016509 [54,] -4.9477199 4.945658 [55,] -4.8459437 4.884499 [56,] -4.7822784 4.824367 [57,] -4.6266325 4.773174 [58,] -4.4323022 4.720218 [59,] -4.1849591 4.665765 [60,] -3.9180042 4.607617 [61,] -3.6216624 4.542605 [62,] -3.3127559 4.468493 [63,] -3.0215325 4.392676 [64,] -2.7075134 4.318479 > (midr <- midrange(x)) [1] 40.47604 > midm <- array(NA,dim=8) > for (j in 1:8) midm[j] <- midmean(x,j) > midm [1] -6.631640 -5.584633 -6.631640 -5.584633 -5.584633 -6.631640 -5.584633 [8] -5.675631 > postscript(file="/var/www/html/rcomp/tmp/19nww1228122948.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/2ed6x1228122948.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/3yheq1228122949.tab") > > system("convert tmp/19nww1228122948.ps tmp/19nww1228122948.png") > system("convert tmp/2ed6x1228122948.ps tmp/2ed6x1228122948.png") > > > proc.time() user system elapsed 1.026 0.346 1.269