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.81,3.95,3.99,4,4.06,4.16,4.19,4.2,4.2,4.2,4.2,4.2,4.23,4.38,4.43,4.44,4.44,4.44,4.44,4.44,4.45,4.45,4.45,4.45,4.45,4.45,4.45,4.45,4.46,4.46,4.46,4.48,4.58,4.67,4.68,4.68,4.69,4.69,4.69,4.69,4.69,4.69,4.69,4.73,4.78,4.79,4.79,4.8,4.8,4.81,5.16,5.26,5.29,5.29,5.29,5.3,5.3,5.3,5.3,5.3,5.3,5.3,5.3,5.35,5.44,5.47,5.47,5.48,5.48,5.48,5.48,5.48) > 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] 72 > (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] 6 6 6 6 6 6 6 6 6 6 6 6 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 3.81 4.23 4.45 4.69 4.80 5.30 NA [2,] 3.95 4.38 4.45 4.69 4.81 5.30 NA [3,] 3.99 4.43 4.45 4.69 5.16 5.30 NA [4,] 4.00 4.44 4.45 4.69 5.26 5.35 NA [5,] 4.06 4.44 4.46 4.69 5.29 5.44 NA [6,] 4.16 4.44 4.46 4.69 5.29 5.47 NA [7,] 4.19 4.44 4.46 4.69 5.29 5.47 NA [8,] 4.20 4.44 4.48 4.73 5.30 5.48 NA [9,] 4.20 4.45 4.58 4.78 5.30 5.48 NA [10,] 4.20 4.45 4.67 4.79 5.30 5.48 NA [11,] 4.20 4.45 4.68 4.79 5.30 5.48 NA [12,] 4.20 4.45 4.68 4.80 5.30 5.48 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 0.14 0.15 0.00 0.00 0.01 0.00 NA [2,] 0.04 0.05 0.00 0.00 0.35 0.00 NA [3,] 0.01 0.01 0.00 0.00 0.10 0.05 NA [4,] 0.06 0.00 0.01 0.00 0.03 0.09 NA [5,] 0.10 0.00 0.00 0.00 0.00 0.03 NA [6,] 0.03 0.00 0.00 0.00 0.00 0.00 NA [7,] 0.01 0.00 0.02 0.04 0.01 0.01 NA [8,] 0.00 0.01 0.10 0.05 0.00 0.00 NA [9,] 0.00 0.00 0.09 0.01 0.00 0.00 NA [10,] 0.00 0.00 0.01 0.00 0.00 0.00 NA [11,] 0.00 0.00 0.00 0.01 0.00 0.00 NA [12,] 0.03 0.00 0.01 0.00 0.00 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/1rofv1259766252.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/2lec61259766252.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/3b6u81259766252.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/4uc651259766252.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,] 3.81 3.95 3.99 4.00 4.060 4.160 4.190 4.200 4.20 4.20 4.200 4.20 [2,] 4.23 4.38 4.43 4.44 4.440 4.440 4.440 4.440 4.45 4.45 4.450 4.45 [3,] 4.57 4.57 4.57 4.57 4.575 4.575 4.575 4.605 4.68 4.73 4.735 4.74 [4,] 4.80 4.81 5.16 5.26 5.290 5.290 5.290 5.300 5.30 5.30 5.300 5.30 [5,] 5.30 5.30 5.30 5.35 5.440 5.470 5.470 5.480 5.48 5.48 5.480 5.48 $n [1] 6 6 6 6 6 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 4.202332 4.292636 4.099126 4.041074 4.026723 4.026723 4.026723 4.050272 [2,] 4.937668 4.847364 5.040874 5.098926 5.123277 5.123277 5.123277 5.159728 [,9] [,10] [,11] [,12] [1,] 4.131723 4.181723 4.186723 4.191723 [2,] 5.228277 5.278277 5.283277 5.288277 $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(3.81, 4.23, 4.57, 4.8, 5.3, 3.95, 4.38, 4.57, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5m4af1259766252.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,] 0.000 0.00 0.00 0.00 0.00 0 0.00 0.000 0.00 0 0 0.00 [2,] 0.000 0.00 0.00 0.00 0.00 0 0.01 0.000 0.00 0 0 0.00 [3,] 0.005 0.02 0.01 0.02 0.00 0 0.01 0.005 0.00 0 0 0.00 [4,] 0.140 0.05 0.05 0.06 0.03 0 0.02 0.050 0.01 0 0 0.01 [5,] 0.150 0.05 0.10 0.09 0.03 0 0.02 0.100 0.01 0 0 0.01 $n [1] 6 6 6 6 6 6 6 6 6 6 6 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] -0.08530452 -0.01225161 -0.02225161 -0.01870194 -0.01935097 0 [2,] 0.09530452 0.05225161 0.04225161 0.05870194 0.01935097 0 [,7] [,8] [,9] [,10] [,11] [,12] [1,] 0.003549677 -0.02725161 -0.006450323 0 0 -0.007065975 [2,] 0.016450323 0.03725161 0.006450323 0 0 0.007065975 $out [1] 0.35 0.10 0.03 0.04 0.09 0.01 0.01 0.03 $group [1] 2 5 6 7 9 10 11 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(0, 0, 0.00499999999999989, 0.14, 0.149999999999999, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6qrhm1259766252.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,] 3.810 4.430 4.450 4.690 5.16 5.300 NA [2,] 3.995 4.435 4.450 4.690 5.21 5.325 NA [3,] 4.175 4.440 4.460 4.690 5.29 5.470 NA [4,] 4.200 4.450 4.625 4.785 5.30 5.480 NA [5,] 4.200 4.450 4.680 4.800 5.30 5.480 NA $n [1] 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 4.081498 4.433158 4.380181 4.64667 5.24895 5.399303 NA [2,] 4.268502 4.446842 4.539819 4.73333 5.33105 5.540697 NA $out [1] 4.23 4.38 4.80 4.81 $group [1] 2 2 5 5 $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(3.81, 3.995, 4.175, 4.2, 4.2, 4.43, 4.435, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7lqxi1259766252.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,] 4.546667 4.570 4.738750 [2,] 4.684167 4.570 4.759375 [3,] 4.754167 4.575 4.792500 [4,] 4.806667 4.705 4.832500 [5,] 4.818333 4.740 4.841250 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 4.698294 4.513426 4.759147 [2,] 4.810040 4.636574 4.825853 $out [1] 4.52875 4.58875 $group [1] 3 3 $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(4.54666666666667, 4.68416666666667, 4.75416666666667, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1rofv1259766252.ps tmp/1rofv1259766252.png") > system("convert tmp/2lec61259766252.ps tmp/2lec61259766252.png") > system("convert tmp/3b6u81259766252.ps tmp/3b6u81259766252.png") > system("convert tmp/4uc651259766252.ps tmp/4uc651259766252.png") > system("convert tmp/5m4af1259766252.ps tmp/5m4af1259766252.png") > system("convert tmp/6qrhm1259766252.ps tmp/6qrhm1259766252.png") > system("convert tmp/7lqxi1259766252.ps tmp/7lqxi1259766252.png") > > > proc.time() user system elapsed 1.167 0.922 1.635