R version 2.13.0 (2011-04-13) Copyright (C) 2011 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i486-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 <- c(14.5,15.1,17.4,16.2,15.6,17.2,14.9,13.8,17.5,16.2,17.5,16.6,16.2,16.6,19.6,15.9,18,18.3,16.3,14.9,18.2,18.4,18.5,16,17.4,17.2,19.6,17.2,18.3,19.3,18.1,16.2,18.4,20.5,19,16.5,18.7,19,19.2,20.5,19.3,20.6,20.1,16.1,20.4,19.7,15.6,14.4,13.7,14.1,15,14.2,13.6,15.4,14.8,12.5,16.2,16.1,16,15.8,14.9,15.4,18.6,17.1,16.8,19.5,17.3,15.8,19.3,18.8,18.5,17.3) > par1 = '12' > #'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!) > par1 <- as.numeric(par1) > (n <- length(x)) [1] 72 > (np <- floor(n / par1)) [1] 6 > arr <- array(NA,dim=c(par1,np+1)) > ari <- array(0,dim=par1) > j <- 0 > for (i in 1:n) + { + j = j + 1 + ari[j] = ari[j] + 1 + arr[j,ari[j]] <- x[i] + if (j == par1) j = 0 + } > ari [1] 6 6 6 6 6 6 6 6 6 6 6 6 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 14.5 16.2 17.4 18.7 13.7 14.9 NA [2,] 15.1 16.6 17.2 19.0 14.1 15.4 NA [3,] 17.4 19.6 19.6 19.2 15.0 18.6 NA [4,] 16.2 15.9 17.2 20.5 14.2 17.1 NA [5,] 15.6 18.0 18.3 19.3 13.6 16.8 NA [6,] 17.2 18.3 19.3 20.6 15.4 19.5 NA [7,] 14.9 16.3 18.1 20.1 14.8 17.3 NA [8,] 13.8 14.9 16.2 16.1 12.5 15.8 NA [9,] 17.5 18.2 18.4 20.4 16.2 19.3 NA [10,] 16.2 18.4 20.5 19.7 16.1 18.8 NA [11,] 17.5 18.5 19.0 15.6 16.0 18.5 NA [12,] 16.6 16.0 16.5 14.4 15.8 17.3 NA > arr.sd <- array(NA,dim=par1) > arr.range <- array(NA,dim=par1) > arr.iqr <- array(NA,dim=par1) > for (j in 1:par1) + { + arr.sd[j] <- sqrt(var(arr[j,],na.rm=TRUE)) + arr.range[j] <- max(arr[j,],na.rm=TRUE) - min(arr[j,],na.rm=TRUE) + arr.iqr[j] <- quantile(arr[j,],0.75,na.rm=TRUE) - quantile(arr[j,],0.25,na.rm=TRUE) + } > overall.sd <- sqrt(var(x)) > overall.range <- max(x) - min(x) > overall.iqr <- quantile(x,0.75) - quantile(x,0.25) > postscript(file="/var/wessaorg/rcomp/tmp/1mx561322571442.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.sd,type='b',ylab='S.D.',main='Standard Deviation Plot',xlab='Periodic Index') > mtext(paste('# blocks = ',np)) > abline(overall.sd,0) > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/24i8w1322571442.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.range,type='b',ylab='range',main='Range Plot',xlab='Periodic Index') > mtext(paste('# blocks = ',np)) > abline(overall.range,0) > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/3gjed1322571442.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.iqr,type='b',ylab='IQR',main='Interquartile Range Plot',xlab='Periodic Index') > mtext(paste('# blocks = ',np)) > abline(overall.iqr,0) > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/423yn1322571442.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > z <- data.frame(t(arr)) > names(z) <- c(1:par1) > (boxplot(z,notch=TRUE,col='grey',xlab='Periodic Index',ylab='Value',main='Notched Box Plots - Periodic Subseries')) $stats [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [1,] 13.70 14.1 15.0 14.20 13.6 15.4 14.8 12.50 16.2 16.1 15.6 15.80 [2,] 14.50 15.1 17.4 15.90 15.6 17.2 14.9 13.80 17.5 16.2 16.0 15.80 [3,] 15.55 16.0 18.9 16.65 17.4 18.8 16.8 15.35 18.3 18.6 18.0 16.25 [4,] 17.40 17.2 19.6 17.20 18.3 19.5 18.1 16.10 19.3 19.7 18.5 16.60 [5,] 18.70 19.0 19.6 17.20 19.3 20.6 20.1 16.20 20.4 20.5 19.0 17.30 $n [1] 6 6 6 6 6 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 13.67941 14.64543 17.48093 15.81146 15.65841 17.31643 14.7359 13.86643 [2,] 17.42059 17.35457 20.31907 17.48854 19.14159 20.28357 18.8641 16.83357 [,9] [,10] [,11] [,12] [1,] 17.13894 16.34239 16.38742 15.73397 [2,] 19.46106 20.85761 19.61258 16.76603 $out [1] 20.5 14.4 $group [1] 4 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(13.7, 14.5, 15.55, 17.4, 18.7, 14.1, 15.1, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/5yvu91322571442.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > z <- data.frame(arr) > names(z) <- c(1:np) > (boxplot(z,notch=TRUE,col='grey',xlab='Block Index',ylab='Value',main='Notched Box Plots - Sequential Blocks')) $stats [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 13.8 14.90 16.20 14.40 12.5 14.9 NA [2,] 15.0 16.10 17.20 17.40 13.9 16.3 NA [3,] 16.2 17.30 18.20 19.25 14.9 17.3 NA [4,] 17.3 18.35 19.15 20.25 15.9 18.7 NA [5,] 17.5 19.60 20.50 20.60 16.2 19.5 NA $n [1] 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 15.15095 16.27376 17.31059 17.9501 13.98779 16.20534 NA [2,] 17.24905 18.32624 19.08941 20.5499 15.81221 18.39466 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(13.8, 15, 16.2, 17.3, 17.5, 14.9, 16.1, 17.3, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/6n4us1322571442.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > z <- data.frame(cbind(arr.sd,arr.range,arr.iqr)) > names(z) <- list('S.D.','Range','IQR') > (boxplot(z,notch=TRUE,col='grey',ylab='Overall Variability',main='Notched Box Plots')) $stats [,1] [,2] [,3] [1,] 0.9838699 2.90 0.7250 [2,] 1.4621715 3.95 1.6000 [3,] 1.7961261 4.75 1.9625 [4,] 1.9632505 5.25 2.4125 [5,] 2.0906937 6.30 2.7250 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 1.567581 4.157061 1.591913 [2,] 2.024672 5.342939 2.333087 $out numeric(0) $group numeric(0) $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(0.983869910099908, 1.46217146634168, 1.79612611061709, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1mx561322571442.ps tmp/1mx561322571442.png",intern=TRUE)) character(0) > try(system("convert tmp/24i8w1322571442.ps tmp/24i8w1322571442.png",intern=TRUE)) character(0) > try(system("convert tmp/3gjed1322571442.ps tmp/3gjed1322571442.png",intern=TRUE)) character(0) > try(system("convert tmp/423yn1322571442.ps tmp/423yn1322571442.png",intern=TRUE)) character(0) > try(system("convert tmp/5yvu91322571442.ps tmp/5yvu91322571442.png",intern=TRUE)) character(0) > try(system("convert tmp/6n4us1322571442.ps tmp/6n4us1322571442.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.390 0.274 1.667