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(3.2,1.9,0,0.6,0.2,0.9,2.4,4.7,9.4,12.5,15.8,18.2,16.8,17.3,19.3,17.9,20.2,18.7,20.1,18.2,18.4,18.2,18.9,19.9,21.3,20,19.5,19.6,20.9,21,19.9,19.6,20.9,21.7,22.9,21.5,21.3,23.5,21.6,24.5,22.2,23.5,20.9,20.7,18.1,17.1,14.8,13.8,15.2,16,17.6,15,15,16.3,19.4,21.3,20.5,21.1,21.6,22.6) > 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,] 3.2 16.8 21.3 21.3 15.2 NA [2,] 1.9 17.3 20.0 23.5 16.0 NA [3,] 0.0 19.3 19.5 21.6 17.6 NA [4,] 0.6 17.9 19.6 24.5 15.0 NA [5,] 0.2 20.2 20.9 22.2 15.0 NA [6,] 0.9 18.7 21.0 23.5 16.3 NA [7,] 2.4 20.1 19.9 20.9 19.4 NA [8,] 4.7 18.2 19.6 20.7 21.3 NA [9,] 9.4 18.4 20.9 18.1 20.5 NA [10,] 12.5 18.2 21.7 17.1 21.1 NA [11,] 15.8 18.9 22.9 14.8 21.6 NA [12,] 18.2 19.9 21.5 13.8 22.6 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] -1.3 0.5 -1.3 2.2 0.8 NA [2,] -1.9 2.0 -0.5 -1.9 1.6 NA [3,] 0.6 -1.4 0.1 2.9 -2.6 NA [4,] -0.4 2.3 1.3 -2.3 0.0 NA [5,] 0.7 -1.5 0.1 1.3 1.3 NA [6,] 1.5 1.4 -1.1 -2.6 3.1 NA [7,] 2.3 -1.9 -0.3 -0.2 1.9 NA [8,] 4.7 0.2 1.3 -2.6 -0.8 NA [9,] 3.1 -0.2 0.8 -1.0 0.6 NA [10,] 3.3 0.7 1.2 -2.3 0.5 NA [11,] 2.4 1.0 -1.4 -1.0 1.0 NA [12,] -1.4 1.4 -0.2 1.4 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/1o3pu1258132004.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/2lxib1258132004.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/36wf71258132004.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/4rnbg1258132004.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,] 15.2 16.0 17.6 15.0 15.0 16.3 19.4 18.2 18.1 12.5 14.8 13.8 [2,] 15.2 16.0 17.6 15.0 15.0 16.3 19.4 18.2 18.1 17.1 15.8 18.2 [3,] 16.8 17.3 19.3 17.9 20.2 18.7 19.9 19.6 18.4 18.2 18.9 19.9 [4,] 21.3 20.0 19.5 19.6 20.9 21.0 20.1 20.7 20.5 21.1 21.6 21.5 [5,] 21.3 23.5 21.6 24.5 22.2 23.5 20.9 21.3 20.9 21.7 22.9 22.6 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 12.48976 14.47361 17.95746 14.64965 16.03107 15.37899 19.40538 17.83351 [2,] 21.11024 20.12639 20.64254 21.15035 24.36893 22.02101 20.39462 21.36649 [,9] [,10] [,11] [,12] [1,] 16.70417 15.37361 14.80173 17.56823 [2,] 20.09583 21.02639 22.99827 22.23177 $out [1] 3.2 1.9 0.0 0.6 0.2 0.9 2.4 4.7 9.4 $group [1] 1 2 3 4 5 6 7 8 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(15.2, 15.2, 16.8, 21.3, 21.3, 16, 16, 17.3, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/59fvk1258132004.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.9 -2.6 -2.3 -1.5 -2.6 -1.9 -2.6 -1.0 0.5 -1.4 -1.4 [2,] -1.3 -1.9 -1.4 -0.4 0.1 -1.1 -0.3 -0.8 -0.2 0.5 -1.0 -0.8 [3,] 0.5 -0.5 0.1 0.0 0.7 1.4 -0.2 0.2 0.6 0.7 1.0 0.6 [4,] 0.8 1.6 0.6 1.3 1.3 1.5 1.9 1.3 0.8 1.2 1.0 1.4 [5,] 2.2 2.0 2.9 2.3 1.3 3.1 2.3 1.3 0.8 1.2 2.4 1.4 $n [1] 5 5 5 5 5 5 5 5 5 5 5 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.9838547 -2.973091 -1.313195 -1.201216 -0.1479170 -0.4371535 -1.754514 [2,] 1.9838547 1.973091 1.513195 1.201216 1.5479170 3.2371535 1.354514 [,8] [,9] [,10] [,11] [,12] [1,] -1.283855 -0.1065975 0.2053818 -0.413195 -1.138 [2,] 1.683855 1.3065975 1.1946182 2.413195 2.338 $out [1] 4.7 3.1 3.3 -2.3 $group [1] 8 9 10 10 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-1.3, -1.3, 0.5, 0.8, 2.2, -1.9, -1.9, -0.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6qm1i1258132004.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,] 0.00 16.80 19.50 13.80 15.0 NA [2,] 0.75 18.05 19.75 17.60 15.6 NA [3,] 2.80 18.55 20.90 21.10 18.5 NA [4,] 10.95 19.60 21.40 22.85 21.2 NA [5,] 18.20 20.20 22.90 24.50 22.6 NA $n [1] 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] -1.852288 17.84303 20.14742 18.70544 15.94580 NA [2,] 7.452288 19.25697 21.65258 23.49456 21.05420 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(0, 0.75, 2.8, 10.95, 18.2, 16.8, 18.05, 18.55, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7xzgv1258132004.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,] 15.52 16.80 17.300 [2,] 15.65 18.05 18.125 [3,] 16.31 18.80 18.675 [4,] 17.79 19.75 19.375 [5,] 19.20 20.20 19.850 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 15.33393 18.02462 18.10487 [2,] 17.28607 19.57538 19.24513 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(15.52, 15.65, 16.31, 17.79, 19.2, 16.8, 18.05, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > system("convert tmp/1o3pu1258132004.ps tmp/1o3pu1258132004.png") > system("convert tmp/2lxib1258132004.ps tmp/2lxib1258132004.png") > system("convert tmp/36wf71258132004.ps tmp/36wf71258132004.png") > system("convert tmp/4rnbg1258132004.ps tmp/4rnbg1258132004.png") > system("convert tmp/59fvk1258132004.ps tmp/59fvk1258132004.png") > system("convert tmp/6qm1i1258132004.ps tmp/6qm1i1258132004.png") > system("convert tmp/7xzgv1258132004.ps tmp/7xzgv1258132004.png") > > > proc.time() user system elapsed 1.220 0.951 1.487