R version 2.9.0 (2009-04-17) Copyright (C) 2009 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(41086,39690,43129,37863,35953,29133,24693,22205,21725,27192,21790,13253,37702,30364,32609,30212,29965,28352,25814,22414,20506,28806,22228,13971,36845,35338,35022,34777,26887,23970,22780,17351,21382,24561,17409,11514,31514,27071,29462,26105,22397,23843,21705,18089,20764,25316,17704,15548,28029,29383,36438,32034,22679,24319,18004,17537,20366,22782,19169,13807,29743,25591,29096,26482,22405,27044,17970,18730,19684,19785,18479,10698,31956,29506,34506,27165,26736,23691,18157,17328,18205,20995,17382,9367,31124,26551,30651,25859,25100,25778,20418,18688,20424,24776,19814,12738,31566,30111,30019,31934,25826,26835,20205,17789,20520,22518,15572,11509,25447,24090,27786,26195,20516,22759,19028,16971,20036,22485,18730,14538) > 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] 120 > (np <- floor(n / par1)) [1] 10 > 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] 10 10 10 10 10 10 10 10 10 10 10 10 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [1,] 41086 37702 36845 31514 28029 29743 31956 31124 31566 25447 NA [2,] 39690 30364 35338 27071 29383 25591 29506 26551 30111 24090 NA [3,] 43129 32609 35022 29462 36438 29096 34506 30651 30019 27786 NA [4,] 37863 30212 34777 26105 32034 26482 27165 25859 31934 26195 NA [5,] 35953 29965 26887 22397 22679 22405 26736 25100 25826 20516 NA [6,] 29133 28352 23970 23843 24319 27044 23691 25778 26835 22759 NA [7,] 24693 25814 22780 21705 18004 17970 18157 20418 20205 19028 NA [8,] 22205 22414 17351 18089 17537 18730 17328 18688 17789 16971 NA [9,] 21725 20506 21382 20764 20366 19684 18205 20424 20520 20036 NA [10,] 27192 28806 24561 25316 22782 19785 20995 24776 22518 22485 NA [11,] 21790 22228 17409 17704 19169 18479 17382 19814 15572 18730 NA [12,] 13253 13971 11514 15548 13807 10698 9367 12738 11509 14538 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [1,] -1396 -7338 -1507 -4443 1354 -4152 -2450 -4573 -1455 -1357 NA [2,] 3439 2245 -316 2391 7055 3505 5000 4100 -92 3696 NA [3,] -5266 -2397 -245 -3357 -4404 -2614 -7341 -4792 1915 -1591 NA [4,] -1910 -247 -7890 -3708 -9355 -4077 -429 -759 -6108 -5679 NA [5,] -6820 -1613 -2917 1446 1640 4639 -3045 678 1009 2243 NA [6,] -4440 -2538 -1190 -2138 -6315 -9074 -5534 -5360 -6630 -3731 NA [7,] -2488 -3400 -5429 -3616 -467 760 -829 -1730 -2416 -2057 NA [8,] -480 -1908 4031 2675 2829 954 877 1736 2731 3065 NA [9,] 5467 8300 3179 4552 2416 101 2790 4352 1998 2449 NA [10,] -5402 -6578 -7152 -7612 -3613 -1306 -3613 -4962 -6946 -3755 NA [11,] -8537 -8257 -5895 -2156 -5362 -7781 -8015 -7076 -4063 -4192 NA [12,] 24449 22874 20000 12481 15936 21258 21757 18828 13938 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/1hhxz1272468920.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/2hhxz1272468920.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/3hhxz1272468920.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/49qw21272468920.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] [1,] 25447 24090.0 27786 25859.0 20516 22759.0 17970.0 16971 19684 19785.0 [2,] 29743 26551.0 29462 26195.0 22405 23843.0 18157.0 17351 20036 22485.0 [3,] 31540 29444.5 31630 28688.5 25463 25048.5 20311.5 17939 20465 23671.5 [4,] 36845 30364.0 35022 32034.0 26887 27044.0 22780.0 18730 20764 25316.0 [5,] 41086 35338.0 43129 37863.0 29965 29133.0 25814.0 18730 21725 28806.0 [,11] [,12] [1,] 15572.0 9367.0 [2,] 17409.0 11509.0 [3,] 18604.5 12995.5 [4,] 19814.0 13971.0 [5,] 22228.0 15548.0 $n [1] 10 10 10 10 10 10 10 10 10 10 10 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 27991.56 27539.37 28852 25771.10 23223.61 23449.15 18001.66 17250.00 [2,] 35088.44 31349.63 34408 31605.90 27702.39 26647.85 22621.34 18628.00 [,9] [,10] [,11] [,12] [1,] 20101.26 22257.02 17402.87 11765.39 [2,] 20828.74 25085.98 19806.13 14225.61 $out [1] 39690 35953 22205 22414 18205 $group [1] 2 5 8 8 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(25447, 29743, 31540, 36845, 41086, 24090, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/59qw21272468920.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] [1,] -7338.0 -316 -7341.0 -9355.0 -6820.0 -9074 -5429.0 -1908.0 101.0 -7612 [2,] -4443.0 2245 -4792.0 -6108.0 -2917.0 -6315 -3400.0 877.0 2416.0 -6946 [3,] -1978.5 3472 -2985.5 -3892.5 843.5 -4900 -2236.5 2205.5 2984.5 -5182 [4,] -1396.0 4100 -1591.0 -759.0 1640.0 -2538 -829.0 2829.0 4552.0 -3613 [5,] 1354.0 5000 1915.0 -247.0 4639.0 -1190 760.0 4031.0 5467.0 -1306 [,11] [,12] [1,] -8537.0 12481 [2,] -8015.0 15936 [3,] -6485.5 20000 [4,] -4192.0 21757 [5,] -2156.0 24449 $n [1] 10 10 10 10 10 10 10 10 10 10 10 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -3500.9027 2545.168 -4584.847 -6565.074 -1433.359 -6787.14 -3521.0741 [2,] -456.0973 4398.832 -1386.153 -1219.926 3120.359 -3012.86 -951.9259 [,8] [,9] [,10] [,11] [,12] [1,] 1230.203 1917.269 -6847.3 -8395.623 16934.27 [2,] 3180.797 4051.731 -3516.7 -4575.377 23065.73 $out [1] 7055 8300 $group [1] 2 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-7338, -4443, -1978.5, -1396, 1354, -316, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/62zd41272468920.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] [,10] [1,] 13253.0 13971 11514.0 15548.0 13807.0 10698.0 9367.0 12738 11509 14538.0 [2,] 21997.5 22321 19395.5 19426.5 18586.5 18604.5 17769.5 20116 18997 18879.0 [3,] 28162.5 28579 24265.5 23120.0 22730.5 21095.0 22343.0 24938 24172 21500.5 [4,] 38776.5 30288 34899.5 26588.0 28706.0 26763.0 28335.5 26205 30065 24768.5 [5,] 43129.0 37702 36845.0 31514.0 36438.0 29743.0 34506.0 31124 31934 27786.0 [,11] [1,] NA [2,] NA [3,] NA [4,] NA [5,] NA $n [1] 12 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 20509.49 24945.2 17194.02 19853.59 18114.93 17373.85 17523.78 22160.77 [2,] 35815.51 32212.8 31336.98 26386.41 27346.07 24816.15 27162.22 27715.23 [,9] [,10] [,11] [1,] 19123.81 18814.26 NA [2,] 29220.19 24186.74 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" NA Warning message: In bxp(list(stats = c(13253, 21997.5, 28162.5, 38776.5, 43129, 13971, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/72zd41272468920.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,] 12694.30 12995.5 12720.12 [2,] 19594.45 19458.0 19489.25 [3,] 24747.00 24360.0 24249.25 [4,] 29816.05 29066.5 28814.38 [5,] 32871.80 31630.0 32855.50 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 20084.86 19977.5 19996.00 [2,] 29409.14 28742.5 28502.50 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" > dev.off() null device 1 > > try(system("convert tmp/1hhxz1272468920.ps tmp/1hhxz1272468920.png",intern=TRUE)) character(0) > try(system("convert tmp/2hhxz1272468920.ps tmp/2hhxz1272468920.png",intern=TRUE)) character(0) > try(system("convert tmp/3hhxz1272468920.ps tmp/3hhxz1272468920.png",intern=TRUE)) character(0) > try(system("convert tmp/49qw21272468920.ps tmp/49qw21272468920.png",intern=TRUE)) character(0) > try(system("convert tmp/59qw21272468920.ps tmp/59qw21272468920.png",intern=TRUE)) character(0) > try(system("convert tmp/62zd41272468920.ps tmp/62zd41272468920.png",intern=TRUE)) character(0) > try(system("convert tmp/72zd41272468920.ps tmp/72zd41272468920.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.171 0.924 1.641