R version 2.8.0 (2008-10-20) 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(6550,8728,12026,14395,14587,13791,9498,8251,7049,9545,9364,8456,7237,9374,11837,13784,15926,13821,11143,7975,7610,10015,12759,8816,10677,10947,15200,17010,20900,16205,12143,8997,5568,11474,12256,10583,10862,10965,14405,20379,20128,17816,12268,8642,7962,13932,15936,12628,12267,12470,18944,21259,22015,18581,15175,10306,10792,14752,13754,11738,12181,12965,19990,23125,23541,21247,15189,14767,10895,17130,17697,16611,12674,12760,20249,22135,20677,19933,15388,15113,13401,16135,17562,14720,12225,11608,20985,19692,24081,22114,14220,13434,13598,17187,16119,13713,13210,14251,20139,21725,26099,21084,18024,16722,14385,21342,17180,14577) > 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] 108 > (np <- floor(n / par1)) [1] 9 > 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] 9 9 9 9 9 9 9 9 9 9 9 9 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] 6550 7237 10677 10862 12267 12181 12674 12225 13210 NA [2,] 8728 9374 10947 10965 12470 12965 12760 11608 14251 NA [3,] 12026 11837 15200 14405 18944 19990 20249 20985 20139 NA [4,] 14395 13784 17010 20379 21259 23125 22135 19692 21725 NA [5,] 14587 15926 20900 20128 22015 23541 20677 24081 26099 NA [6,] 13791 13821 16205 17816 18581 21247 19933 22114 21084 NA [7,] 9498 11143 12143 12268 15175 15189 15388 14220 18024 NA [8,] 8251 7975 8997 8642 10306 14767 15113 13434 16722 NA [9,] 7049 7610 5568 7962 10792 10895 13401 13598 14385 NA [10,] 9545 10015 11474 13932 14752 17130 16135 17187 21342 NA [11,] 9364 12759 12256 15936 13754 17697 17562 16119 17180 NA [12,] 8456 8816 10583 12628 11738 16611 14720 13713 14577 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] 2178 2137 270 103 203 784 86 -617 1041 NA [2,] 3298 2463 4253 3440 6474 7025 7489 9377 5888 NA [3,] 2369 1947 1810 5974 2315 3135 1886 -1293 1586 NA [4,] 192 2142 3890 -251 756 416 -1458 4389 4374 NA [5,] -796 -2105 -4695 -2312 -3434 -2294 -744 -1967 -5015 NA [6,] -4293 -2678 -4062 -5548 -3406 -6058 -4545 -7894 -3060 NA [7,] -1247 -3168 -3146 -3626 -4869 -422 -275 -786 -1302 NA [8,] -1202 -365 -3429 -680 486 -3872 -1712 164 -2337 NA [9,] 2496 2405 5906 5970 3960 6235 2734 3589 6957 NA [10,] -181 2744 782 2004 -998 567 1427 -1068 -4162 NA [11,] -908 -3943 -1673 -3308 -2016 -1086 -2842 -2406 -2603 NA [12,] -1219 1861 279 -361 443 -3937 -2495 -503 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/freestat/rcomp/tmp/1zrjk1272188757.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/freestat/rcomp/tmp/2zrjk1272188757.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/freestat/rcomp/tmp/3a0051272188757.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/freestat/rcomp/tmp/4a0051272188757.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,] 10677 8728 11837 13784 15926 13791 9498 7975 5568 9545 9364 8456 [2,] 10677 10947 14405 17010 20128 16205 12143 8642 7610 11474 12759 10583 [3,] 12181 11608 18944 20379 20900 18581 14220 10306 10792 14752 15936 12628 [4,] 12267 12760 20139 21725 23541 21084 15189 14767 13401 17130 17180 14577 [5,] 13210 14251 20985 23125 26099 22114 18024 16722 14385 21342 17697 16611 $n [1] 9 9 9 9 9 9 9 9 9 9 9 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 11343.6 10653.15 15924.09 17895.77 19102.49 16011.39 12615.77 7080.167 [2,] 13018.4 12562.85 21963.91 22862.23 22697.51 21150.61 15824.23 13531.833 [,9] [,10] [,11] [,12] [1,] 7742.073 11773.17 13607.61 10524.49 [2,] 13841.927 17730.83 18264.39 14731.51 $out [1] 6550 7237 14587 $group [1] 1 1 5 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(10677, 10677, 12181, 12267, 13210, 8728, 10947, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/5a0051272188757.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,] -617 2463 1586 -1458 -5015 -7894 -4869 -3872 2405 -4162 -3943 -3937 [2,] 103 3440 1810 192 -3434 -5548 -3168 -2337 2734 -998 -2842 -1857 [3,] 270 5888 1947 756 -2294 -4293 -1302 -1202 3960 567 -2406 -432 [4,] 1041 7025 2369 3890 -1967 -3406 -786 -365 5970 1427 -1673 361 [5,] 2178 9377 3135 4389 -744 -2678 -275 486 6957 2744 -908 1861 $n [1] 9 9 9 9 9 9 9 9 9 9 9 8 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] -224.0133 3999.9 1652.593 -1191.613 -3066.62 -5421.12 -2556.52 -2240.5867 [2,] 764.0133 7776.1 2241.407 2703.613 -1521.38 -3164.88 -47.48 -163.4133 [,9] [,10] [,11] [,12] [1,] 2255.707 -710.1667 -3021.673 -1671.0066 [2,] 5664.293 1844.1667 -1790.327 807.0066 $out [1] 5974 -1293 $group [1] 3 3 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-617, 103, 270, 1041, 2178, 2463, 3440, 5888, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/63az81272188757.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] [,8] [,9] [1,] 6550.0 7237.0 5568.0 7962.0 10306.0 10895.0 12674.0 11608.0 13210 [2,] 8353.5 8395.5 10630.0 10913.5 12002.5 13866.0 14060.5 13516.0 14481 [3,] 9431.0 10579.0 11808.5 13280.0 14253.0 16870.5 15761.5 15169.5 17602 [4,] 12908.5 13271.5 15702.5 16876.0 18762.5 20618.5 20091.0 20338.5 21213 [5,] 14587.0 15926.0 20900.0 20379.0 22015.0 23541.0 22135.0 24081.0 26099 [,10] [1,] NA [2,] NA [3,] NA [4,] NA [5,] NA $n [1] 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 7353.434 8355.024 9494.899 10560.46 11169.72 13790.64 13010.95 12057.71 [2,] 11508.566 12802.976 14122.101 15999.54 17336.28 19950.36 18512.05 18281.29 [,9] [,10] [1,] 14531.49 NA [2,] 20672.51 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" NA Warning message: In bxp(list(stats = c(6550, 8353.5, 9431, 12908.5, 14587, 7237, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/73az81272188757.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,] 10140.00 10306.0 10505.50 [2,] 11570.83 11894.5 11779.00 [3,] 14142.22 14486.0 13984.00 [4,] 17687.06 18762.5 17958.25 [5,] 20883.78 20900.0 21834.50 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 11352.57 11353.46 11165.60 [2,] 16931.87 17618.54 16802.40 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(10140, 11570.8333333333, 14142.2222222222, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1zrjk1272188757.ps tmp/1zrjk1272188757.png",intern=TRUE)) character(0) > try(system("convert tmp/2zrjk1272188757.ps tmp/2zrjk1272188757.png",intern=TRUE)) character(0) > try(system("convert tmp/3a0051272188757.ps tmp/3a0051272188757.png",intern=TRUE)) character(0) > try(system("convert tmp/4a0051272188757.ps tmp/4a0051272188757.png",intern=TRUE)) character(0) > try(system("convert tmp/5a0051272188757.ps tmp/5a0051272188757.png",intern=TRUE)) character(0) > try(system("convert tmp/63az81272188757.ps tmp/63az81272188757.png",intern=TRUE)) character(0) > try(system("convert tmp/73az81272188757.ps tmp/73az81272188757.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.881 1.473 2.293