R version 2.15.2 (2012-10-26) -- "Trick or Treat" Copyright (C) 2012 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i686-pc-linux-gnu (32-bit) 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 <- array(list(38.1,34.6,21.7,29.0,16.0,37.6,43.4,21.1,39.6,31.3,22.7,43.9,14.0,35.1,26.0,35.2,38.0,31.3,28.3,37.8,35.3,29.0,33.6,41.0,27.3,24.5,37.1,44.9,27.3,27.4,29.4,35.3,31.6,31.5,34.3,30.2,36.7,46.2,35.0,26.5,57.5,50.4,29.4,30.3,43.3,24.4,44.1,26.2,34.1,24.7,29.4,28.6,26.3,25.1,27.9,31.9,31.5,35.3,36.1,32.0,23.5,39.4,37.3,45.3,44.7,32.6,38.9,32.3,40.1,29.4,40.2,32.5,26.8,13.0,29.4,29.7,55.1,34.8,37.2,32.6,28.7,43.6,34.1,33.3,17.8,35.1,35.3,NA,39.2,40.3,35.0,NA,34.5,33.0,35.0,NA,34.6,26.9,33.4,NA,39.0,NA,28.3,NA),dim=c(8,13),dimnames=list(c('1','2','3','4','5','6','7','8'),1:13)) > y <- array(NA,dim=c(8,13),dimnames=list(c('1','2','3','4','5','6','7','8'),1:13)) > for (i in 1:dim(x)[1]) + { + for (j in 1:dim(x)[2]) + { + y[i,j] <- as.numeric(x[i,j]) + } + } > par1 = 'grey' > ylab = 'value' > xlab = 'variables' > main = 'Notched Boxplots' > z <- as.data.frame(t(y)) > postscript(file="/var/wessaorg/rcomp/tmp/1u1x41355781451.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > (r<-boxplot(z ,xlab=xlab,ylab=ylab,main=main,notch=TRUE,col=par1)) $stats [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 26.8 24.5 21.7 28.60 14.0 24.40 26.0 21.10 [2,] 31.5 26.9 29.4 29.95 23.5 28.20 29.4 26.50 [3,] 34.6 31.5 33.4 32.00 34.5 33.90 35.0 32.55 [4,] 39.2 35.3 35.0 35.55 39.0 36.35 37.3 35.30 [5,] 44.7 43.6 38.9 43.90 55.1 46.20 44.1 45.30 $n [1] 13 13 13 11 13 12 13 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 31.22576 27.81901 30.94601 29.33223 27.7077 30.18273 31.53812 28.15317 [2,] 37.97424 35.18099 35.85399 34.66777 41.2923 37.61727 38.46188 36.94683 $out [1] 57.5 50.4 13.0 44.9 $group [1] 1 2 2 4 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" Warning message: In bxp(list(stats = c(26.8, 31.5, 34.6, 39.2, 44.7, 24.5, 26.9, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > #Note: the /var/wessaorg/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/wessaorg/rcomp/createtable") > > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/overview.htm','Boxplot statistics','Boxplot overview'),6,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Variable',1,TRUE) > a<-table.element(a,hyperlink('http://www.xycoon.com/lower_whisker.htm','lower whisker','definition of lower whisker'),1,TRUE) > a<-table.element(a,hyperlink('http://www.xycoon.com/lower_hinge.htm','lower hinge','definition of lower hinge'),1,TRUE) > a<-table.element(a,hyperlink('http://www.xycoon.com/central_tendency.htm','median','definitions about measures of central tendency'),1,TRUE) > a<-table.element(a,hyperlink('http://www.xycoon.com/upper_hinge.htm','upper hinge','definition of upper hinge'),1,TRUE) > a<-table.element(a,hyperlink('http://www.xycoon.com/upper_whisker.htm','upper whisker','definition of upper whisker'),1,TRUE) > a<-table.row.end(a) > for (i in 1:length(y[,1])) + { + a<-table.row.start(a) + a<-table.element(a,dimnames(t(x))[[2]][i],1,TRUE) + for (j in 1:5) + { + a<-table.element(a,r$stats[j,i]) + } + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/wessaorg/rcomp/tmp/2ug7k1355781451.tab") > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,'Boxplot Notches',4,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Variable',1,TRUE) > a<-table.element(a,'lower bound',1,TRUE) > a<-table.element(a,'median',1,TRUE) > a<-table.element(a,'upper bound',1,TRUE) > a<-table.row.end(a) > for (i in 1:length(y[,1])) + { + a<-table.row.start(a) + a<-table.element(a,dimnames(t(x))[[2]][i],1,TRUE) + a<-table.element(a,r$conf[1,i]) + a<-table.element(a,r$stats[3,i]) + a<-table.element(a,r$conf[2,i]) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/wessaorg/rcomp/tmp/35d2l1355781451.tab") > > try(system("convert tmp/1u1x41355781451.ps tmp/1u1x41355781451.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 0.860 0.187 1.021