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(115.6,111.9,107,107.1,100.6,99.2,108.4,103,99.8,115,90.8,95.9,114.4,108.2,112.6,109.1,105,105,118.5,103.7,112.5,116.6,96.6,101.9,116.5,119.3,115.4,108.5,111.5,108.8,121.8,109.6,112.2,119.6,104.1,105.3,115,124.1,116.8,107.5,115.6,116.2,116.3,119,111.9,118.6,106.9,103.2,118.6,118.7,102.8,100.6,94.9,94.5,102.9,95.3,92.5,102.7,91.5,89.5) > 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] 60 > (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] 5 5 5 5 5 5 5 5 5 5 5 5 > arr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 115.6 114.4 116.5 115.0 118.6 NA [2,] 111.9 108.2 119.3 124.1 118.7 NA [3,] 107.0 112.6 115.4 116.8 102.8 NA [4,] 107.1 109.1 108.5 107.5 100.6 NA [5,] 100.6 105.0 111.5 115.6 94.9 NA [6,] 99.2 105.0 108.8 116.2 94.5 NA [7,] 108.4 118.5 121.8 116.3 102.9 NA [8,] 103.0 103.7 109.6 119.0 95.3 NA [9,] 99.8 112.5 112.2 111.9 92.5 NA [10,] 115.0 116.6 119.6 118.6 102.7 NA [11,] 90.8 96.6 104.1 106.9 91.5 NA [12,] 95.9 101.9 105.3 103.2 89.5 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/18wji1258139222.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/2w1g01258139222.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/3kvvv1258139222.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/4bdbf1258139222.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,] 114.4 108.2 102.8 107.1 94.9 94.5 102.9 95.3 92.5 115.0 90.8 89.5 [2,] 115.0 111.9 107.0 107.1 100.6 99.2 108.4 103.0 99.8 115.0 91.5 95.9 [3,] 115.6 118.7 112.6 107.5 105.0 105.0 116.3 103.7 111.9 116.6 96.6 101.9 [4,] 116.5 119.3 115.4 108.5 111.5 108.8 118.5 109.6 112.2 118.6 104.1 103.2 [5,] 118.6 124.1 116.8 109.1 115.6 116.2 121.8 119.0 112.5 119.6 106.9 105.3 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 114.5401 113.4712 106.6646 106.5108 97.29809 98.21666 109.1634 99.03646 [2,] 116.6599 123.9288 118.5354 108.4892 112.70191 111.78334 123.4366 108.36354 [,9] [,10] [,11] [,12] [1,] 103.1382 114.0562 87.69687 96.74184 [2,] 120.6618 119.1438 105.50313 107.05816 $out [1] 100.6 102.7 $group [1] 4 10 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(114.4, 115, 115.6, 116.5, 118.6, 108.2, 111.9, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5qtzn1258139222.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,] 90.80 96.60 104.10 103.2 89.50 NA [2,] 99.50 104.35 108.65 109.7 93.50 NA [3,] 105.00 108.65 111.85 115.9 97.95 NA [4,] 110.15 113.50 117.90 117.7 102.85 NA [5,] 115.60 118.50 121.80 124.1 102.90 NA $n [1] 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 100.1425 104.4766 107.6310 112.2511 93.6854 NA [2,] 109.8575 112.8234 116.0690 119.5489 102.2146 NA $out [1] 118.6 118.7 $group [1] 5 5 $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(90.8, 99.5, 105, 110.15, 115.6, 96.6, 104.35, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6t47q1258139222.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,] 3.424617 8.50 1.4 [2,] 6.111934 14.90 5.1 [3,] 7.060209 16.50 7.9 [4,] 8.351836 20.35 10.5 [5,] 9.164442 23.70 12.6 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 6.038575 14.01422 5.437024 [2,] 8.081843 18.98578 10.362976 $out [1] 1.637681 4.200000 $group [1] 1 2 $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(3.42461676688064, 6.11193434033134, 7.06020869671878, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/18wji1258139222.ps tmp/18wji1258139222.png") > system("convert tmp/2w1g01258139222.ps tmp/2w1g01258139222.png") > system("convert tmp/3kvvv1258139222.ps tmp/3kvvv1258139222.png") > system("convert tmp/4bdbf1258139222.ps tmp/4bdbf1258139222.png") > system("convert tmp/5qtzn1258139222.ps tmp/5qtzn1258139222.png") > system("convert tmp/6t47q1258139222.ps tmp/6t47q1258139222.png") > > > proc.time() user system elapsed 1.077 0.811 1.341