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(349 + ,336 + ,331 + ,327 + ,323 + ,322 + ,385 + ,405 + ,412 + ,411 + ,410 + ,415 + ,414 + ,411 + ,408 + ,410 + ,411 + ,416 + ,479 + ,498 + ,502 + ,498 + ,499 + ,506 + ,510 + ,509 + ,502 + ,495 + ,490 + ,490 + ,553 + ,570 + ,573 + ,572 + ,575 + ,580 + ,580 + ,574 + ,563 + ,556 + ,546 + ,545 + ,605 + ,628 + ,631 + ,626 + ,614 + ,606 + ,602 + ,589 + ,574 + ,558 + ,552 + ,546 + ,607 + ,636 + ,631 + ,623 + ,618 + ,605 + ,619 + ,596 + ,570 + ,546 + ,528 + ,506 + ,555 + ,568 + ,564 + ,553 + ,541 + ,542 + ,540 + ,521 + ,505 + ,491 + ,482 + ,478 + ,523 + ,531 + ,532 + ,540 + ,525 + ,533 + ,531 + ,508 + ,495 + ,482 + ,470 + ,466 + ,515 + ,518 + ,516 + ,511 + ,500 + ,498 + ,494 + ,476 + ,458 + ,443 + ,430 + ,424 + ,476 + ,481 + ,470 + ,460 + ,451 + ,450 + ,444 + ,429 + ,421 + ,400 + ,389 + ,384 + ,432 + ,446 + ,431 + ,423 + ,416 + ,416 + ,413 + ,399 + ,386 + ,374 + ,365 + ,365 + ,418 + ,428 + ,424 + ,421 + ,417 + ,423 + ,423 + ,419 + ,406 + ,398 + ,390 + ,391 + ,444 + ,460 + ,455 + ,456 + ,452 + ,459 + ,461 + ,451 + ,443 + ,439 + ,430 + ,436 + ,488 + ,506 + ,502 + ,501 + ,501 + ,515 + ,521 + ,520 + ,512 + ,509 + ,505 + ,511 + ,570 + ,592 + ,594 + ,586 + ,586 + ,592 + ,594 + ,586 + ,572 + ,563 + ,555 + ,554 + ,601 + ,622 + ,617 + ,606 + ,595 + ,599 + ,600 + ,592 + ,575 + ,567 + ,555 + ,555 + ,608 + ,631 + ,629 + ,624 + ,610 + ,616 + ,621 + ,604 + ,584 + ,574 + ,555 + ,545 + ,599 + ,620 + ,608 + ,590 + ,579 + ,580 + ,579 + ,572 + ,560 + ,551 + ,537 + ,541 + ,588 + ,607 + ,599 + ,578 + ,563 + ,566 + ,561 + ,554 + ,540 + ,526 + ,512 + ,505 + ,554 + ,584 + ,569 + ,540 + ,522 + ,526 + ,527 + ,516 + ,503 + ,489 + ,479 + ,475 + ,524 + ,552 + ,532 + ,511 + ,492 + ,492 + ,493 + ,481 + ,462 + ,457 + ,442 + ,439 + ,488 + ,521 + ,501 + ,485 + ,464 + ,460 + ,467 + ,460 + ,448 + ,443 + ,436 + ,431 + ,484 + ,510 + ,513 + ,503 + ,471 + ,471 + ,476 + ,475 + ,470 + ,461 + ,455 + ,456 + ,517 + ,525 + ,523 + ,519 + ,509 + ,512 + ,519 + ,517 + ,510 + ,509 + ,501 + ,507 + ,569 + ,580 + ,578 + ,565 + ,547 + ,555 + ,562 + ,561 + ,555 + ,544 + ,537 + ,543 + ,594 + ,611 + ,613 + ,611 + ,594 + ,595 + ,591 + ,589 + ,584 + ,573 + ,567 + ,569 + ,621 + ,629 + ,628 + ,612 + ,595 + ,597 + ,593 + ,590 + ,580 + ,574 + ,573 + ,573 + ,620 + ,626 + ,620 + ,588 + ,566 + ,557 + ,561 + ,549 + ,532 + ,526 + ,511 + ,499 + ,555 + ,565 + ,542 + ,527 + ,510 + ,514 + ,517 + ,508 + ,493 + ,490 + ,469 + ,478 + ,528 + ,534 + ,518 + ,506 + ,502 + ,516 + ,528 + ,533 + ,536 + ,537 + ,524 + ,536 + ,587 + ,597 + ,581 + ,564 + ,558) > 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] 518.8691 > sqrtn <- sqrt(length(x)) > (armse <- sd(x) / sqrtn) [1] 3.606310 > (armose <- arm / armse) [1] 143.8781 > (geo <- geomean(x)) [1] 514.0874 > (har <- harmean(x)) [1] 508.9793 > (qua <- quamean(x)) [1] 523.3365 > (win <- winmean(x)) [,1] [,2] [1,] 518.8579 3.604649 [2,] 518.8802 3.601300 [3,] 518.9136 3.596373 [4,] 518.9471 3.586413 [5,] 519.1281 3.561431 [6,] 519.3788 3.525790 [7,] 519.3788 3.525790 [8,] 519.5348 3.498057 [9,] 519.7855 3.469785 [10,] 519.7577 3.462023 [11,] 519.7577 3.456134 [12,] 519.8245 3.442611 [13,] 519.8245 3.435788 [14,] 519.8635 3.431685 [15,] 520.1142 3.398228 [16,] 520.1588 3.393769 [17,] 520.2061 3.389062 [18,] 520.4067 3.360501 [19,] 520.4067 3.351118 [20,] 520.4624 3.336041 [21,] 520.5209 3.320380 [22,] 520.3983 3.310618 [23,] 520.3983 3.299627 [24,] 520.3315 3.294408 [25,] 520.2618 3.289019 [26,] 520.3343 3.282320 [27,] 520.3343 3.269623 [28,] 520.2563 3.250631 [29,] 520.3370 3.243278 [30,] 520.3370 3.229430 [31,] 520.3370 3.229430 [32,] 520.2479 3.222777 [33,] 520.3398 3.214497 [34,] 520.3398 3.198987 [35,] 520.4373 3.190302 [36,] 520.5376 3.165181 [37,] 520.3315 3.150126 [38,] 520.4373 3.123935 [39,] 520.3287 3.116143 [40,] 520.2173 3.108220 [41,] 520.3315 3.098272 [42,] 520.3315 3.098272 [43,] 520.5710 3.040180 [44,] 520.6936 3.029788 [45,] 520.6936 3.010427 [46,] 520.5655 3.001512 [47,] 520.6964 2.990510 [48,] 520.6964 2.990510 [49,] 520.6964 2.969657 [50,] 521.2535 2.923725 [51,] 521.2535 2.923725 [52,] 521.6880 2.888654 [53,] 521.5404 2.878374 [54,] 521.8412 2.832111 [55,] 521.9944 2.820085 [56,] 521.9944 2.820085 [57,] 521.8357 2.809120 [58,] 521.8357 2.785405 [59,] 521.8357 2.785405 [60,] 522.0028 2.748043 [61,] 522.3426 2.721953 [62,] 522.5153 2.683950 [63,] 522.6908 2.670749 [64,] 522.5125 2.658621 [65,] 522.5125 2.632815 [66,] 523.0641 2.591954 [67,] 523.0641 2.591954 [68,] 522.8747 2.552557 [69,] 522.8747 2.552557 [70,] 523.0696 2.538334 [71,] 522.6741 2.484606 [72,] 522.6741 2.456945 [73,] 522.8774 2.442273 [74,] 522.8774 2.442273 [75,] 522.8774 2.442273 [76,] 522.8774 2.442273 [77,] 522.8774 2.412904 [78,] 522.8774 2.412904 [79,] 522.8774 2.382912 [80,] 523.3231 2.351304 [81,] 523.0975 2.276043 [82,] 523.3259 2.260089 [83,] 523.5571 2.213332 [84,] 523.7911 2.197277 [85,] 523.7911 2.197277 [86,] 523.7911 2.197277 [87,] 523.7911 2.165312 [88,] 523.7911 2.165312 [89,] 524.7827 2.098679 [90,] 524.7827 2.098679 [91,] 524.7827 2.065694 [92,] 524.7827 2.065694 [93,] 524.7827 2.065694 [94,] 524.7827 1.998021 [95,] 524.7827 1.998021 [96,] 525.0501 1.980592 [97,] 524.7799 1.963529 [98,] 525.3259 1.928220 [99,] 525.3259 1.928220 [100,] 525.3259 1.892788 [101,] 525.0446 1.875137 [102,] 525.6128 1.838958 [103,] 525.6128 1.802868 [104,] 526.4819 1.748806 [105,] 526.1894 1.730413 [106,] 526.4847 1.712284 [107,] 526.4847 1.675421 [108,] 526.4847 1.675421 [109,] 526.1811 1.656500 [110,] 526.4875 1.637880 [111,] 526.7967 1.619243 [112,] 526.4847 1.599828 [113,] 526.4847 1.561447 [114,] 526.4847 1.561447 [115,] 526.8050 1.542336 [116,] 526.8050 1.503217 [117,] 526.1532 1.463298 [118,] 527.1393 1.405408 [119,] 526.8078 1.385151 > (tri <- trimean(x)) [,1] [,2] [1,] 519.0924 3.569139 [2,] 519.3296 3.532295 [3,] 519.5581 3.495839 [4,] 519.7778 3.459785 [5,] 519.9914 3.425122 [6,] 520.1700 3.394803 [7,] 520.3072 3.370161 [8,] 520.4461 3.344619 [9,] 520.5660 3.322221 [10,] 520.6578 3.302750 [11,] 520.7537 3.283495 [12,] 520.8507 3.264184 [13,] 520.9429 3.245558 [14,] 521.0363 3.226898 [15,] 521.1277 3.207916 [16,] 521.2018 3.191120 [17,] 521.2738 3.174056 [18,] 521.3437 3.156713 [19,] 521.4019 3.140854 [20,] 521.4608 3.125055 [21,] 521.5174 3.109685 [22,] 521.5714 3.094758 [23,] 521.6326 3.079862 [24,] 521.6945 3.065059 [25,] 521.7605 3.049974 [26,] 521.8306 3.034594 [27,] 521.8984 3.018983 [28,] 521.9670 3.003454 [29,] 522.0399 2.988334 [30,] 522.1104 2.972990 [31,] 522.1818 2.957744 [32,] 522.2542 2.941855 [33,] 522.3311 2.925631 [34,] 522.4055 2.909147 [35,] 522.4810 2.892739 [36,] 522.5540 2.876063 [37,] 522.6246 2.859905 [38,] 522.7032 2.843747 [39,] 522.7794 2.828136 [40,] 522.8602 2.812184 [41,] 522.9458 2.795873 [42,] 523.0291 2.779300 [43,] 523.1136 2.761973 [44,] 523.1919 2.746534 [45,] 523.2677 2.730859 [46,] 523.3446 2.715319 [47,] 523.4264 2.699429 [48,] 523.5057 2.683288 [49,] 523.5862 2.666377 [50,] 523.6680 2.649576 [51,] 523.7354 2.634035 [52,] 523.8039 2.617733 [53,] 523.8617 2.602194 [54,] 523.9243 2.586313 [55,] 523.9799 2.571648 [56,] 524.0324 2.556764 [57,] 524.0324 2.541121 [58,] 524.1440 2.525131 [59,] 524.1440 2.509329 [60,] 524.2636 2.492704 [61,] 524.2636 2.476824 [62,] 524.3702 2.461246 [63,] 524.3702 2.446462 [64,] 524.4589 2.431448 [65,] 524.5066 2.416114 [66,] 524.5551 2.401033 [67,] 524.5911 2.386887 [68,] 524.6278 2.371942 [69,] 524.6697 2.357807 [70,] 524.7123 2.342857 [71,] 524.7512 2.327669 [72,] 524.8000 2.313856 [73,] 524.8498 2.300395 [74,] 524.8957 2.286763 [75,] 524.9426 2.272301 [76,] 524.9903 2.256956 [77,] 525.0390 2.240671 [78,] 525.0887 2.224688 [79,] 525.1393 2.207710 [80,] 525.1910 2.191024 [81,] 525.2335 2.174764 [82,] 525.2821 2.160819 [83,] 525.3264 2.146691 [84,] 525.3665 2.133737 [85,] 525.4021 2.120640 [86,] 525.4385 2.106639 [87,] 525.4757 2.091672 [88,] 525.5137 2.077159 [89,] 525.5525 2.061625 [90,] 525.5698 2.048222 [91,] 525.5876 2.033844 [92,] 525.6057 2.019997 [93,] 525.6057 2.005123 [94,] 525.6433 1.989145 [95,] 525.6627 1.975332 [96,] 525.6826 1.960454 [97,] 525.6826 1.945325 [98,] 525.7178 1.929875 [99,] 525.7267 1.915063 [100,] 525.7358 1.899062 [101,] 525.7452 1.883659 [102,] 525.7613 1.867928 [103,] 525.7647 1.852878 [104,] 525.7682 1.838524 [105,] 525.7517 1.825855 [106,] 525.7415 1.813067 [107,] 525.7241 1.800103 [108,] 525.7063 1.788007 [109,] 525.6879 1.774756 [110,] 525.6763 1.761366 [111,] 525.6569 1.747765 [112,] 525.6296 1.733925 [113,] 525.6090 1.719934 [114,] 525.6090 1.706912 [115,] 525.5659 1.692538 [116,] 525.5354 1.677870 [117,] 525.5040 1.664220 [118,] 525.5040 1.651794 [119,] 525.4463 1.641614 > (midr <- midrange(x)) [1] 479 > midm <- array(NA,dim=8) > for (j in 1:8) midm[j] <- midmean(x,j) > midm [1] 526.071 526.071 526.071 526.071 526.071 526.071 526.071 526.071 > postscript(file="/var/www/html/rcomp/tmp/1vybe1260627387.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/2799h1260627387.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/3vvtn1260627388.tab") > > system("convert tmp/1vybe1260627387.ps tmp/1vybe1260627387.png") > system("convert tmp/2799h1260627387.ps tmp/2799h1260627387.png") > > > proc.time() user system elapsed 1.990 0.356 2.136