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. Natural language support but running in an English locale 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(-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-0.027018803106504 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,0.027018803106547 + ,-0.027018803106504 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,0.027018803106547 + ,-0.027018803106504 + ,0.027018803106547 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-0.027018803106504 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,0.027018803106547 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-0.027018803106504 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,0.027018803106547 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-0.027018803106504 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,4.7517545453957E-14 + ,0.027018803106547 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-3.5527136788005E-15 + ,-0.027018803106504 + ,0.027018803106547 + ,-0.0061427474094038 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,0.026467925613205 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,0.026467925613205 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,0.026467925613205 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-2.5313084961454E-14 + ,-0.026467925613225 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15 + ,5.3290705182008E-15) > 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] -3.071374e-05 > sqrtn <- sqrt(length(x)) > (armse <- sd(x) / sqrtn) [1] 0.000845801 > (armose <- arm / armse) [1] -0.0363132 > (geo <- geomean(x)) [1] NaN Warning message: In log(x) : NaNs produced > (har <- harmean(x)) [1] -3.270271e-14 > (qua <- quamean(x)) [1] 0.01193153 > (win <- winmean(x)) [,1] [,2] [1,] -3.071374e-05 8.458009e-04 [2,] -3.071374e-05 8.458009e-04 [3,] -3.071374e-05 8.458009e-04 [4,] -3.071374e-05 8.458009e-04 [5,] -3.071374e-05 8.458009e-04 [6,] -3.071374e-05 8.458009e-04 [7,] -3.071374e-05 8.396516e-04 [8,] -3.071374e-05 8.396516e-04 [9,] -3.071374e-05 8.396516e-04 [10,] -3.071374e-05 8.396516e-04 [11,] -3.071374e-05 8.396516e-04 [12,] -3.071374e-05 8.396516e-04 [13,] -3.071374e-05 8.396516e-04 [14,] -3.071374e-05 8.396516e-04 [15,] -3.071374e-05 8.396516e-04 [16,] -3.071374e-05 8.396516e-04 [17,] -3.071374e-05 8.396516e-04 [18,] -3.071374e-05 8.396516e-04 [19,] -3.071374e-05 8.396516e-04 [20,] -6.449885e-04 1.334880e-04 [21,] 2.404743e-15 1.913859e-15 [22,] 2.404743e-15 1.913859e-15 [23,] 2.404743e-15 1.913859e-15 [24,] 2.404743e-15 1.913859e-15 [25,] 2.404743e-15 1.913859e-15 [26,] 2.404743e-15 1.913859e-15 [27,] 2.404743e-15 1.913859e-15 [28,] 2.404743e-15 1.913859e-15 [29,] 2.404743e-15 1.913859e-15 [30,] 2.404743e-15 1.913859e-15 [31,] 2.404743e-15 1.913859e-15 [32,] 2.404743e-15 1.913859e-15 [33,] 2.404743e-15 1.913859e-15 [34,] 2.404743e-15 1.913859e-15 [35,] 2.404743e-15 1.913859e-15 [36,] 2.404743e-15 1.913859e-15 [37,] 2.404743e-15 1.913859e-15 [38,] 2.404743e-15 1.913859e-15 [39,] 2.404743e-15 1.913859e-15 [40,] 2.404743e-15 1.913859e-15 [41,] 2.404743e-15 1.913859e-15 [42,] 2.404743e-15 1.913859e-15 [43,] 2.404743e-15 1.913859e-15 [44,] 2.404743e-15 1.913859e-15 [45,] -7.087664e-15 9.584699e-16 [46,] -7.087664e-15 9.584699e-16 [47,] -7.087664e-15 9.584699e-16 [48,] -7.087664e-15 9.584699e-16 [49,] -7.087664e-15 9.584699e-16 [50,] -7.087664e-15 9.584699e-16 [51,] -7.087664e-15 9.584699e-16 [52,] -7.087664e-15 9.584699e-16 [53,] -7.087664e-15 9.584699e-16 [54,] -7.087664e-15 9.584699e-16 [55,] -7.087664e-15 9.584699e-16 [56,] -7.087664e-15 9.584699e-16 [57,] -7.087664e-15 9.584699e-16 [58,] -7.087664e-15 9.584699e-16 [59,] -7.087664e-15 9.584699e-16 [60,] -7.087664e-15 9.584699e-16 [61,] -7.087664e-15 9.584699e-16 [62,] -7.087664e-15 9.584699e-16 [63,] -7.087664e-15 9.584699e-16 [64,] -7.087664e-15 9.584699e-16 [65,] -7.087664e-15 9.584699e-16 [66,] -7.087664e-15 9.584699e-16 > (tri <- trimean(x)) [,1] [,2] [1,] -3.102398e-05 8.321721e-04 [2,] -3.134055e-05 8.176498e-04 [3,] -3.166365e-05 8.021523e-04 [4,] -3.199348e-05 7.855861e-04 [5,] -3.233025e-05 7.678431e-04 [6,] -3.267419e-05 7.487976e-04 [7,] -3.302552e-05 7.283015e-04 [8,] -3.338450e-05 7.074166e-04 [9,] -3.375136e-05 6.848325e-04 [10,] -3.412637e-05 6.603177e-04 [11,] -3.450982e-05 6.335847e-04 [12,] -3.490197e-05 6.042688e-04 [13,] -3.530315e-05 5.718937e-04 [14,] -3.571365e-05 5.358153e-04 [15,] -3.613381e-05 4.951214e-04 [16,] -3.656397e-05 4.484360e-04 [17,] -3.700450e-05 3.934853e-04 [18,] -3.745578e-05 3.259276e-04 [19,] -3.791819e-05 2.348551e-04 [20,] -3.839217e-05 3.839217e-05 [21,] 9.275281e-17 1.862663e-15 [22,] -4.839434e-17 1.854588e-15 [23,] -1.932076e-16 1.845660e-15 [24,] -3.418318e-16 1.835805e-15 [25,] -4.944193e-16 1.824942e-15 [26,] -6.511308e-16 1.812984e-15 [27,] -8.121357e-16 1.799829e-15 [28,] -9.776131e-16 1.785368e-15 [29,] -9.776131e-16 1.769475e-15 [30,] -1.322751e-15 1.752008e-15 [31,] -1.502824e-15 1.732810e-15 [32,] -1.688192e-15 1.711698e-15 [33,] -1.879094e-15 1.688464e-15 [34,] -2.075781e-15 1.662868e-15 [35,] -2.278519e-15 1.634632e-15 [36,] -2.487593e-15 1.603430e-15 [37,] -2.703305e-15 1.568876e-15 [38,] -2.925975e-15 1.530508e-15 [39,] -3.155945e-15 1.487767e-15 [40,] -3.393582e-15 1.439961e-15 [41,] -3.639273e-15 1.386225e-15 [42,] -3.893437e-15 1.325441e-15 [43,] -4.156519e-15 1.256124e-15 [44,] -4.428997e-15 1.176224e-15 [45,] -4.711383e-15 1.082746e-15 [46,] -4.613593e-15 1.082048e-15 [47,] -4.512114e-15 1.080816e-15 [48,] -4.406731e-15 1.078984e-15 [49,] -4.297216e-15 1.076473e-15 [50,] -4.183320e-15 1.073193e-15 [51,] -4.064776e-15 1.069042e-15 [52,] -3.941292e-15 1.063898e-15 [53,] -3.812553e-15 1.057622e-15 [54,] -3.678217e-15 1.050049e-15 [55,] -3.537911e-15 1.040984e-15 [56,] -3.391227e-15 1.030196e-15 [57,] -3.391227e-15 1.017407e-15 [58,] -3.237720e-15 1.002279e-15 [59,] -2.908243e-15 9.843993e-16 [60,] -2.731149e-15 9.632518e-16 [61,] -2.544973e-15 9.381845e-16 [62,] -2.348998e-15 9.083546e-16 [63,] -2.142430e-15 8.726432e-16 [64,] -1.924387e-15 8.295136e-16 [65,] -1.693883e-15 7.767544e-16 [66,] -1.449821e-15 7.109653e-16 > (midr <- midrange(x)) [1] 2.150016e-14 > midm <- array(NA,dim=8) > for (j in 1:8) midm[j] <- midmean(x,j) > midm [1] -8.40124e-15 -8.40124e-15 -8.40124e-15 -8.40124e-15 -8.40124e-15 [6] -8.40124e-15 -8.40124e-15 -8.40124e-15 > postscript(file="/var/www/html/freestat/rcomp/tmp/19qik1290437071.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/freestat/rcomp/tmp/29qik1290437071.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/freestat/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/www/html/freestat/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/freestat/rcomp/tmp/3utrj1290437071.tab") > > try(system("convert tmp/19qik1290437071.ps tmp/19qik1290437071.png",intern=TRUE)) character(0) > try(system("convert tmp/29qik1290437071.ps tmp/29qik1290437071.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.440 0.554 1.527