R version 2.12.0 (2010-10-15) Copyright (C) 2010 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i486-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(104.77,111.04,104.5,102.42,103.05,105.84,107.92,108.22,104.26,105.19,103.25,108.16,105.27,113.99,109.84,104.33,105.48,109.68,111.54,110.63,107.8,108.02,105.59,111.64,107,116.14,117.18,102.28,109.43,114.28,117.39,116.66,114.29,114.18,114.12,122.62,115.7,127.91,119.55,115.08,116.63,121.38,123.41,120.7,119.4,116.83,116.4,121.67,116.54,129.61,119.93,117.64,121.01,124.2,125.23,123.24,121.58,120.89,117.77,110.91) > 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,] 104.77 105.27 107.00 115.70 116.54 NA [2,] 111.04 113.99 116.14 127.91 129.61 NA [3,] 104.50 109.84 117.18 119.55 119.93 NA [4,] 102.42 104.33 102.28 115.08 117.64 NA [5,] 103.05 105.48 109.43 116.63 121.01 NA [6,] 105.84 109.68 114.28 121.38 124.20 NA [7,] 107.92 111.54 117.39 123.41 125.23 NA [8,] 108.22 110.63 116.66 120.70 123.24 NA [9,] 104.26 107.80 114.29 119.40 121.58 NA [10,] 105.19 108.02 114.18 116.83 120.89 NA [11,] 103.25 105.59 114.12 116.40 117.77 NA [12,] 108.16 111.64 122.62 121.67 110.91 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 6.27 8.72 9.14 12.21 13.07 NA [2,] -6.54 -4.15 1.04 -8.36 -9.68 NA [3,] -2.08 -5.51 -14.90 -4.47 -2.29 NA [4,] 0.63 1.15 7.15 1.55 3.37 NA [5,] 2.79 4.20 4.85 4.75 3.19 NA [6,] 2.08 1.86 3.11 2.03 1.03 NA [7,] 0.30 -0.91 -0.73 -2.71 -1.99 NA [8,] -3.96 -2.83 -2.37 -1.30 -1.66 NA [9,] 0.93 0.22 -0.11 -2.57 -0.69 NA [10,] -1.94 -2.43 -0.06 -0.43 -3.12 NA [11,] 4.91 6.05 8.50 5.27 -6.86 NA [12,] -2.89 -4.64 -6.92 -5.13 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/1438l1319286495.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/www/rcomp/tmp/2vyyd1319286495.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/www/rcomp/tmp/3774e1319286495.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/www/rcomp/tmp/4fx0m1319286495.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] [1,] 104.77 111.04 104.50 102.28 103.05 105.84 107.92 108.22 104.26 105.19 [2,] 105.27 113.99 109.84 102.42 105.48 109.68 111.54 110.63 107.80 108.02 [3,] 107.00 116.14 117.18 104.33 109.43 114.28 117.39 116.66 114.29 114.18 [4,] 115.70 127.91 119.55 115.08 116.63 121.38 123.41 120.70 119.40 116.83 [5,] 116.54 129.61 119.93 117.64 121.01 124.20 125.23 123.24 121.58 120.89 [,11] [,12] [1,] 103.25 108.16 [2,] 105.59 110.91 [3,] 114.12 111.64 [4,] 116.40 121.67 [5,] 117.77 122.62 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 99.63019 106.3042 110.3189 95.38448 101.5514 106.0128 109.0027 109.5446 [2,] 114.36981 125.9758 124.0411 113.27552 117.3086 122.5472 125.7773 123.7754 [,9] [,10] [,11] [,12] [1,] 106.0935 107.9549 106.4817 104.0370 [2,] 122.4865 120.4051 121.7583 119.2430 $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(104.77, 105.27, 107, 115.7, 116.54, 111.04, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/56ndy1319286495.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,] 6.27 -9.68 -5.51 0.63 2.79 1.86 -2.71 -3.96 -0.69 -3.12 4.91 -6.920 [2,] 8.72 -8.36 -5.51 1.15 3.19 1.86 -1.99 -2.83 -0.69 -2.43 4.91 -6.025 [3,] 9.14 -6.54 -4.47 1.55 4.20 2.03 -0.91 -2.37 -0.11 -1.94 5.27 -4.885 [4,] 12.21 -4.15 -2.29 3.37 4.75 2.08 -0.73 -1.66 0.22 -0.43 6.05 -3.765 [5,] 13.07 1.04 -2.08 3.37 4.85 2.08 0.30 -1.30 0.93 -0.06 6.05 -2.890 $n [1] 5 5 5 5 5 5 5 5 5 5 5 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 6.673975 -9.514775 -6.745244 -0.01864641 3.097708 1.874549 -1.80031283 [2,] 11.606025 -3.565225 -2.194756 3.11864641 5.302292 2.185451 -0.01968717 [,8] [,9] [,10] [,11] [,12] [1,] -3.196719 -0.7530037 -3.353195 4.464479 -6.6704 [2,] -1.543281 0.5330037 -0.526805 6.075521 -3.0996 $out [1] -14.90 7.15 3.11 1.03 -2.57 8.50 -6.86 $group [1] 3 4 6 6 9 11 11 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(6.27000000000001, 8.72, 9.14, 12.21, 13.07, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/60f2z1319286495.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] [1,] 102.420 104.330 107.000 115.080 110.910 NA [2,] 103.755 105.535 111.775 116.515 117.705 NA [3,] 104.980 108.850 114.285 119.475 120.950 NA [4,] 108.040 111.085 116.920 121.525 123.720 NA [5,] 111.040 113.990 122.620 127.910 129.610 NA $n [1] 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 103.0256 106.3186 111.9383 117.1899 118.2065 NA [2,] 106.9344 111.3814 116.6317 121.7601 123.6935 NA $out [1] 102.28 $group [1] 3 $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(102.42, 103.755, 104.98, 108.04, 111.04, 104.33, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/71u111319286495.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,] 108.350 104.330 108.7500 [2,] 111.273 110.535 111.0250 [3,] 113.833 114.230 114.1475 [4,] 115.483 116.400 115.9775 [5,] 119.738 117.390 120.9500 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 111.9128 111.5549 111.8886 [2,] 115.7532 116.9051 116.4064 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(108.35, 111.273, 113.833, 115.483, 119.738, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1438l1319286495.ps tmp/1438l1319286495.png",intern=TRUE)) character(0) > try(system("convert tmp/2vyyd1319286495.ps tmp/2vyyd1319286495.png",intern=TRUE)) character(0) > try(system("convert tmp/3774e1319286495.ps tmp/3774e1319286495.png",intern=TRUE)) character(0) > try(system("convert tmp/4fx0m1319286495.ps tmp/4fx0m1319286495.png",intern=TRUE)) character(0) > try(system("convert tmp/56ndy1319286495.ps tmp/56ndy1319286495.png",intern=TRUE)) character(0) > try(system("convert tmp/60f2z1319286495.ps tmp/60f2z1319286495.png",intern=TRUE)) character(0) > try(system("convert tmp/71u111319286495.ps tmp/71u111319286495.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 2.540 0.250 2.787