R version 2.8.0 (2008-10-20) 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. Natural language support but running in an English locale 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(13,16,19,15,14,13,19,15,14,15,16,16,16,17,15,15,20,18,16,16,19,16,17,17,16,15,14,15,12,14,16,14,7,10,14,16,16,16,14,20,14,14,11,15,16,14,16,14,12,16,9,14,16,16,15,16,12,16,16,14,16,17,18,18,12,16,10,14,18,18,16,16,16,13,16,16,20,16,15,15,16,14,15,12,17,16,15,13,16,16,16,16,14,16,16,20,15,16,13,17,16,12,16,16,17,13,12,18,14,14,13,16,13,16,13,16,15,16,15,17,15,12,16,10,16,14,15,13,15,11,12,8,16,15,17,16,10,18,13,15,16,16,14,10,17,13,15,16,12,13) > 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] 150 > (np <- floor(n / par1)) [1] 12 > 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] 13 13 13 13 13 13 12 12 12 12 12 12 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [,13] [1,] 13 16 16 16 12 16 16 17 15 14 15 16 17 [2,] 16 17 15 16 16 17 13 16 16 14 12 15 13 [3,] 19 15 14 14 9 18 16 15 13 13 16 17 15 [4,] 15 15 15 20 14 18 16 13 17 16 10 16 16 [5,] 14 20 12 14 16 12 20 16 16 13 16 10 12 [6,] 13 18 14 14 16 16 16 16 12 16 14 18 13 [7,] 19 16 16 11 15 10 15 16 16 13 15 13 NA [8,] 15 16 14 15 16 14 15 16 16 16 13 15 NA [9,] 14 19 7 16 12 18 16 14 17 15 15 16 NA [10,] 15 16 10 14 16 18 14 16 13 16 11 16 NA [11,] 16 17 14 16 16 16 15 16 12 15 12 14 NA [12,] 16 17 16 14 14 16 12 20 18 17 8 10 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [,13] [1,] 3 1 -1 0 4 1 -3 -1 1 0 -3 -1 -4 [2,] 3 -2 -1 -2 -7 1 3 -1 -3 -1 4 2 2 [3,] -4 0 1 6 5 0 0 -2 4 3 -6 -1 1 [4,] -1 5 -3 -6 2 -6 4 3 -1 -3 6 -6 -4 [5,] -1 -2 2 0 0 4 -4 0 -4 3 -2 8 1 [6,] 6 -2 2 -3 -1 -6 -1 0 4 -3 1 -5 NA [7,] -4 0 -2 4 1 4 0 0 0 3 -2 2 NA [8,] -1 3 -7 1 -4 4 1 -2 1 -1 2 1 NA [9,] 1 -3 3 -2 4 0 -2 2 -4 1 -4 0 NA [10,] 1 1 4 2 0 -2 1 0 -1 -1 1 -2 NA [11,] 0 0 2 -2 -2 0 -3 4 6 2 -4 -4 NA [12,] 0 -1 0 -2 2 0 5 -5 -4 -2 8 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/html/freestat/rcomp/tmp/1920n1292696565.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/www/html/freestat/rcomp/tmp/2920n1292696565.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/www/html/freestat/rcomp/tmp/3ktiq1292696565.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/www/html/freestat/rcomp/tmp/4ktiq1292696565.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] [,12] [1,] 14 12 13 14 10 12 10 13.0 12.0 10.0 12.0 8 [2,] 15 14 14 15 12 14 13 14.5 14.0 13.5 14.0 13 [3,] 16 16 15 16 14 16 15 15.0 15.5 15.5 15.5 16 [4,] 16 16 16 16 16 16 16 16.0 16.5 16.0 16.0 17 [5,] 17 17 19 17 20 18 19 16.0 19.0 18.0 17.0 20 $n [1] 13 13 13 13 13 13 12 12 12 12 12 12 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 15.56179 15.12357 14.12357 15.56179 12.24715 15.12357 13.63168 14.31584 [2,] 16.43821 16.87643 15.87643 16.43821 15.75285 16.87643 16.36832 15.68416 [,9] [,10] [,11] [,12] [1,] 14.35973 14.35973 14.58779 14.17557 [2,] 16.64027 16.64027 16.41221 17.82443 $out [1] 13 12 9 20 18 13 10 7 $group [1] 1 1 3 4 4 4 4 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(14, 15, 16, 16, 17, 12, 14, 16, 16, 17, 13, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/5ktiq1292696565.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] [,12] [1,] -4 -7 -6 -6 -4 -6.0 -4.0 -4.0 -4.0 -2.0 -4.0 -5.0 [2,] -1 -2 -1 -4 -2 -3.0 -1.0 -1.5 -2.5 -1.0 -2.5 -2.0 [3,] 0 -1 0 -1 0 -1.0 0.0 1.0 0.0 0.5 0.0 0.0 [4,] 1 2 3 3 2 1.5 2.5 1.5 1.5 1.0 2.0 3.5 [5,] 4 4 6 6 8 6.0 4.0 4.0 4.0 4.0 6.0 8.0 $n [1] 13 13 13 13 13 12 12 12 12 12 12 12 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.8764263 -2.7528526 -1.752853 -4.067492 -1.752853 -3.052480 -1.596373 [2,] 0.8764263 0.7528526 1.752853 2.067492 1.752853 1.052480 1.596373 [,8] [,9] [,10] [,11] [,12] [1,] -0.3683201 -1.824427 -0.4122134 -2.052480 -2.508587 [2,] 2.3683201 1.824427 1.4122134 2.052480 2.508587 $out [1] -7 $group [1] 8 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-4, -1, 0, 1, 4, -7, -2, -1, 2, 4, -6, -1, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/6ukzb1292696565.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] [,11] [,12] [,13] [1,] 13 15.0 10.0 11.0 9.0 12 13.0 15.0 12.0 13.0 8.0 10.0 12 [2,] 14 16.0 13.0 14.0 13.0 15 14.5 15.5 13.0 13.5 11.5 13.5 13 [3,] 15 16.5 14.0 14.5 15.5 16 15.5 16.0 16.0 15.0 13.5 15.5 14 [4,] 16 17.5 15.5 16.0 16.0 18 16.0 16.0 16.5 16.0 15.0 16.0 16 [5,] 19 19.0 16.0 16.0 16.0 18 16.0 16.0 18.0 17.0 16.0 18.0 17 $n [1] 12 12 12 12 12 12 12 12 12 12 12 12 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 14.08779 15.81584 12.85973 13.58779 14.13168 14.63168 14.81584 15.77195 [2,] 15.91221 17.18416 15.14027 15.41221 16.86832 17.36832 16.18416 16.22805 [,9] [,10] [,11] [,12] [,13] [1,] 14.40363 13.85973 11.90363 14.35973 12.06490 [2,] 17.59637 16.14027 15.09637 16.64027 15.93510 $out [1] 20 7 20 10 20 12 17 13 14 20 $group [1] 2 3 4 6 7 7 8 8 8 8 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" NA Warning message: In bxp(list(stats = c(13, 14, 15, 16, 19, 15, 16, 16.5, 17.5, 19, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/7ukzb1292696565.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,] 14.58333 14.0 14.5000 [2,] 14.76282 15.0 14.9375 [3,] 14.91987 15.5 15.0000 [4,] 15.08013 16.0 15.3125 [5,] 15.46154 16.0 15.5000 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 14.77515 15.04389 14.82896 [2,] 15.06460 15.95611 15.17104 $out [1] 14 $group [1] 3 $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(14.5833333333333, 14.7628205128205, 14.9198717948718, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1920n1292696565.ps tmp/1920n1292696565.png",intern=TRUE)) character(0) > try(system("convert tmp/2920n1292696565.ps tmp/2920n1292696565.png",intern=TRUE)) character(0) > try(system("convert tmp/3ktiq1292696565.ps tmp/3ktiq1292696565.png",intern=TRUE)) character(0) > try(system("convert tmp/4ktiq1292696565.ps tmp/4ktiq1292696565.png",intern=TRUE)) character(0) > try(system("convert tmp/5ktiq1292696565.ps tmp/5ktiq1292696565.png",intern=TRUE)) character(0) > try(system("convert tmp/6ukzb1292696565.ps tmp/6ukzb1292696565.png",intern=TRUE)) character(0) > try(system("convert tmp/7ukzb1292696565.ps tmp/7ukzb1292696565.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.941 1.470 2.241