R version 2.8.1 (2008-12-22) 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(14.5,14.3,15.3,14.4,13.7,14.2,13.5,11.9,14.6,15.6,14.1,14.9,14.2,14.6,17.2,15.4,14.3,17.5,14.5,14.4,16.6,16.7,16.6,16.9,15.7,16.4,18.4,16.9,16.5,18.3,15.1,15.7,18.1,16.8,18.9,19,18.1,17.8,21.5,17.1,18.7,19,16.4,16.9,18.6,19.3,19.4,17.6,18.6,18.1,20.4,18.1,19.6,19.9,19.2,17.8,19.2,22,21.1,19.5,22.2,20.9,22.2,23.5,21.5,24.3,22.8,20.3,23.7,23.3,19.6,18,17.3,16.8,18.2,16.5,16,18.4) > 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] 78 > (np <- floor(n / par1)) [1] 6 > 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] 7 7 7 7 7 7 6 6 6 6 6 6 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 14.5 14.2 15.7 18.1 18.6 22.2 17.3 [2,] 14.3 14.6 16.4 17.8 18.1 20.9 16.8 [3,] 15.3 17.2 18.4 21.5 20.4 22.2 18.2 [4,] 14.4 15.4 16.9 17.1 18.1 23.5 16.5 [5,] 13.7 14.3 16.5 18.7 19.6 21.5 16.0 [6,] 14.2 17.5 18.3 19.0 19.9 24.3 18.4 [7,] 13.5 14.5 15.1 16.4 19.2 22.8 NA [8,] 11.9 14.4 15.7 16.9 17.8 20.3 NA [9,] 14.6 16.6 18.1 18.6 19.2 23.7 NA [10,] 15.6 16.7 16.8 19.3 22.0 23.3 NA [11,] 14.1 16.6 18.9 19.4 21.1 19.6 NA [12,] 14.9 16.9 19.0 17.6 19.5 18.0 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.2 0.4 0.7 -0.3 -0.5 -1.3 -0.5 [2,] 1.0 2.6 2.0 3.7 2.3 1.3 1.4 [3,] -0.9 -1.8 -1.5 -4.4 -2.3 1.3 -1.7 [4,] -0.7 -1.1 -0.4 1.6 1.5 -2.0 -0.5 [5,] 0.5 3.2 1.8 0.3 0.3 2.8 2.4 [6,] -0.7 -3.0 -3.2 -2.6 -0.7 -1.5 NA [7,] -1.6 -0.1 0.6 0.5 -1.4 -2.5 NA [8,] 2.7 2.2 2.4 1.7 1.4 3.4 NA [9,] 1.0 0.1 -1.3 0.7 2.8 -0.4 NA [10,] -1.5 -0.1 2.1 0.1 -0.9 -3.7 NA [11,] 0.8 0.3 0.1 -1.8 -1.6 -1.6 NA [12,] -0.7 -1.2 -0.9 1.0 2.7 -0.7 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/rcomp/tmp/1kkq91257884370.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/rcomp/tmp/2plfp1257884370.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/rcomp/tmp/3cdgv1257884370.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/rcomp/tmp/4irxk1257884370.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,] 14.20 14.30 15.30 14.40 13.70 17.50 13.50 11.9 14.60 15.60 14.10 14.9 [2,] 15.10 15.50 17.70 15.95 15.15 17.90 14.50 14.4 16.60 16.70 16.60 16.9 [3,] 17.30 16.80 18.40 16.90 16.50 18.40 15.75 16.3 18.35 18.05 19.15 17.8 [4,] 18.35 17.95 20.95 17.60 19.15 19.45 19.20 17.8 19.20 22.00 19.60 19.0 [5,] 22.20 20.90 22.20 18.10 21.50 19.90 22.80 20.3 19.20 23.30 21.10 19.5 $n [1] 7 7 7 7 7 7 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 15.35915 15.3369 16.45915 15.91465 14.11126 17.47437 12.71835 14.10689 [2,] 19.24085 18.2631 20.34085 17.88535 18.88874 19.32563 18.78165 18.49311 [,9] [,10] [,11] [,12] [1,] 16.67292 14.63133 17.21490 16.44543 [2,] 20.02708 21.46867 21.08510 19.15457 $out [1] 23.5 14.2 24.3 23.7 $group [1] 4 6 6 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(14.2, 15.1, 17.3, 18.35, 22.2, 14.3, 15.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/5imyq1257884370.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,] -1.3 1.00 -2.30 -2.00 0.3 -3.20 -2.50 1.4 -1.3 -3.7 -1.80 -1.2 [2,] -0.5 1.35 -2.05 -0.90 0.4 -3.00 -1.60 1.7 -0.4 -1.5 -1.60 -0.9 [3,] -0.3 2.00 -1.70 -0.50 1.8 -2.05 -0.75 2.3 0.4 -0.5 -0.75 -0.7 [4,] 0.1 2.45 -1.20 0.55 2.6 -0.70 0.50 2.7 1.0 0.1 0.30 1.0 [5,] 0.7 3.70 -0.90 1.60 3.2 -0.70 0.60 3.4 2.8 2.1 0.80 2.7 $n [1] 7 7 7 7 7 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.65831032 1.343098 -2.207606 -1.3659166 0.4861955 -3.5335743 -2.1045678 [2,] 0.05831032 2.656902 -1.192394 0.3659166 3.1138045 -0.5664257 0.6045678 [,8] [,9] [,10] [,11] [,12] [1,] 1.654968 -0.5030452 -1.5320517 -1.9755614 -1.9255614 [2,] 2.945032 1.3030452 0.5320517 0.4755614 0.5255614 $out [1] -4.4 1.3 $group [1] 3 3 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-1.3, -0.5, -0.300000000000001, 0.100000000000001, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/67lb41257884370.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] [1,] 13.50 14.20 15.10 16.40 17.80 18.0 16.00 [2,] 13.90 14.45 16.05 17.35 18.35 20.6 16.50 [3,] 14.35 16.00 16.85 18.35 19.35 22.2 17.05 [4,] 14.75 16.80 18.35 19.15 20.15 23.4 18.20 [5,] 15.60 17.50 19.00 21.50 22.00 24.3 18.40 $n [1] 12 12 12 12 12 12 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 13.96231 14.92815 15.80095 17.52901 18.52901 20.9229 15.95345 [2,] 14.73769 17.07185 17.89905 19.17099 20.17099 23.4771 18.14655 $out [1] 11.9 $group [1] 1 $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(13.5, 13.9, 14.35, 14.75, 15.6, 14.2, 14.45, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/7iy491257884370.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,] 16.16667 15.750 16.15000 [2,] 17.08571 16.650 16.72500 [3,] 17.53214 17.550 17.53125 [4,] 18.63333 18.375 18.51875 [5,] 19.02857 19.150 19.32500 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 16.82626 16.76322 16.71311 [2,] 18.23802 18.33678 18.34939 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(16.1666666666667, 17.0857142857143, 17.5321428571429, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1kkq91257884370.ps tmp/1kkq91257884370.png") > system("convert tmp/2plfp1257884370.ps tmp/2plfp1257884370.png") > system("convert tmp/3cdgv1257884370.ps tmp/3cdgv1257884370.png") > system("convert tmp/4irxk1257884370.ps tmp/4irxk1257884370.png") > system("convert tmp/5imyq1257884370.ps tmp/5imyq1257884370.png") > system("convert tmp/67lb41257884370.ps tmp/67lb41257884370.png") > system("convert tmp/7iy491257884370.ps tmp/7iy491257884370.png") > > > proc.time() user system elapsed 1.520 1.410 2.815