R version 2.11.1 (2010-05-31) Copyright (C) 2010 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(2.5313084961454E-14 + ,0.0070484873310255 + ,-3.5971225997855E-14 + ,-3.5971225997855E-14 + ,-3.5971225997855E-14 + ,-0.0070484873310361 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,0.0070484873310255 + ,-0.0070484873310361 + ,0.0070484873310255 + ,-3.5971225997855E-14 + ,-3.5971225997855E-14 + ,-0.22336306618724 + ,-1.2434497875802E-14 + ,-1.2434497875802E-14 + ,0.029207051746288 + ,2.1316282072803E-14 + ,2.1316282072803E-14 + ,-0.029207051746279 + ,-1.2434497875802E-14 + ,-1.2434497875802E-14 + ,0.029207051746288 + ,2.1316282072803E-14 + ,2.1316282072803E-14 + ,2.1316282072803E-14 + ,2.1316282072803E-14 + ,-0.25344890080958 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,0.0027434859457602 + ,-0.0027434859457909 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,0.0027434859457602 + ,-0.041964199098991 + ,0.039220713153242 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,0.0027434859457602 + ,9.3258734068513E-15 + ,9.3258734068513E-15 + ,9.3258734068513E-15 + ,9.3258734068513E-15 + ,9.3258734068513E-15 + ,9.3258734068513E-15 + ,-0.0027434859457909 + ,-3.9968028886506E-14 + ,-3.9968028886506E-14 + ,-0.06234313057414 + ,-3.9968028886506E-15 + ,-3.9968028886506E-15 + ,-0.053295913866004 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,-0.013975382737553 + ,4.8849813083507E-14 + ,4.8849813083507E-14 + ,-0.019740080385951 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,0.014252022707225 + ,2.3980817331903E-14 + ,-0.014252022707176 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,0.014252022707225 + ,2.3980817331903E-14 + ,2.3980817331903E-14 + ,2.3980817331903E-14 + ,2.3980817331903E-14 + ,2.3980817331903E-14 + ,2.3980817331903E-14 + ,-0.058268908123976 + ,-4.4408920985006E-16 + ,0.058268908124 + ,2.3980817331903E-14 + ,2.3980817331903E-14 + ,-0.014252022707176 + ,0.014252022707225 + ,-0.014252022707176 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,2.5313084961454E-14 + ,0.0047732787526256 + ,0.0094787439545678 + ,2.3980817331903E-14 + ,-0.014252022707176 + ,2.5313084961454E-14 + ,-0.059130523226774 + ,4.7961634663807E-14 + ,4.7961634663807E-14 + ,4.7961634663807E-14 + ,-0.013628831055652 + ,0.013628831055654 + ,4.7961634663807E-14 + ,-0.027445976608752 + ,-4.4408920985006E-15 + ,-4.4408920985006E-15 + ,-0.026433257068204 + ,-0.018018505502649 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,0.018018505502629 + ,-0.018018505502649 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,0.018018505502629 + ,-0.018018505502649 + ,2.9309887850104E-14 + ,0.018018505502629 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-0.018018505502649 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,0.018018505502629 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-0.018018505502649 + ,0.018018505502629 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-0.018018505502649 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,0.018018505502629 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,-0.018018505502649 + ,2.9309887850104E-14 + ,2.9309887850104E-14 + ,0.018018505502629 + ,-4.8849813083507E-14 + ,-4.8849813083507E-14 + ,0.025563313559651 + ,-0.089149906971764 + ,-0.049742091894859 + ,-4.5741188614556E-14 + ,-4.5741188614556E-14 + ,-4.5741188614556E-14 + ,0.049742091894854 + ,4.0412118096356E-14 + ,0.08914990697184 + ,3.5527136788005E-14 + ,-0.089149906971764 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,0.08914990697184 + ,-0.089149906971764 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14 + ,4.0412118096356E-14) > 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] -0.003832536 > sqrtn <- sqrt(length(x)) > (armse <- sd(x) / sqrtn) [1] 0.002174412 > (armose <- arm / armse) [1] -1.762562 > (geo <- geomean(x)) [1] NaN Warning message: In log(x) : NaNs produced > (har <- harmean(x)) [1] -3.328476e-13 > (qua <- quamean(x)) [1] 0.03091236 > (win <- winmean(x)) [,1] [,2] [1,] -3.682107e-03 2.091247e-03 [2,] -2.648786e-03 1.438651e-03 [3,] -2.776688e-03 1.413084e-03 [4,] -2.987115e-03 1.377186e-03 [5,] -2.567288e-03 1.145468e-03 [6,] -2.470909e-03 1.120582e-03 [7,] -2.568284e-03 1.095604e-03 [8,] -2.671156e-03 1.009963e-03 [9,] -2.511234e-03 9.702508e-04 [10,] -2.122340e-03 8.781943e-04 [11,] -1.420697e-03 7.299169e-04 [12,] -1.315032e-03 7.100351e-04 [13,] -1.249205e-03 6.979796e-04 [14,] -7.806829e-04 6.190677e-04 [15,] -9.340509e-04 5.582251e-04 [16,] -9.340509e-04 5.582251e-04 [17,] -9.340509e-04 5.582251e-04 [18,] -9.901382e-04 5.506495e-04 [19,] -1.384396e-03 5.027224e-04 [20,] -1.627422e-03 4.784015e-04 [21,] -1.627422e-03 4.784015e-04 [22,] -1.213109e-03 4.093843e-04 [23,] -1.474758e-03 3.853803e-04 [24,] -1.718333e-03 3.679798e-04 [25,] -1.718333e-03 3.679798e-04 [26,] -1.682370e-03 3.618321e-04 [27,] -2.005956e-03 3.366441e-04 [28,] -1.084708e-03 1.786444e-04 [29,] -1.084708e-03 1.786444e-04 [30,] -4.389578e-04 7.129775e-05 [31,] -4.389578e-04 7.129775e-05 [32,] 5.826450e-15 2.733276e-15 [33,] 5.753176e-15 2.727619e-15 [34,] 5.753176e-15 2.727619e-15 [35,] 5.753176e-15 2.727619e-15 [36,] 4.474199e-15 2.634485e-15 [37,] 4.474199e-15 2.634485e-15 [38,] 4.474199e-15 2.634485e-15 [39,] 4.474199e-15 2.634485e-15 [40,] 4.474199e-15 2.634485e-15 [41,] 4.474199e-15 2.634485e-15 [42,] 4.474199e-15 2.634485e-15 [43,] 4.474199e-15 2.634485e-15 [44,] 4.474199e-15 2.634485e-15 [45,] 4.474199e-15 2.634485e-15 [46,] 5.189182e-15 2.562408e-15 [47,] 5.189182e-15 2.562408e-15 [48,] 5.189182e-15 2.562408e-15 [49,] 6.603607e-15 2.423412e-15 [50,] 6.603607e-15 2.423412e-15 [51,] 6.603607e-15 2.423412e-15 [52,] 6.603607e-15 2.423412e-15 [53,] 6.603607e-15 2.423412e-15 [54,] 6.603607e-15 2.423412e-15 [55,] 6.603607e-15 2.423412e-15 [56,] 6.603607e-15 2.423412e-15 [57,] 5.211387e-15 2.329014e-15 [58,] 3.408385e-15 2.216971e-15 [59,] 3.408385e-15 2.216971e-15 [60,] 3.408385e-15 2.216971e-15 [61,] 4.627410e-15 2.097749e-15 [62,] 4.627410e-15 2.097749e-15 [63,] 4.627410e-15 2.097749e-15 [64,] 4.627410e-15 2.097749e-15 [65,] 4.627410e-15 2.097749e-15 [66,] 1.239453e-14 1.358992e-15 > (tri <- trimean(x)) [,1] [,2] [1,] -3.041456e-03 1.732651e-03 [2,] -2.387730e-03 1.252674e-03 [3,] -2.253166e-03 1.141223e-03 [4,] -2.071387e-03 1.024663e-03 [5,] -1.830406e-03 9.018137e-04 [6,] -1.673623e-03 8.360737e-04 [7,] -1.530740e-03 7.683815e-04 [8,] -1.369630e-03 6.969950e-04 [9,] -1.190849e-03 6.349243e-04 [10,] -1.027839e-03 5.721898e-04 [11,] -9.048612e-04 5.196459e-04 [12,] -8.515724e-04 4.884383e-04 [13,] -8.071797e-04 4.569113e-04 [14,] -7.676426e-04 4.234138e-04 [15,] -7.665468e-04 3.983995e-04 [16,] -7.532528e-04 3.793233e-04 [17,] -7.396384e-04 3.581621e-04 [18,] -7.256921e-04 3.344553e-04 [19,] -7.075545e-04 3.086753e-04 [20,] -6.630254e-04 2.860321e-04 [21,] -6.019876e-04 2.633280e-04 [22,] -5.393848e-04 2.369516e-04 [23,] -4.996136e-04 2.172195e-04 [24,] -4.438273e-04 1.973985e-04 [25,] -3.730214e-04 1.760585e-04 [26,] -3.003019e-04 1.500218e-04 [27,] -2.274848e-04 1.175657e-04 [28,] -1.359996e-04 7.366804e-05 [29,] -1.359996e-04 5.637290e-05 [30,] -3.919266e-05 2.761352e-05 [31,] -1.988033e-05 1.988033e-05 [32,] 8.777293e-15 2.797424e-15 [33,] 8.914925e-15 2.790911e-15 [34,] 9.060093e-15 2.783634e-15 [35,] 9.209727e-15 2.775153e-15 [36,] 9.364037e-15 2.765350e-15 [37,] 9.579639e-15 2.759728e-15 [38,] 9.802195e-15 2.752854e-15 [39,] 1.003205e-14 2.744596e-15 [40,] 1.026956e-14 2.734807e-15 [41,] 1.051513e-14 2.723319e-15 [42,] 1.076916e-14 2.709944e-15 [43,] 1.103211e-14 2.694466e-15 [44,] 1.130445e-14 2.676640e-15 [45,] 1.158669e-14 2.656186e-15 [46,] 1.187939e-14 2.632777e-15 [47,] 1.215380e-14 2.612403e-15 [48,] 1.243877e-14 2.588961e-15 [49,] 1.273491e-14 2.562047e-15 [50,] 1.298517e-14 2.544023e-15 [51,] 1.324564e-14 2.522993e-15 [52,] 1.351697e-14 2.498543e-15 [53,] 1.379984e-14 2.470186e-15 [54,] 1.409501e-14 2.437339e-15 [55,] 1.440329e-14 2.399306e-15 [56,] 1.472559e-14 2.355241e-15 [57,] 1.472559e-14 2.304106e-15 [58,] 1.506289e-14 2.251623e-15 [59,] 1.598180e-14 2.197021e-15 [60,] 1.651457e-14 2.132092e-15 [61,] 1.707466e-14 2.054498e-15 [62,] 1.761164e-14 1.980856e-15 [63,] 1.817765e-14 1.891833e-15 [64,] 1.877510e-14 1.783038e-15 [65,] 1.940670e-14 1.647894e-15 [66,] 2.007544e-14 1.475654e-15 > (midr <- midrange(x)) [1] -0.0821495 > midm <- array(NA,dim=8) > for (j in 1:8) midm[j] <- midmean(x,j) > midm [1] 1.586364e-14 1.586364e-14 1.586364e-14 1.586364e-14 1.586364e-14 [6] 1.586364e-14 1.586364e-14 1.586364e-14 > postscript(file="/var/www/rcomp/tmp/1am3i1290526842.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/rcomp/tmp/23v2k1290526842.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/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/www/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/rcomp/tmp/35zt21290526842.tab") > > try(system("convert tmp/1am3i1290526842.ps tmp/1am3i1290526842.png",intern=TRUE)) character(0) > try(system("convert tmp/23v2k1290526842.ps tmp/23v2k1290526842.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.48 0.47 1.91