R version 2.12.1 (2010-12-16) Copyright (C) 2010 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(193.230,199.068,195.076,191.563,191.067,186.665,185.508,184.371,183.046,175.714,175.768,171.029,170.465,170.102,156.389,124.291,99.360,86.675,85.056,128.236,164.257,162.401,152.779,156.005,153.387,153.190,148.840,144.211,145.953,145.542,150.271,147.489,143.824,134.754,131.736,126.304,125.511,125.495,130.133,126.257,110.323,98.417,105.749,120.665,124.075,127.245,146.731,144.979,148.210,144.670,142.970,142.524,146.142,146.522,148.128,148.798,150.181,152.388,155.694,160.662,155.520,158.262,154.338,158.196,160.371,154.856,150.636,145.899,141.242,140.834,141.119,139.104,134.437,129.425,123.155,119.273,120.472,121.523,121.983,123.658,124.794,124.827,120.382,117.395,115.790,114.283,117.271,117.448,118.764,120.550,123.554,125.412,124.182,119.828,115.361,114.226,115.214,115.864,114.276,113.469) > par1 = '10' > #'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] 100 > (np <- floor(n / par1)) [1] 10 > 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] 10 10 10 10 10 10 10 10 10 10 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [1,] 193.230 175.768 164.257 150.271 110.323 142.970 155.520 141.119 124.794 [2,] 199.068 171.029 162.401 147.489 98.417 142.524 158.262 139.104 124.827 [3,] 195.076 170.465 152.779 143.824 105.749 146.142 154.338 134.437 120.382 [4,] 191.563 170.102 156.005 134.754 120.665 146.522 158.196 129.425 117.395 [5,] 191.067 156.389 153.387 131.736 124.075 148.128 160.371 123.155 115.790 [6,] 186.665 124.291 153.190 126.304 127.245 148.798 154.856 119.273 114.283 [7,] 185.508 99.360 148.840 125.511 146.731 150.181 150.636 120.472 117.271 [8,] 184.371 86.675 144.211 125.495 144.979 152.388 145.899 121.523 117.448 [9,] 183.046 85.056 145.953 130.133 148.210 155.694 141.242 121.983 118.764 [10,] 175.714 128.236 145.542 126.257 144.670 160.662 140.834 123.658 120.550 [,10] [,11] [1,] 123.554 NA [2,] 125.412 NA [3,] 124.182 NA [4,] 119.828 NA [5,] 115.361 NA [6,] 114.226 NA [7,] 115.214 NA [8,] 115.864 NA [9,] 114.276 NA [10,] 113.469 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/rcomp/tmp/1s8y71305848671.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/rcomp/tmp/2hf771305848671.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/rcomp/tmp/3wxzz1305848671.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/rcomp/tmp/446zj1305848671.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] [1,] 110.3230 98.4170 105.749 117.395 115.361 114.2260 99.360 86.675 [2,] 124.7940 125.4120 124.182 120.665 123.155 119.2730 117.271 117.448 [3,] 146.6205 145.0065 144.983 140.638 139.932 126.7745 136.121 134.853 [4,] 164.2570 162.4010 154.338 158.196 156.389 153.1900 150.181 145.899 [5,] 193.2300 199.0680 195.076 191.563 191.067 186.6650 185.508 184.371 [,9] [,10] [1,] 85.0560 113.469 [2,] 118.7640 123.658 [3,] 135.6875 134.535 [4,] 148.2100 145.542 [5,] 183.0460 175.714 $n [1] 10 10 10 10 10 10 10 10 10 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 126.9032 126.5253 129.9159 121.8860 123.3270 109.8282 119.6779 120.6377 [2,] 166.3378 163.4877 160.0501 159.3900 156.5370 143.7208 152.5641 149.0683 [,9] [,10] [1,] 120.9751 123.6009 [2,] 150.3999 145.4691 $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" Warning message: In bxp(list(stats = c(110.323, 124.794, 146.6205, 164.257, 193.23, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/5vv3b1305848671.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] [,8] [1,] 175.714 85.0560 144.2110 125.4950 98.417 142.524 140.834 119.2730 [2,] 184.371 99.3600 145.9530 126.2570 110.323 146.142 145.899 121.5230 [3,] 188.866 142.3125 152.9845 130.9345 125.660 148.463 154.597 123.4065 [4,] 193.230 170.4650 156.0050 143.8240 144.979 152.388 158.196 134.4370 [5,] 199.068 175.7680 164.2570 150.2710 148.210 160.662 160.371 141.1190 [,9] [,10] [,11] [1,] 114.283 113.4690 NA [2,] 117.271 114.2760 NA [3,] 118.106 115.6125 NA [4,] 120.550 123.5540 NA [5,] 124.827 125.4120 NA $n [1] 10 10 10 10 10 10 10 10 10 10 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 184.4397 106.7856 147.9621 122.1573 108.3445 145.3422 148.4529 116.9542 [2,] 193.2923 177.8394 158.0069 139.7117 142.9755 151.5838 160.7411 129.8588 [,9] [,10] [,11] [1,] 116.4677 110.9768 NA [2,] 119.7443 120.2482 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" NA Warning message: In bxp(list(stats = c(175.714, 184.371, 188.866, 193.23, 199.068, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/6olk01305848671.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,] 23.34935 62.2450 21.01625 [2,] 24.26173 74.1680 27.20250 [3,] 25.15857 84.5275 31.66950 [4,] 26.48304 97.6960 32.53125 [5,] 27.99383 100.6510 34.79325 $n [1] 10 10 10 $conf [,1] [,2] [,3] [1,] 24.04871 72.77197 29.00704 [2,] 26.26842 96.28303 34.33196 $out [1] 19.40932 $group [1] 1 $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(23.34934965761, 24.2617305027669, 25.1585693735036, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1s8y71305848671.ps tmp/1s8y71305848671.png",intern=TRUE)) character(0) > try(system("convert tmp/2hf771305848671.ps tmp/2hf771305848671.png",intern=TRUE)) character(0) > try(system("convert tmp/3wxzz1305848671.ps tmp/3wxzz1305848671.png",intern=TRUE)) character(0) > try(system("convert tmp/446zj1305848671.ps tmp/446zj1305848671.png",intern=TRUE)) character(0) > try(system("convert tmp/5vv3b1305848671.ps tmp/5vv3b1305848671.png",intern=TRUE)) character(0) > try(system("convert tmp/6olk01305848671.ps tmp/6olk01305848671.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 2.500 0.424 2.901