R version 2.7.2 (2008-08-25) Copyright (C) 2008 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(3180,4151,4023,3431,3874,2617,3580,5267,3832,3441,3228,3397,3971,4625,4486,4131,4686,3174,4282,4209,4159,3936,3153,3620,4227,4441,4808,4850,5040,3546,4669,5410,5134,4864,3999,4459,4622,5360,4658,5173,4845,3325,4720,4895,5071,4895,3805,4187,4435,4475,4774,5161,4529,3284,4303,4610,4691,4200,3471,3132) > 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)) > darr <- array(NA,dim=c(par1,np+1)) > ari <- array(0,dim=par1) > dx <- diff(x) > j <- 0 > for (i in 1:n) + { + j = j + 1 + ari[j] = ari[j] + 1 + arr[j,ari[j]] <- x[i] + darr[j,ari[j]] <- dx[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,] 3180 3971 4227 4622 4435 NA [2,] 4151 4625 4441 5360 4475 NA [3,] 4023 4486 4808 4658 4774 NA [4,] 3431 4131 4850 5173 5161 NA [5,] 3874 4686 5040 4845 4529 NA [6,] 2617 3174 3546 3325 3284 NA [7,] 3580 4282 4669 4720 4303 NA [8,] 5267 4209 5410 4895 4610 NA [9,] 3832 4159 5134 5071 4691 NA [10,] 3441 3936 4864 4895 4200 NA [11,] 3228 3153 3999 3805 3471 NA [12,] 3397 3620 4459 4187 3132 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 971 654 214 738 40 NA [2,] -128 -139 367 -702 299 NA [3,] -592 -355 42 515 387 NA [4,] 443 555 190 -328 -632 NA [5,] -1257 -1512 -1494 -1520 -1245 NA [6,] 963 1108 1123 1395 1019 NA [7,] 1687 -73 741 175 307 NA [8,] -1435 -50 -276 176 81 NA [9,] -391 -223 -270 -176 -491 NA [10,] -213 -783 -865 -1090 -729 NA [11,] 169 467 460 382 -339 NA [12,] 574 607 163 248 NA NA > arr.mean <- array(NA,dim=par1) > arr.median <- array(NA,dim=par1) > arr.midrange <- array(NA,dim=par1) > for (j in 1:par1) + { + arr.mean[j] <- mean(arr[j,],na.rm=TRUE) + arr.median[j] <- median(arr[j,],na.rm=TRUE) + arr.midrange[j] <- (quantile(arr[j,],0.75,na.rm=TRUE) + quantile(arr[j,],0.25,na.rm=TRUE)) / 2 + } > overall.mean <- mean(x) > overall.median <- median(x) > overall.midrange <- (quantile(x,0.75) + quantile(x,0.25)) / 2 > postscript(file="/var/www/html/rcomp/tmp/1b30l1225643331.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.mean,type='b',ylab='mean',main='Mean Plot',xlab='Periodic Index') > mtext(paste('#blocks = ',np)) > abline(overall.mean,0) > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/26y3p1225643331.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.median,type='b',ylab='median',main='Median Plot',xlab='Periodic Index') > mtext(paste('#blocks = ',np)) > abline(overall.median,0) > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/3g10z1225643331.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.midrange,type='b',ylab='midrange',main='Midrange Plot',xlab='Periodic Index') > mtext(paste('#blocks = ',np)) > abline(overall.midrange,0) > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/4jsns1225643331.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,] 3971 4441 4486 3431 4529 3174 4282 4209 3832 3441 3153 3132 [2,] 3971 4441 4486 4131 4529 3174 4282 4610 4159 3936 3228 3397 [3,] 4227 4475 4658 4850 4686 3284 4303 4895 4691 4200 3471 3620 [4,] 4435 4625 4774 5161 4845 3325 4669 5267 5071 4864 3805 4187 [5,] 4622 4625 4808 5173 5040 3546 4720 5410 5134 4895 3999 4459 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 3899.139 4344.986 4454.5 4122.205 4462.715 3177.304 4029.547 4430.765 [2,] 4554.861 4605.014 4861.5 5577.795 4909.285 3390.696 4576.453 5359.235 [,9] [,10] [,11] [,12] [1,] 4046.583 3544.278 3063.293 3061.788 [2,] 5335.417 4855.722 3878.707 4178.212 $out [1] 3180 4151 5360 4023 3874 2617 3580 $group [1] 1 2 2 3 5 6 7 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(3971, 3971, 4227, 4435, 4622, 4441, 4441, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5ya951225643331.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > z <- data.frame(t(darr)) > names(z) <- c(1:par1) > (boxplot(z,notch=TRUE,col='grey',xlab='Periodic Index',ylab='Value',main='Notched Box Plots - Differenced Periodic Subseries')) $stats [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [1,] 40 -702 -592 -632 -1520 963 -73 -276 -491 -865 169 163.0 [2,] 214 -139 -355 -328 -1512 1019 175 -276 -391 -865 169 205.5 [3,] 654 -128 42 190 -1494 1108 307 -50 -270 -783 382 411.0 [4,] 738 299 387 443 -1257 1123 741 81 -223 -729 460 590.5 [5,] 971 367 515 555 -1245 1123 741 176 -176 -729 467 607.0 $n [1] 5 5 5 5 5 5 5 5 5 5 5 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 283.7429 -437.4897 -482.2953 -354.7867 -1674.182 1034.514 -92.93417 [2,] 1024.2571 181.4897 566.2953 734.7867 -1313.818 1181.486 706.93417 [,8] [,9] [,10] [,11] [,12] [1,] -302.2553 -388.7084 -879.0973 176.3801 106.85 [2,] 202.2553 -151.2916 -686.9027 587.6199 715.15 $out [1] 1395 1687 -1435 -213 -1090 -339 $group [1] 6 7 8 10 10 11 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(40, 214, 654, 738, 971, -702, -139, -128, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6g90l1225643331.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,] 2617.0 3153 3546.0 3805.0 3132.0 NA [2,] 3312.5 3778 4334.0 4404.5 3835.5 NA [3,] 3510.5 4145 4738.5 4782.5 4455.0 NA [4,] 3948.5 4384 4952.0 4983.0 4650.5 NA [5,] 4151.0 4686 5410.0 5360.0 5161.0 NA $n [1] 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 3220.416 3868.599 4456.626 4518.642 4083.273 NA [2,] 3800.584 4421.401 5020.374 5046.358 4826.727 NA $out [1] 5267 3325 $group [1] 1 4 $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(2617, 3312.5, 3510.5, 3948.5, 4151, 3153, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7wkuo1225643331.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > z <- data.frame(cbind(arr.mean,arr.median,arr.midrange)) > names(z) <- list('mean','median','midrange') > (boxplot(z,notch=TRUE,col='grey',ylab='Overall Central Tendency',main='Notched Box Plots')) $stats [,1] [,2] [,3] [1,] 3189.2 3284.0 3249.50 [2,] 3923.0 3910.0 3997.50 [3,] 4430.0 4389.0 4504.25 [4,] 4586.1 4688.5 4638.00 [5,] 4878.2 4895.0 4938.50 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 4127.556 4033.921 4212.114 [2,] 4732.444 4744.079 4796.386 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(3189.2, 3923, 4430, 4586.1, 4878.2, 3284, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1b30l1225643331.ps tmp/1b30l1225643331.png") > system("convert tmp/26y3p1225643331.ps tmp/26y3p1225643331.png") > system("convert tmp/3g10z1225643331.ps tmp/3g10z1225643331.png") > system("convert tmp/4jsns1225643331.ps tmp/4jsns1225643331.png") > system("convert tmp/5ya951225643331.ps tmp/5ya951225643331.png") > system("convert tmp/6g90l1225643331.ps tmp/6g90l1225643331.png") > system("convert tmp/7wkuo1225643331.ps tmp/7wkuo1225643331.png") > > > proc.time() user system elapsed 1.428 0.961 1.756