R version 2.15.2 (2012-10-26) -- "Trick or Treat" Copyright (C) 2012 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i686-pc-linux-gnu (32-bit) 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(7.66,7.53,7.54,7.56,7.57,7.56,7.57,7.61,7.61,7.6,7.61,7.61,7.62,7.7,7.73,7.75,7.76,7.76,7.77,7.79,7.79,7.79,7.83,7.83,7.88,7.95,8.01,8.05,8.1,8.1,8.16,8.18,8.2,7.99,8.01,8.02,8.03,8.04,8.07,8.08,8.08,8.1,8.11,8.15,8.16,8.17,8.18,8.15,8.15,8.17,8.16,8.15,8.16,8.15,8.18,8.19,8.18,8.2,8.21,8.22,8.23,8.25,8.28,8.28,8.29,8.3,8.34,8.38,8.39,8.44,8.46,8.46) > par1 = '18' > par1 <- '12' > 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,] 7.66 7.62 7.88 8.03 8.15 8.23 NA [2,] 7.53 7.70 7.95 8.04 8.17 8.25 NA [3,] 7.54 7.73 8.01 8.07 8.16 8.28 NA [4,] 7.56 7.75 8.05 8.08 8.15 8.28 NA [5,] 7.57 7.76 8.10 8.08 8.16 8.29 NA [6,] 7.56 7.76 8.10 8.10 8.15 8.30 NA [7,] 7.57 7.77 8.16 8.11 8.18 8.34 NA [8,] 7.61 7.79 8.18 8.15 8.19 8.38 NA [9,] 7.61 7.79 8.20 8.16 8.18 8.39 NA [10,] 7.60 7.79 7.99 8.17 8.20 8.44 NA [11,] 7.61 7.83 8.01 8.18 8.21 8.46 NA [12,] 7.61 7.83 8.02 8.15 8.22 8.46 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.13 0.08 0.07 0.01 0.02 0.02 NA [2,] 0.01 0.03 0.06 0.03 -0.01 0.03 NA [3,] 0.02 0.02 0.04 0.01 -0.01 0.00 NA [4,] 0.01 0.01 0.05 0.00 0.01 0.01 NA [5,] -0.01 0.00 0.00 0.02 -0.01 0.01 NA [6,] 0.01 0.01 0.06 0.01 0.03 0.04 NA [7,] 0.04 0.02 0.02 0.04 0.01 0.04 NA [8,] 0.00 0.00 0.02 0.01 -0.01 0.01 NA [9,] -0.01 0.00 -0.21 0.01 0.02 0.05 NA [10,] 0.01 0.04 0.02 0.01 0.01 0.02 NA [11,] 0.00 0.00 0.01 -0.03 0.01 0.00 NA [12,] 0.01 0.05 0.01 0.00 0.01 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/wessaorg/rcomp/tmp/1yj611357130259.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/wessaorg/rcomp/tmp/28kn11357130259.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/wessaorg/rcomp/tmp/3aob51357130259.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/wessaorg/rcomp/tmp/4grqm1357130259.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,] 7.620 7.530 7.54 7.560 7.57 7.56 7.570 7.610 7.61 7.60 7.610 7.610 [2,] 7.660 7.700 7.73 7.750 7.76 7.76 7.770 7.790 7.79 7.79 7.830 7.830 [3,] 7.955 7.995 8.04 8.065 8.09 8.10 8.135 8.165 8.17 8.08 8.095 8.085 [4,] 8.150 8.170 8.16 8.150 8.16 8.15 8.180 8.190 8.20 8.20 8.210 8.220 [5,] 8.230 8.250 8.28 8.280 8.29 8.30 8.340 8.380 8.39 8.44 8.460 8.460 $n [1] 6 6 6 6 6 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 7.638934 7.691835 7.762636 7.806987 7.831987 7.848437 7.870537 7.906987 [2,] 8.271066 8.298165 8.317364 8.323013 8.348013 8.351563 8.399463 8.423013 [,9] [,10] [,11] [,12] [1,] 7.905537 7.815537 7.849888 7.833437 [2,] 8.434463 8.344463 8.340112 8.336563 $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(7.62, 7.66, 7.955, 8.15, 8.23, 7.53, 7.7, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/5m9pn1357130259.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,] 0.01 -0.01 -0.010 0.01 -0.01 0.01 0.01 -0.010 -0.010 0.010 0.00 0.01 [2,] 0.01 0.01 0.000 0.01 -0.01 0.01 0.02 0.000 -0.010 0.010 0.00 0.01 [3,] 0.02 0.03 0.015 0.01 0.00 0.02 0.03 0.005 0.005 0.015 0.00 0.01 [4,] 0.07 0.03 0.020 0.01 0.01 0.04 0.04 0.010 0.020 0.020 0.01 0.01 [5,] 0.08 0.06 0.040 0.01 0.02 0.06 0.04 0.020 0.050 0.020 0.01 0.01 $n [1] 6 6 6 6 6 6 6 6 6 6 6 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.01870194 0.01709935 0.002099354 0.01 -0.01290065 0.000649031 0.01709935 [2,] 0.05870194 0.04290065 0.027900646 0.01 0.01290065 0.039350969 0.04290065 [,8] [,9] [,10] [,11] [,12] [1,] -0.001450323 -0.01435097 0.008549677 -0.006450323 0.01 [2,] 0.011450323 0.02435097 0.021450323 0.006450323 0.01 $out [1] -0.13 0.05 0.00 -0.21 0.04 -0.03 0.05 0.00 $group [1] 1 4 4 9 10 11 12 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(0.00999999999999979, 0.00999999999999979, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/605kj1357130259.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] [1,] 7.530 7.700 7.880 8.030 8.150 8.230 NA [2,] 7.560 7.740 8.000 8.075 8.155 8.280 NA [3,] 7.585 7.765 8.035 8.105 8.175 8.320 NA [4,] 7.610 7.790 8.130 8.155 8.195 8.415 NA [5,] 7.660 7.830 8.200 8.180 8.220 8.460 NA $n [1] 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 7.562195 7.742195 7.975706 8.068511 8.156756 8.258426 NA [2,] 7.607805 7.787805 8.094294 8.141489 8.193244 8.381574 NA $out [1] 7.62 $group [1] 2 $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(7.53, 7.56, 7.585, 7.61, 7.66, 7.7, 7.74, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/7psrv1357130259.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,] 7.928333 7.9950 7.91750 [2,] 7.971667 8.0525 7.97375 [3,] 8.008333 8.0875 8.00375 [4,] 8.049167 8.1175 8.03625 [5,] 8.055000 8.1700 8.04000 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 7.972985 8.057853 7.975243 [2,] 8.043682 8.117147 8.032257 $out [1] 7.955 $group [1] 2 $names [1] "mean" "median" "midrange" > dev.off() null device 1 > > try(system("convert tmp/1yj611357130259.ps tmp/1yj611357130259.png",intern=TRUE)) character(0) > try(system("convert tmp/28kn11357130259.ps tmp/28kn11357130259.png",intern=TRUE)) character(0) > try(system("convert tmp/3aob51357130259.ps tmp/3aob51357130259.png",intern=TRUE)) character(0) > try(system("convert tmp/4grqm1357130259.ps tmp/4grqm1357130259.png",intern=TRUE)) character(0) > try(system("convert tmp/5m9pn1357130259.ps tmp/5m9pn1357130259.png",intern=TRUE)) character(0) > try(system("convert tmp/605kj1357130259.ps tmp/605kj1357130259.png",intern=TRUE)) character(0) > try(system("convert tmp/7psrv1357130259.ps tmp/7psrv1357130259.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 3.558 0.489 4.108