R version 2.6.2 (2008-02-08) 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(58.1,57.9,57.3,55.9,55,55.9,56.6,57.3,56.2,57.7,56.8,57.9,58.3,58.2,56.9,57.1,56.7,54.2,54.2,52.1,51.5,51.8,53,52.4,52.41,52.36,52.94,52.34,51.84,51.42,50.85,50.66,51.53,51.59,52.32,51.98,51.17,50.57,49.84,50.12,49.08,48.57,47.22,46.78,46.04,45.05,44.42,44.09,44.46,44.34,43.04,42.87,42.32,42.49,41.94,41.6,41.42,41.12,41.28,40.21,39.69,39.16,38.8,38.44,37.02,36.75,35.95,36.29,36.35,36.07,36.6,36.5) > 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,] 58.1 58.3 52.41 51.17 44.46 39.69 NA [2,] 57.9 58.2 52.36 50.57 44.34 39.16 NA [3,] 57.3 56.9 52.94 49.84 43.04 38.80 NA [4,] 55.9 57.1 52.34 50.12 42.87 38.44 NA [5,] 55.0 56.7 51.84 49.08 42.32 37.02 NA [6,] 55.9 54.2 51.42 48.57 42.49 36.75 NA [7,] 56.6 54.2 50.85 47.22 41.94 35.95 NA [8,] 57.3 52.1 50.66 46.78 41.60 36.29 NA [9,] 56.2 51.5 51.53 46.04 41.42 36.35 NA [10,] 57.7 51.8 51.59 45.05 41.12 36.07 NA [11,] 56.8 53.0 52.32 44.42 41.28 36.60 NA [12,] 57.9 52.4 51.98 44.09 40.21 36.50 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.2 -0.10 -0.05 -0.60 -0.12 -0.53 NA [2,] -0.6 -1.30 0.58 -0.73 -1.30 -0.36 NA [3,] -1.4 0.20 -0.60 0.28 -0.17 -0.36 NA [4,] -0.9 -0.40 -0.50 -1.04 -0.55 -1.42 NA [5,] 0.9 -2.50 -0.42 -0.51 0.17 -0.27 NA [6,] 0.7 0.00 -0.57 -1.35 -0.55 -0.80 NA [7,] 0.7 -2.10 -0.19 -0.44 -0.34 0.34 NA [8,] -1.1 -0.60 0.87 -0.74 -0.18 0.06 NA [9,] 1.5 0.30 0.06 -0.99 -0.30 -0.28 NA [10,] -0.9 1.20 0.73 -0.63 0.16 0.53 NA [11,] 1.1 -0.60 -0.34 -0.33 -1.07 -0.10 NA [12,] 0.4 0.01 -0.81 0.37 -0.52 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/1x2js1208893338.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/2vmmm1208893338.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/31qq61208893338.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/4u5tw1208893338.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] [1,] 39.69 39.160 38.80 38.44 37.02 36.750 35.950 36.29 36.35 36.07 36.60 [2,] 44.46 44.340 43.04 42.87 42.32 42.490 41.940 41.60 41.42 41.12 41.28 [3,] 51.79 51.465 51.39 51.23 50.46 49.995 49.035 48.72 48.77 48.32 48.37 [4,] 58.10 57.900 56.90 55.90 55.00 54.200 54.200 52.10 51.53 51.80 53.00 [5,] 58.30 58.200 57.30 57.10 56.70 55.900 56.600 57.30 56.20 57.70 56.80 [,12] [1,] 36.500 [2,] 40.210 [3,] 48.035 [4,] 52.400 [5,] 57.900 $n [1] 6 6 6 6 6 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 42.99176 42.71836 42.44985 42.82523 42.28099 42.44167 41.1269 41.94716 [2,] 60.58824 60.21164 60.33015 59.63477 58.63901 57.54833 56.9431 55.49284 [,9] [,10] [,11] [,12] [1,] 42.24872 41.43106 40.81022 40.17206 [2,] 55.29128 55.20894 55.92978 55.89794 $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(39.69, 44.46, 51.79, 58.1, 58.3, 39.16, 44.34, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5f1ez1208893338.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] [1,] -0.60 -1.300 -1.400 -1.420 -0.510 -1.35 -0.440 -1.10 -0.99 -0.900 -1.070 [2,] -0.53 -1.300 -0.600 -1.040 -0.510 -0.80 -0.440 -0.74 -0.30 -0.630 -0.600 [3,] -0.16 -0.665 -0.265 -0.725 -0.345 -0.56 -0.265 -0.39 -0.11 0.345 -0.335 [4,] -0.10 -0.360 0.200 -0.500 0.170 0.00 0.340 0.06 0.30 0.730 -0.100 [5,] -0.05 0.580 0.280 -0.400 0.900 0.70 0.700 0.87 0.30 1.200 -0.100 [,12] [1,] -0.81 [2,] -0.52 [3,] 0.01 [4,] 0.37 [5,] 0.40 $n [1] 6 6 6 6 6 6 6 6 6 6 6 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] -0.4373639 -1.27133036 -0.7810258 -1.0733174 -0.78362196 -1.07602584 [2,] 0.1173639 -0.05866964 0.2510258 -0.3766826 0.09362196 -0.04397416 [,7] [,8] [,9] [,10] [,11] [,12] [1,] -0.7681252 -0.9060258 -0.4970194 -0.5322439 -0.65751615 -0.6188718 [2,] 0.2381252 0.1260258 0.2770194 1.2222439 -0.01248385 0.6388718 $out [1] -2.5 -2.1 1.5 1.1 $group [1] 5 7 9 11 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-0.600000000000001, -0.530000000000001, -0.16, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6iymk1208893338.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,] 55.00 51.50 50.660 44.090 40.210 35.950 NA [2,] 56.05 52.25 51.475 45.545 41.350 36.320 NA [3,] 57.05 54.20 51.910 47.895 42.130 36.675 NA [4,] 57.80 57.00 52.350 49.980 42.955 38.620 NA [5,] 58.10 58.30 52.940 51.170 44.460 39.690 NA $n [1] 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 56.25181 52.03349 51.51091 45.87217 41.39795 35.62595 NA [2,] 57.84819 56.36651 52.30909 49.91783 42.86205 37.72405 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(55, 56.05, 57.05, 57.8, 58.1, 51.5, 52.25, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7fm331208893338.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,] 47.17333 48.035 46.73750 [2,] 47.31250 48.545 47.18313 [3,] 48.00750 49.515 48.53438 [4,] 49.63250 51.310 50.08563 [5,] 50.68833 51.790 51.40750 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 46.94933 48.25386 47.21053 [2,] 49.06567 50.77614 49.85822 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(47.1733333333333, 47.3125, 48.0075, 49.6325, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1x2js1208893338.ps tmp/1x2js1208893338.png") > system("convert tmp/2vmmm1208893338.ps tmp/2vmmm1208893338.png") > system("convert tmp/31qq61208893338.ps tmp/31qq61208893338.png") > system("convert tmp/4u5tw1208893338.ps tmp/4u5tw1208893338.png") > system("convert tmp/5f1ez1208893338.ps tmp/5f1ez1208893338.png") > system("convert tmp/6iymk1208893338.ps tmp/6iymk1208893338.png") > system("convert tmp/7fm331208893338.ps tmp/7fm331208893338.png") > > > proc.time() user system elapsed 1.428 0.956 1.727