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(9.829,9.125,9.782,9.441,9.162,9.915,10.444,10.209,9.985,9.842,9.429,10.132,9.849,9.172,10.313,9.819,9.955,10.048,10.082,10.541,10.208,10.233,9.439,9.963,10.158,9.225,10.474,9.757,10.490,10.281,10.444,10.640,10.695,10.786,9.832,9.747,10.411,9.511,10.402,9.701,10.540,10.112,10.915,11.183,10.384,10.834,9.886,10.216,10.943,9.867,10.203,10.837,10.573,10.647,11.502,10.656,10.866,10.835,9.945,10.331) > 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,] 9.829 9.849 10.158 10.411 10.943 NA [2,] 9.125 9.172 9.225 9.511 9.867 NA [3,] 9.782 10.313 10.474 10.402 10.203 NA [4,] 9.441 9.819 9.757 9.701 10.837 NA [5,] 9.162 9.955 10.490 10.540 10.573 NA [6,] 9.915 10.048 10.281 10.112 10.647 NA [7,] 10.444 10.082 10.444 10.915 11.502 NA [8,] 10.209 10.541 10.640 11.183 10.656 NA [9,] 9.985 10.208 10.695 10.384 10.866 NA [10,] 9.842 10.233 10.786 10.834 10.835 NA [11,] 9.429 9.439 9.832 9.886 9.945 NA [12,] 10.132 9.963 9.747 10.216 10.331 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] -0.704 -0.677 -0.933 -0.900 -1.076 NA [2,] 0.657 1.141 1.249 0.891 0.336 NA [3,] -0.341 -0.494 -0.717 -0.701 0.634 NA [4,] -0.279 0.136 0.733 0.839 -0.264 NA [5,] 0.753 0.093 -0.209 -0.428 0.074 NA [6,] 0.529 0.034 0.163 0.803 0.855 NA [7,] -0.235 0.459 0.196 0.268 -0.846 NA [8,] -0.224 -0.333 0.055 -0.799 0.210 NA [9,] -0.143 0.025 0.091 0.450 -0.031 NA [10,] -0.413 -0.794 -0.954 -0.948 -0.890 NA [11,] 0.703 0.524 -0.085 0.330 0.386 NA [12,] -0.283 0.195 0.664 0.727 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/wessaorg/rcomp/tmp/1rovu1322755733.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/2f4jc1322755733.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/3c8ca1322755733.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/4mcu61322755733.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] [,11] [1,] 9.829 9.125 10.203 9.701 9.162 9.915 10.082 10.541 9.985 9.842 9.429 [2,] 9.849 9.172 10.203 9.701 9.955 10.048 10.444 10.541 10.208 10.233 9.439 [3,] 10.158 9.225 10.313 9.757 10.490 10.112 10.444 10.640 10.384 10.786 9.832 [4,] 10.411 9.511 10.402 9.819 10.540 10.281 10.915 10.656 10.695 10.834 9.886 [5,] 10.943 9.867 10.474 9.819 10.573 10.281 11.502 10.656 10.866 10.835 9.945 [,12] [1,] 9.747 [2,] 9.963 [3,] 10.132 [4,] 10.216 [5,] 10.331 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 9.760892 8.985463 10.17239 9.673621 10.07664 9.947363 10.11119 10.55874 [2,] 10.555108 9.464537 10.45361 9.840379 10.90336 10.276637 10.77681 10.72126 [,9] [,10] [,11] [,12] [1,] 10.03989 10.36133 9.516151 9.953231 [2,] 10.72811 11.21067 10.147849 10.310769 $out [1] 9.782 9.441 10.837 10.647 10.209 11.183 $group [1] 3 4 4 6 8 8 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(9.829, 9.849, 10.158, 10.411, 10.943, 9.125, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/5xuo11322755733.ps",horizontal=F,onefile=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] [1,] -1.076 0.336 -0.717 -0.279 -0.428 0.034 -0.846 -0.799 -0.143 -0.954 0.330 [2,] -0.933 0.657 -0.701 -0.264 -0.209 0.163 -0.235 -0.333 -0.031 -0.948 0.330 [3,] -0.900 0.891 -0.494 0.136 0.074 0.529 0.196 -0.224 0.025 -0.890 0.386 [4,] -0.704 1.141 -0.341 0.733 0.093 0.803 0.268 0.055 0.091 -0.794 0.524 [5,] -0.677 1.249 -0.341 0.839 0.093 0.855 0.459 0.210 0.091 -0.794 0.703 [,12] [1,] -0.2830 [2,] -0.0440 [3,] 0.4295 [4,] 0.6955 [5,] 0.7270 $n [1] 5 5 5 5 5 5 5 5 5 5 5 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] -1.0618108 0.5490068 -0.7483751 -0.5684777 -0.1393924 0.07677761 [2,] -0.7381892 1.2329932 -0.2396249 0.8404777 0.2873924 0.98122239 [,7] [,8] [,9] [,10] [,11] [,12] [1,] -0.1594185 -0.49815982 -0.06120489 -0.998816 0.2489201 -0.154705 [2,] 0.5514185 0.05015982 0.11120489 -0.781184 0.5230799 1.013705 $out [1] 0.634 0.753 0.450 -0.413 -0.085 $group [1] 3 5 9 10 11 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-1.076, -0.933, -0.9, -0.704000000000001, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/6n82s1322755733.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] [1,] 9.1250 9.4390 9.2250 9.511 9.8670 NA [2,] 9.4350 9.8340 9.7945 9.999 10.2670 NA [3,] 9.8355 10.0055 10.3625 10.393 10.6515 NA [4,] 10.0585 10.2205 10.5650 10.687 10.8515 NA [5,] 10.4440 10.5410 10.7860 11.183 11.5020 NA $n [1] 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 9.551117 9.829215 10.01107 10.0792 10.38491 NA [2,] 10.119883 10.181785 10.71393 10.7068 10.91809 NA $out [1] 9.172 $group [1] 2 $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(9.125, 9.435, 9.8355, 10.0585, 10.444, 9.439, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/754dr1322755733.ps",horizontal=F,onefile=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,] 9.3800 9.7570 9.34150 [2,] 9.9944 9.9720 9.92475 [3,] 10.2177 10.2355 10.20600 [4,] 10.4668 10.4670 10.49250 [5,] 10.6774 10.7860 10.67950 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 10.00224 10.00973 9.947045 [2,] 10.43316 10.46127 10.464955 $out [1] 9.225 $group [1] 2 $names [1] "mean" "median" "midrange" > dev.off() null device 1 > > try(system("convert tmp/1rovu1322755733.ps tmp/1rovu1322755733.png",intern=TRUE)) character(0) > try(system("convert tmp/2f4jc1322755733.ps tmp/2f4jc1322755733.png",intern=TRUE)) character(0) > try(system("convert tmp/3c8ca1322755733.ps tmp/3c8ca1322755733.png",intern=TRUE)) character(0) > try(system("convert tmp/4mcu61322755733.ps tmp/4mcu61322755733.png",intern=TRUE)) character(0) > try(system("convert tmp/5xuo11322755733.ps tmp/5xuo11322755733.png",intern=TRUE)) character(0) > try(system("convert tmp/6n82s1322755733.ps tmp/6n82s1322755733.png",intern=TRUE)) character(0) > try(system("convert tmp/754dr1322755733.ps tmp/754dr1322755733.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.609 0.332 1.952