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(5740,5639,5538,5336,7380,7279,5740,4718,4819,4819,4920,5133,4516,3898,3392,3392,5336,5538,3999,2258,3179,3179,3898,4313,4212,3179,3696,3493,5234,4819,3179,1954,3078,3392,3696,4100,3280,2572,2876,2977,5639,5639,4100,3898,4516,4212,5032,6054,6257,4819,4414,3999,6773,6976,6459,6976,6874,6054,6976,7998,8413,7178,6358,6976,9638,10458,10256,10660,10559,9537,11278,11693,12300,10458,9739,10559,12513,14254,13839,13839,14042,13333,15176,15176,14862,13120,13434,13637,14973,16714,15479,16097,15580,15277,17636,17119,16400,15378,16400,16917,17534,18354,17534,18040,17423,17322,19883,20096,19276,17838,19063,19579,20197,21118,20197,20916,20602,19478,21837,21837) > 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] 120 > (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 10 10 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [1,] 5740 4516 4212 3280 6257 8413 12300 14862 16400 19276 NA [2,] 5639 3898 3179 2572 4819 7178 10458 13120 15378 17838 NA [3,] 5538 3392 3696 2876 4414 6358 9739 13434 16400 19063 NA [4,] 5336 3392 3493 2977 3999 6976 10559 13637 16917 19579 NA [5,] 7380 5336 5234 5639 6773 9638 12513 14973 17534 20197 NA [6,] 7279 5538 4819 5639 6976 10458 14254 16714 18354 21118 NA [7,] 5740 3999 3179 4100 6459 10256 13839 15479 17534 20197 NA [8,] 4718 2258 1954 3898 6976 10660 13839 16097 18040 20916 NA [9,] 4819 3179 3078 4516 6874 10559 14042 15580 17423 20602 NA [10,] 4819 3179 3392 4212 6054 9537 13333 15277 17322 19478 NA [11,] 4920 3898 3696 5032 6976 11278 15176 17636 19883 21837 NA [12,] 5133 4313 4100 6054 7998 11693 15176 17119 20096 21837 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/1khxm1312385555.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/2k1711312385555.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/3rlal1312385555.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/4bgpa1312385555.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] [1,] 3280 2572.0 2876 2977 5234 4819.0 3179.0 1954 3078.0 3179.0 [2,] 4516 3898.0 3696 3493 5639 5639.0 4100.0 3898 4516.0 4212.0 [3,] 7335 6408.5 5948 6156 8509 8868.5 8357.5 8818 8716.5 7795.5 [4,] 14862 13120.0 13434 13637 14973 16714.0 15479.0 16097 15580.0 15277.0 [5,] 19276 17838.0 19063 19579 20197 21118.0 20197.0 20916 20602.0 19478.0 [,11] [,12] [1,] 3696 4100.0 [2,] 4920 5133.0 [3,] 9127 9845.5 [4,] 17636 17119.0 [5,] 21837 21837.0 $n [1] 10 10 10 10 10 10 10 10 10 10 10 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 2165.726 1800.821 1082.507 1087.653 3845.361 3334.988 2672.098 [2,] 12504.274 11016.179 10813.493 11224.347 13172.639 14402.012 14042.902 [,8] [,9] [,10] [,11] [,12] [1,] 2722.893 3188.484 2266.985 2773.579 3856.817 [2,] 14913.107 14244.516 13324.015 15480.421 15834.183 $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(3280, 4516, 7335, 14862, 19276, 2572, 3898, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/59ui51312385555.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] [,9] [,10] [1,] 4718.0 2258.0 1954.0 2572.0 3999.0 6358.0 9739.0 13120.0 15378.0 17838 [2,] 4869.5 3285.5 3179.0 3128.5 5436.5 7795.5 11429.5 14249.5 16658.5 19377 [3,] 5437.0 3898.0 3594.5 4156.0 6616.0 9947.0 13586.0 15378.0 17478.5 20197 [4,] 5740.0 4414.5 4156.0 5335.5 6976.0 10609.5 14148.0 16405.5 18197.0 21017 [5,] 5740.0 5538.0 5234.0 6054.0 7998.0 11693.0 15176.0 17636.0 20096.0 21837 [,11] [1,] NA [2,] NA [3,] NA [4,] NA [5,] NA $n [1] 12 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 5039.959 3383.056 3148.884 3149.372 5913.824 8663.516 12346.07 14394.63 [2,] 5834.041 4412.944 4040.116 5162.628 7318.176 11230.484 14825.93 16361.37 [,9] [,10] [,11] [1,] 16776.78 19448.98 NA [2,] 18180.22 20945.02 NA $out [1] 7380 7279 $group [1] 1 1 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" NA Warning message: In bxp(list(stats = c(4718, 4869.5, 5437, 5740, 5740, 2258, 3285.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/6ovrj1312385555.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,] 5453.988 14963.0 8326.250 [2,] 5810.614 16091.5 8941.375 [3,] 6171.900 16450.5 10276.500 [4,] 6626.701 17630.5 10936.875 [5,] 7074.625 18962.0 12073.000 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 5799.677 15748.55 9366.339 [2,] 6544.123 17152.45 11186.661 $out numeric(0) $group numeric(0) $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(5453.98796906142, 5810.61367631253, 6171.90008950125, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1khxm1312385555.ps tmp/1khxm1312385555.png",intern=TRUE)) character(0) > try(system("convert tmp/2k1711312385555.ps tmp/2k1711312385555.png",intern=TRUE)) character(0) > try(system("convert tmp/3rlal1312385555.ps tmp/3rlal1312385555.png",intern=TRUE)) character(0) > try(system("convert tmp/4bgpa1312385555.ps tmp/4bgpa1312385555.png",intern=TRUE)) character(0) > try(system("convert tmp/59ui51312385555.ps tmp/59ui51312385555.png",intern=TRUE)) character(0) > try(system("convert tmp/6ovrj1312385555.ps tmp/6ovrj1312385555.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.371 0.292 1.664