R version 2.11.1 (2010-05-31) Copyright (C) 2010 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(108,106.6,122.2,115.8,115.6,124.5,121.7,118.7,113.7,113.4,115.1,143.9,101,103.4,121.5,111.9,117.4,124.3,122,119.7,115,112.2,115.3,142.6,104.1,105.3,124.4,113.9,124.8,131.8,125.6,125,119.7,116.1,120,148.1,109.2,109.4,135.1,114.9,129,138.5,125.6,130.4,120.3,126.2,127.6,150.9,114.6,118.6,131.4,124.5,136.8,136.8,136.6,131,125.8,129.4,124.8,157.1,116.6,114.2,128.4,127.3,133.5,137.2,137.7,131.2,127.7,133.9,124.3,160.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] 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,] 108.0 101.0 104.1 109.2 114.6 116.6 NA [2,] 106.6 103.4 105.3 109.4 118.6 114.2 NA [3,] 122.2 121.5 124.4 135.1 131.4 128.4 NA [4,] 115.8 111.9 113.9 114.9 124.5 127.3 NA [5,] 115.6 117.4 124.8 129.0 136.8 133.5 NA [6,] 124.5 124.3 131.8 138.5 136.8 137.2 NA [7,] 121.7 122.0 125.6 125.6 136.6 137.7 NA [8,] 118.7 119.7 125.0 130.4 131.0 131.2 NA [9,] 113.7 115.0 119.7 120.3 125.8 127.7 NA [10,] 113.4 112.2 116.1 126.2 129.4 133.9 NA [11,] 115.1 115.3 120.0 127.6 124.8 124.3 NA [12,] 143.9 142.6 148.1 150.9 157.1 160.6 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -1.4 2.4 1.2 0.2 4.0 -2.4 NA [2,] 15.6 18.1 19.1 25.7 12.8 14.2 NA [3,] -6.4 -9.6 -10.5 -20.2 -6.9 -1.1 NA [4,] -0.2 5.5 10.9 14.1 12.3 6.2 NA [5,] 8.9 6.9 7.0 9.5 0.0 3.7 NA [6,] -2.8 -2.3 -6.2 -12.9 -0.2 0.5 NA [7,] -3.0 -2.3 -0.6 4.8 -5.6 -6.5 NA [8,] -5.0 -4.7 -5.3 -10.1 -5.2 -3.5 NA [9,] -0.3 -2.8 -3.6 5.9 3.6 6.2 NA [10,] 1.7 3.1 3.9 1.4 -4.6 -9.6 NA [11,] 28.8 27.3 28.1 23.3 32.3 36.3 NA [12,] -42.9 -38.5 -38.9 -36.3 -40.5 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/rcomp/tmp/1tw7s1287747228.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/rcomp/tmp/2tw7s1287747228.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/rcomp/tmp/3457v1287747228.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/rcomp/tmp/4457v1287747228.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,] 101.0 103.4 121.5 111.90 115.6 124.3 121.7 118.7 113.7 112.20 115.10 142.6 [2,] 104.1 105.3 122.2 113.90 117.4 124.5 122.0 119.7 115.0 113.40 115.30 143.9 [3,] 108.6 108.0 126.4 115.35 126.9 134.3 125.6 127.7 120.0 121.15 122.15 149.5 [4,] 114.6 114.2 131.4 124.50 133.5 137.2 136.6 131.0 125.8 129.40 124.80 157.1 [5,] 116.6 118.6 135.1 127.30 136.8 138.5 137.7 131.2 127.7 133.90 127.60 160.6 $n [1] 6 6 6 6 6 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 101.8272 102.2592 120.4657 108.5127 116.5150 126.1081 116.1825 120.4111 [2,] 115.3728 113.7408 132.3343 122.1873 137.2850 142.4919 135.0175 134.9889 [,9] [,10] [,11] [,12] [1,] 113.0337 110.8295 116.0222 140.9856 [2,] 126.9663 131.4705 128.2778 158.0144 $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(101, 104.1, 108.6, 114.6, 116.6, 103.4, 105.3, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/5457v1287747228.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,] -2.4 12.80 -10.50 -0.20 0.00 -12.90 -6.50 -5.3 -3.60 -9.60 23.30 -42.9 [2,] -1.4 14.20 -10.50 5.50 3.70 -6.20 -5.60 -5.3 -2.80 -4.60 27.30 -40.5 [3,] 0.7 16.85 -8.25 8.55 6.95 -2.55 -2.65 -5.1 1.65 1.55 28.45 -38.9 [4,] 2.4 19.10 -6.40 12.30 8.90 -0.20 -0.60 -4.7 5.90 3.10 32.30 -38.5 [5,] 4.0 25.70 -1.10 14.10 9.50 0.50 4.80 -4.7 6.20 3.90 36.30 -36.3 $n [1] 6 6 6 6 6 6 6 6 6 6 6 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -1.751123 13.68934 -10.894632 4.16378 3.595832 -6.420194 -5.8751615 [2,] 3.151123 20.01066 -5.605368 12.93622 10.304168 1.320194 0.5751615 [,8] [,9] [,10] [,11] [,12] [1,] -5.487019 -3.961781 -3.416749 25.22484 -40.31319 [2,] -4.712981 7.261781 6.516749 31.67516 -37.48681 $out [1] -20.2 -10.1 -3.5 $group [1] 3 8 8 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-2.39999999999999, -1.40000000000001, 0.700000000000003, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/6ee6f1287747228.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,] 106.60 101.00 104.1 109.20 114.60 114.20 NA [2,] 113.55 112.05 115.0 117.60 124.65 125.80 NA [3,] 115.70 116.35 122.2 126.90 130.20 129.80 NA [4,] 121.95 121.75 125.3 132.75 136.70 135.55 NA [5,] 124.50 124.30 131.8 150.90 136.80 137.70 NA $n [1] 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 111.8687 111.9258 117.5021 119.9900 124.7039 125.3530 NA [2,] 119.5313 120.7742 126.8979 133.8100 135.6961 134.2470 NA $out [1] 143.9 142.6 148.1 157.1 160.6 $group [1] 1 2 3 5 6 $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(106.6, 113.55, 115.7, 121.95, 124.5, 101, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/7ee6f1287747228.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,] 108.9167 108.000 109.1625 [2,] 119.2083 117.675 119.2688 [3,] 123.9333 123.875 123.5750 [4,] 127.6833 127.300 127.5375 [5,] 132.1833 134.300 131.7125 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 120.0678 119.4850 119.8036 [2,] 127.7988 128.2650 127.3464 $out [1] 150.5333 149.5000 150.2500 $group [1] 1 2 3 $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(108.916666666667, 119.208333333333, 123.933333333333, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1tw7s1287747228.ps tmp/1tw7s1287747228.png",intern=TRUE)) character(0) > try(system("convert tmp/2tw7s1287747228.ps tmp/2tw7s1287747228.png",intern=TRUE)) character(0) > try(system("convert tmp/3457v1287747228.ps tmp/3457v1287747228.png",intern=TRUE)) character(0) > try(system("convert tmp/4457v1287747228.ps tmp/4457v1287747228.png",intern=TRUE)) character(0) > try(system("convert tmp/5457v1287747228.ps tmp/5457v1287747228.png",intern=TRUE)) character(0) > try(system("convert tmp/6ee6f1287747228.ps tmp/6ee6f1287747228.png",intern=TRUE)) character(0) > try(system("convert tmp/7ee6f1287747228.ps tmp/7ee6f1287747228.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.95 1.38 3.27