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(25000,25284,12434.5,33955,14980.5,50831,4198.5,34566,35000,11055.5,20807,21887.29,16977.5,19613.5,14570,24416.5,16825.5,13980,21450.5,27239.5,19078.5,20459.1,20373.5,19306.5,16723.16,11638,20917,17903.5,28218.5,15268,21555,23143,16691,17932.5,30512,41931.5,10853.5,25939.5,14900,25127.76,22063.5,25306.5,31217.5,23201.5,38148,26264,16359,27945.5,16218.5,36003.5,20323.5,20100.5,18741,24426.75,19174.5,13766,18999,21745,34469,13248,16218.5,36003.5,20323.5,20100.5,18741,24426.75,19174.5,13766,18999,21745,34469,13248) > par1 = '4' > #'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] 18 > 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] 18 18 18 18 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [1,] 25000.0 14980.5 35000.00 16977.5 16825.5 19078.5 16723.16 28218.5 16691.0 [2,] 25284.0 50831.0 11055.50 19613.5 13980.0 20459.1 11638.00 15268.0 17932.5 [3,] 12434.5 4198.5 20807.00 14570.0 21450.5 20373.5 20917.00 21555.0 30512.0 [4,] 33955.0 34566.0 21887.29 24416.5 27239.5 19306.5 17903.50 23143.0 41931.5 [,10] [,11] [,12] [,13] [,14] [,15] [,16] [,17] [,18] [1,] 10853.50 22063.5 38148.0 16218.5 18741.00 18999 16218.5 18741.00 18999 [2,] 25939.50 25306.5 26264.0 36003.5 24426.75 21745 36003.5 24426.75 21745 [3,] 14900.00 31217.5 16359.0 20323.5 19174.50 34469 20323.5 19174.50 34469 [4,] 25127.76 23201.5 27945.5 20100.5 13766.00 13248 20100.5 13766.00 13248 [,19] [1,] NA [2,] NA [3,] NA [4,] 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/1m0721275772802.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/2m0721275772802.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/3w97n1275772802.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/4w97n1275772802.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] [1,] 10853.5 11055.50 12434.5 13248.00 [2,] 16691.0 17932.50 16359.0 17903.50 [3,] 18741.0 23085.88 20348.5 22515.15 [4,] 22063.5 25939.50 21555.0 27239.50 [5,] 28218.5 36003.50 21555.0 34566.00 $n [1] 18 18 18 18 $conf [,1] [,2] [,3] [,4] [1,] 16740.23 20103.99 18413.46 19038.33 [2,] 20741.77 26067.76 22283.54 25991.96 $out [1] 35000.0 38148.0 50831.0 4198.5 30512.0 31217.5 34469.0 34469.0 41931.5 $group [1] 1 1 2 3 3 3 3 3 4 $names [1] "1" "2" "3" "4" Warning message: In bxp(list(stats = c(10853.5, 16691, 18741, 22063.5, 28218.5, 11055.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5w97n1275772802.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] [,7] [,8] [1,] 12434.50 4198.50 11055.50 14570.00 13980.00 19078.5 11638.00 15268.00 [2,] 18717.25 9589.50 15931.25 15773.75 15402.75 19192.5 14180.58 18411.50 [3,] 25142.00 24773.25 21347.15 18295.50 19138.00 19840.0 17313.33 22349.00 [4,] 29619.50 42698.50 28443.65 22015.00 24345.00 20416.3 19410.25 25680.75 [5,] 33955.00 50831.00 35000.00 24416.50 27239.50 20459.1 20917.00 28218.50 [,9] [,10] [,11] [,12] [,13] [,14] [,15] [,16] [1,] 16691.00 10853.50 22063.5 16359.00 16218.5 13766.00 13248.0 16218.5 [2,] 17311.75 12876.75 22632.5 21311.50 18159.5 16253.50 16123.5 18159.5 [3,] 24222.25 20013.88 24254.0 27104.75 20212.0 18957.75 20372.0 20212.0 [4,] 36221.75 25533.63 28262.0 33046.75 28163.5 21800.62 28107.0 28163.5 [5,] 41931.50 25939.50 31217.5 38148.00 36003.5 24426.75 34469.0 36003.5 [,17] [,18] [,19] [1,] 13766.00 13248.0 NA [2,] 16253.50 16123.5 NA [3,] 18957.75 20372.0 NA [4,] 21800.62 28107.0 NA [5,] 24426.75 34469.0 NA $n [1] 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 16529.22 -1382.86 11462.35 13364.91 12073.62 18873.20 13181.89 16606.29 [2,] 33754.78 50929.36 31231.94 23226.09 26202.38 20806.80 21444.77 28091.71 [,9] [,10] [,11] [,12] [,13] [,14] [,15] [,16] [1,] 9283.35 10014.94 19806.69 17833.90 12308.84 14575.52 10905.03 12308.84 [2,] 39161.15 30012.82 28701.31 36375.60 28115.16 23339.98 29838.97 28115.16 [,17] [,18] [,19] [1,] 14575.52 10905.03 NA [2,] 23339.98 29838.97 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" [16] "16" "17" "18" NA Warning message: In bxp(list(stats = c(12434.5, 18717.25, 25142, 29619.5, 33955, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6p0681275772802.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,] 6993.848 27294.5 4466.000 [2,] 7373.608 27989.0 4542.105 [3,] 7861.170 29477.0 6023.355 [4,] 8828.442 35023.0 7942.907 [5,] 9687.910 39775.5 8457.315 $n [1] 4 4 4 $conf [,1] [,2] [,3] [1,] 6711.852 23920.14 3336.721 [2,] 9010.489 35033.86 8709.989 $out numeric(0) $group numeric(0) $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(6993.84844751546, 7373.60810628424, 7861.17035827406, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1m0721275772802.ps tmp/1m0721275772802.png",intern=TRUE)) character(0) > try(system("convert tmp/2m0721275772802.ps tmp/2m0721275772802.png",intern=TRUE)) character(0) > try(system("convert tmp/3w97n1275772802.ps tmp/3w97n1275772802.png",intern=TRUE)) character(0) > try(system("convert tmp/4w97n1275772802.ps tmp/4w97n1275772802.png",intern=TRUE)) character(0) > try(system("convert tmp/5w97n1275772802.ps tmp/5w97n1275772802.png",intern=TRUE)) character(0) > try(system("convert tmp/6p0681275772802.ps tmp/6p0681275772802.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.065 0.832 18.263