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. 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(110.5,110.8,104.2,88.9,89.8,90,93.9,91.3,87.8,99.7,73.5,79.2,96.9,95.2,95.6,89.7,92.8,88,101.1,92.7,95.8,103.8,81.8,87.1,105.9,108.1,102.6,93.7,103.5,100.6,113.3,102.4,102.1,106.9,87.3,93.1,109.1,120.3,104.9,92.6,109.8,111.4,117.9,121.6,117.8,124.2,106.8,102.7,116.8,113.6,96.1,85,83.2,84.9,83,79.6,83.2,83.8,82.8,71.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] 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,] 110.5 96.9 105.9 109.1 116.8 NA [2,] 110.8 95.2 108.1 120.3 113.6 NA [3,] 104.2 95.6 102.6 104.9 96.1 NA [4,] 88.9 89.7 93.7 92.6 85.0 NA [5,] 89.8 92.8 103.5 109.8 83.2 NA [6,] 90.0 88.0 100.6 111.4 84.9 NA [7,] 93.9 101.1 113.3 117.9 83.0 NA [8,] 91.3 92.7 102.4 121.6 79.6 NA [9,] 87.8 95.8 102.1 117.8 83.2 NA [10,] 99.7 103.8 106.9 124.2 83.8 NA [11,] 73.5 81.8 87.3 106.8 82.8 NA [12,] 79.2 87.1 93.1 102.7 71.4 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 0.3 -1.7 2.2 11.2 -3.2 NA [2,] -6.6 0.4 -5.5 -15.4 -17.5 NA [3,] -15.3 -5.9 -8.9 -12.3 -11.1 NA [4,] 0.9 3.1 9.8 17.2 -1.8 NA [5,] 0.2 -4.8 -2.9 1.6 1.7 NA [6,] 3.9 13.1 12.7 6.5 -1.9 NA [7,] -2.6 -8.4 -10.9 3.7 -3.4 NA [8,] -3.5 3.1 -0.3 -3.8 3.6 NA [9,] 11.9 8.0 4.8 6.4 0.6 NA [10,] -26.2 -22.0 -19.6 -17.4 -1.0 NA [11,] 5.7 5.3 5.8 -4.1 -11.4 NA [12,] 17.7 18.8 16.0 14.1 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/freestat/rcomp/tmp/1s8l21257880832.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/freestat/rcomp/tmp/2h7181257880832.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/freestat/rcomp/tmp/33vd11257880832.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/freestat/rcomp/tmp/4vk8o1257880832.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,] 105.9 108.1 95.6 85.0 83.2 84.9 83.0 79.6 83.2 99.7 81.8 71.4 [2,] 105.9 108.1 96.1 88.9 89.8 88.0 93.9 91.3 87.8 99.7 81.8 79.2 [3,] 109.1 110.8 102.6 89.7 92.8 90.0 101.1 92.7 95.8 103.8 82.8 87.1 [4,] 110.5 113.6 104.2 92.6 103.5 100.6 113.3 102.4 102.1 106.9 87.3 93.1 [5,] 116.8 120.3 104.9 93.7 109.8 111.4 117.9 102.4 117.8 106.9 87.3 102.7 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 105.8497 106.9137 96.87656 87.08559 83.11961 81.09687 87.39201 [2,] 112.3503 114.6863 108.32344 92.31441 102.48039 98.90313 114.80799 [,8] [,9] [,10] [,11] [,12] [1,] 84.85677 85.69566 98.7125 78.91371 77.2783 [2,] 100.54323 105.90434 108.8875 86.68629 96.9217 $out [1] 96.9 95.2 121.6 124.2 83.8 73.5 106.8 $group [1] 1 2 8 10 10 11 11 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(105.9, 105.9, 109.1, 110.5, 116.8, 108.1, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/58cmx1257880832.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,] -3.2 -17.5 -15.3 -1.8 -4.8 -1.9 -10.9 -3.8 0.6 -26.2 -11.4 14.10 [2,] -1.7 -15.4 -12.3 0.9 -2.9 3.9 -8.4 -3.5 4.8 -22.0 -4.1 15.05 [3,] 0.3 -6.6 -11.1 3.1 0.2 6.5 -3.4 -0.3 6.4 -19.6 5.3 16.85 [4,] 2.2 -5.5 -8.9 9.8 1.6 12.7 -2.6 3.1 8.0 -17.4 5.7 18.25 [5,] 2.2 0.4 -5.9 17.2 1.7 13.1 3.7 3.6 11.9 -17.4 5.8 18.80 $n [1] 5 5 5 5 5 5 5 5 5 5 5 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -2.45573 -13.5953151 -13.502431 -3.188718 -2.979689 0.2819422 -7.4982654 [2,] 3.05573 0.3953151 -8.697569 9.388718 3.379689 12.7180578 0.6982654 [,8] [,9] [,10] [,11] [,12] [1,] -4.963543 4.138888 -22.85035 -1.624655 14.322 [2,] 4.363543 8.661112 -16.34965 12.224655 19.378 $out [1] 11.2 -1.0 $group [1] 1 10 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-3.2, -1.70000000000000, 0.299999999999997, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/6ydw01257880832.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,] 73.50 81.80 87.30 92.60 79.60 NA [2,] 88.35 88.85 97.15 105.85 82.90 NA [3,] 90.65 94.00 102.50 110.60 83.50 NA [4,] 101.95 96.35 106.40 119.10 90.55 NA [5,] 110.80 103.80 113.30 124.20 96.10 NA $n [1] 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 84.44695 90.5792 98.28101 104.5566 80.01078 NA [2,] 96.85305 97.4208 106.71899 116.6434 86.98922 NA $out [1] 116.8 113.6 71.4 $group [1] 5 5 5 $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(73.5, 88.35, 90.65, 101.95, 110.8, 81.8, 88.85, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/7b7au1257880832.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,] 86.44 82.80 84.550 [2,] 92.48 89.85 92.525 [3,] 97.43 94.30 96.750 [4,] 102.76 103.20 103.450 [5,] 109.60 110.80 110.850 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 92.74122 88.21098 91.76703 [2,] 102.11878 100.38902 101.73297 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(86.44, 92.48, 97.43, 102.76, 109.6, 82.8, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1s8l21257880832.ps tmp/1s8l21257880832.png") > system("convert tmp/2h7181257880832.ps tmp/2h7181257880832.png") > system("convert tmp/33vd11257880832.ps tmp/33vd11257880832.png") > system("convert tmp/4vk8o1257880832.ps tmp/4vk8o1257880832.png") > system("convert tmp/58cmx1257880832.ps tmp/58cmx1257880832.png") > system("convert tmp/6ydw01257880832.ps tmp/6ydw01257880832.png") > system("convert tmp/7b7au1257880832.ps tmp/7b7au1257880832.png") > > > proc.time() user system elapsed 1.906 1.506 2.207