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(47,19,52,136,80,42,54,66,81,63,137,72,107,58,36,52,79,77,54,84,48,96,83,66,61,53,30,74,69,59,42,65,70,100,63,105,82,81,75,102,121,98,76,77,63,37,35,23,40,29,37,51,20,28,13,22,25,13,16,13,16,17,9,17,25,14,8,7,10,7,10,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,] 47 107 61 82 40 16 NA [2,] 19 58 53 81 29 17 NA [3,] 52 36 30 75 37 9 NA [4,] 136 52 74 102 51 17 NA [5,] 80 79 69 121 20 25 NA [6,] 42 77 59 98 28 14 NA [7,] 54 54 42 76 13 8 NA [8,] 66 84 65 77 22 7 NA [9,] 81 48 70 63 25 10 NA [10,] 63 96 100 37 13 7 NA [11,] 137 83 63 35 16 10 NA [12,] 72 66 105 23 13 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/www/html/rcomp/tmp/185na1291659188.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/www/html/rcomp/tmp/285na1291659188.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/www/html/rcomp/tmp/3jw5d1291659188.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/www/html/rcomp/tmp/4jw5d1291659188.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,] 16 17 9.0 17 20 14.0 8 7.0 10.0 7 10 3.0 [2,] 40 19 30.0 51 25 28.0 13 22.0 25.0 13 16 13.0 [3,] 54 41 36.5 63 74 50.5 48 65.5 55.5 50 49 44.5 [4,] 82 58 52.0 102 80 77.0 54 77.0 70.0 96 83 72.0 [5,] 107 81 75.0 136 121 98.0 76 84.0 81.0 100 137 105.0 $n [1] 6 6 6 6 6 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 26.90864 15.84374 22.30929 30.10335 38.52322 18.89342 21.55368 30.02322 [2,] 81.09136 66.15626 50.69071 95.89665 109.47678 82.10658 74.44632 100.97678 [,9] [,10] [,11] [,12] [1,] 26.47355 -3.537681 5.782836 6.443094 [2,] 84.52645 103.537681 92.217164 82.556906 $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(16, 40, 54, 82, 107, 17, 19, 41, 58, 81, 9, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5u5my1291659188.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,] 19.0 36.0 42 23.0 13.0 3.0 NA [2,] 49.5 53.0 56 50.0 14.5 7.5 NA [3,] 64.5 71.5 64 76.5 23.5 10.0 NA [4,] 80.5 83.5 72 90.0 33.0 16.5 NA [5,] 81.0 107.0 74 121.0 51.0 25.0 NA $n [1] 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 50.36069 57.58875 56.70229 58.25573 15.06203 5.89504 NA [2,] 78.63931 85.41125 71.29771 94.74427 31.93797 14.10496 NA $out [1] 136 137 30 100 105 $group [1] 1 1 3 3 3 $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(19, 49.5, 64.5, 80.5, 81, 36, 53, 71.5, 83.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6u5my1291659188.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,] 22.15777 64.0 16.750 [2,] 26.81559 69.5 35.125 [3,] 31.80345 87.5 41.250 [4,] 40.18351 101.5 49.375 [5,] 47.92772 127.0 68.750 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 25.70625 72.90459 34.75048 [2,] 37.90064 102.09541 47.74952 $out numeric(0) $group numeric(0) $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(22.1577676372568, 26.8155894189034, 31.8034482867863, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/185na1291659188.ps tmp/185na1291659188.png",intern=TRUE)) character(0) > try(system("convert tmp/285na1291659188.ps tmp/285na1291659188.png",intern=TRUE)) character(0) > try(system("convert tmp/3jw5d1291659188.ps tmp/3jw5d1291659188.png",intern=TRUE)) character(0) > try(system("convert tmp/4jw5d1291659188.ps tmp/4jw5d1291659188.png",intern=TRUE)) character(0) > try(system("convert tmp/5u5my1291659188.ps tmp/5u5my1291659188.png",intern=TRUE)) character(0) > try(system("convert tmp/6u5my1291659188.ps tmp/6u5my1291659188.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.065 0.850 2.986