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(5,1.3,0,1.3,3,1.3,-1,-1.3,-2,-0.3,0.7,-6,-1,3,-2,-1.3,1.7,4,5.3,-3,1.3,8.7,7.3,7.3,7.7,4.7,4.7,3.7,8.3,8,8.3,12.7,11.7,9.7,9.3,9.3,7.7,8.3,7.7,7,4.3,-0.3,4.7,2,0.3,-1.7,1.3,-12.3,-14.3,-15.7,-16.7,-19,-27.3,-26.7,-26.3,-28.6,-22.9,-21.9,-17.6,-17.6,-20.8) > 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] 61 > (np <- floor(n / par1)) [1] 5 > 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 5 5 5 5 5 5 5 5 5 5 5 > arr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 5.0 -1.0 7.7 7.7 -14.3 -20.8 [2,] 1.3 3.0 4.7 8.3 -15.7 NA [3,] 0.0 -2.0 4.7 7.7 -16.7 NA [4,] 1.3 -1.3 3.7 7.0 -19.0 NA [5,] 3.0 1.7 8.3 4.3 -27.3 NA [6,] 1.3 4.0 8.0 -0.3 -26.7 NA [7,] -1.0 5.3 8.3 4.7 -26.3 NA [8,] -1.3 -3.0 12.7 2.0 -28.6 NA [9,] -2.0 1.3 11.7 0.3 -22.9 NA [10,] -0.3 8.7 9.7 -1.7 -21.9 NA [11,] 0.7 7.3 9.3 1.3 -17.6 NA [12,] -6.0 7.3 9.3 -12.3 -17.6 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/www/html/rcomp/tmp/1tgzy1257941770.ps",horizontal=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/www/html/rcomp/tmp/27taw1257941770.ps",horizontal=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/www/html/rcomp/tmp/365he1257941770.ps",horizontal=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/www/html/rcomp/tmp/423o31257941770.ps",horizontal=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,] -20.8 1.3 -2.0 -1.3 1.7 -0.3 -1.0 -3.0 -2.0 -1.7 0.7 -17.6 [2,] -14.3 1.3 -2.0 -1.3 1.7 -0.3 -1.0 -3.0 -2.0 -1.7 0.7 -12.3 [3,] 2.0 3.0 0.0 1.3 3.0 1.3 4.7 -1.3 0.3 -0.3 1.3 -6.0 [4,] 7.7 4.7 4.7 3.7 4.3 4.0 5.3 2.0 1.3 8.7 7.3 7.3 [5,] 7.7 8.3 7.7 7.0 4.3 8.0 8.3 2.0 1.3 9.7 9.3 9.3 $n [1] 6 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -12.19071 0.5975686 -4.734203 -2.232987 1.162847 -1.738369 0.2484359 [2,] 16.19071 5.4024314 4.734203 4.832987 4.837153 4.338369 9.1515641 [,8] [,9] [,10] [,11] [,12] [1,] -4.832987 -2.031772 -7.648614 -3.363543 -19.84931 [2,] 2.232987 2.631772 7.048614 5.963543 7.84931 $out [1] -15.7 -16.7 -19.0 8.3 -27.3 -26.7 -26.3 12.7 -28.6 11.7 -22.9 -21.9 [13] -17.6 $group [1] 2 3 4 5 5 6 7 8 8 9 9 10 11 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-20.8, -14.3, 2, 7.7, 7.7, 1.3, 1.3, 3, 4.7, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5rg3g1257941770.ps",horizontal=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] [1,] -2.00 -3.00 3.7 -1.70 -28.60 -20.8 [2,] -1.15 -1.15 6.2 0.00 -26.50 -20.8 [3,] 0.35 2.35 8.3 3.15 -20.45 -20.8 [4,] 1.30 6.30 9.5 7.35 -17.15 -20.8 [5,] 3.00 8.70 12.7 8.30 -14.30 -20.8 $n [1] 12 12 12 12 12 1 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] -0.7674614 -1.047995 6.794848 -0.2023843 -24.71460 -20.8 [2,] 1.4674614 5.747995 9.805152 6.5023843 -16.18540 -20.8 $out [1] 5.0 -6.0 -12.3 $group [1] 1 1 4 $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(-2, -1.15, 0.35, 1.3, 3, -3, -1.15, 2.35, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6t6t21257941770.ps",horizontal=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,] 9.32266 24.00 2.60 [2,] 10.39465 26.45 3.85 [3,] 12.41073 30.05 5.65 [4,] 13.93043 34.65 8.55 [5,] 15.22902 41.30 10.40 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 10.79804 26.30992 3.506298 [2,] 14.02342 33.79008 7.793702 $out [1] 18.0 19.6 $group [1] 3 3 $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(9.32266056445262, 10.394646082578, 12.410729780192, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1tgzy1257941770.ps tmp/1tgzy1257941770.png") > system("convert tmp/27taw1257941770.ps tmp/27taw1257941770.png") > system("convert tmp/365he1257941770.ps tmp/365he1257941770.png") > system("convert tmp/423o31257941770.ps tmp/423o31257941770.png") > system("convert tmp/5rg3g1257941770.ps tmp/5rg3g1257941770.png") > system("convert tmp/6t6t21257941770.ps tmp/6t6t21257941770.png") > > > proc.time() user system elapsed 1.055 0.800 1.819