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(102.5,77.7,82.8,77.3,103.1,99.7,99.5,107.2,96.7,97.1,105.2,151.2,102.7,75.4,87.2,83.7,105.8,111.5,99.7,111.2,101.5,110.9,116.3,164.9,118.1,83.7,84,107.2,113.7,120.7,111.2,112.4,112.5,130.4,130.7,174.3,132.2,91.8,104.2,104.8,131.4,141.2,132.7,135.7,136.9,151.2,144,201.5,149.6,108.7,122.8,126.7,139.9,162.5,142.7,151.6,148.1,159,157.8,226.7,153.7,122.3,117.6,166,154.5,183.9,164.4,173.3,160.2,166.4,170.3,238.4,166.8,122.5,141.8,140.5,173.8,188.8,168,187.4,177.7,183.8,196.1,264.6,193.7,141.3,170.1,163.7,190.1,230.7,195.9,210.3,204.7,210.3,221.2,288.2,203.2,162.4,149.2,195.3,213.7,227.9,212.1,226.8,212.6,220.9,228.1,311.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] 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,] 102.5 102.7 118.1 132.2 149.6 153.7 166.8 193.7 203.2 NA [2,] 77.7 75.4 83.7 91.8 108.7 122.3 122.5 141.3 162.4 NA [3,] 82.8 87.2 84.0 104.2 122.8 117.6 141.8 170.1 149.2 NA [4,] 77.3 83.7 107.2 104.8 126.7 166.0 140.5 163.7 195.3 NA [5,] 103.1 105.8 113.7 131.4 139.9 154.5 173.8 190.1 213.7 NA [6,] 99.7 111.5 120.7 141.2 162.5 183.9 188.8 230.7 227.9 NA [7,] 99.5 99.7 111.2 132.7 142.7 164.4 168.0 195.9 212.1 NA [8,] 107.2 111.2 112.4 135.7 151.6 173.3 187.4 210.3 226.8 NA [9,] 96.7 101.5 112.5 136.9 148.1 160.2 177.7 204.7 212.6 NA [10,] 97.1 110.9 130.4 151.2 159.0 166.4 183.8 210.3 220.9 NA [11,] 105.2 116.3 130.7 144.0 157.8 170.3 196.1 221.2 228.1 NA [12,] 151.2 164.9 174.3 201.5 226.7 238.4 264.6 288.2 311.6 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] -24.8 -27.3 -34.4 -40.4 -40.9 -31.4 -44.3 -52.4 -40.8 NA [2,] 5.1 11.8 0.3 12.4 14.1 -4.7 19.3 28.8 -13.2 NA [3,] -5.5 -3.5 23.2 0.6 3.9 48.4 -1.3 -6.4 46.1 NA [4,] 25.8 22.1 6.5 26.6 13.2 -11.5 33.3 26.4 18.4 NA [5,] -3.4 5.7 7.0 9.8 22.6 29.4 15.0 40.6 14.2 NA [6,] -0.2 -11.8 -9.5 -8.5 -19.8 -19.5 -20.8 -34.8 -15.8 NA [7,] 7.7 11.5 1.2 3.0 8.9 8.9 19.4 14.4 14.7 NA [8,] -10.5 -9.7 0.1 1.2 -3.5 -13.1 -9.7 -5.6 -14.2 NA [9,] 0.4 9.4 17.9 14.3 10.9 6.2 6.1 5.6 8.3 NA [10,] 8.1 5.4 0.3 -7.2 -1.2 3.9 12.3 10.9 7.2 NA [11,] 46.0 48.6 43.6 57.5 68.9 68.1 68.5 67.0 83.5 NA [12,] -48.5 -46.8 -42.1 -51.9 -73.0 -71.6 -70.9 -85.0 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/1nv2a1259494641.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/2pxjg1259494641.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/32bth1259494641.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/4acnc1259494641.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,] 102.5 75.4 82.8 77.3 103.1 99.7 99.5 107.2 96.7 97.1 105.2 151.2 [2,] 118.1 83.7 87.2 104.8 113.7 120.7 111.2 112.4 112.5 130.4 130.7 174.3 [3,] 149.6 108.7 117.6 126.7 139.9 162.5 142.7 151.6 148.1 159.0 157.8 226.7 [4,] 166.8 122.5 141.8 163.7 173.8 188.8 168.0 187.4 177.7 183.8 196.1 264.6 [5,] 203.2 162.4 170.1 195.3 213.7 230.7 212.1 226.8 212.6 220.9 228.1 311.6 $n [1] 9 9 9 9 9 9 9 9 9 9 9 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 123.9513 88.26533 88.844 95.67933 108.2473 126.634 112.7853 112.1 [2,] 175.2487 129.13467 146.356 157.72067 171.5527 198.366 172.6147 191.1 [,9] [,10] [,11] [,12] [1,] 113.7613 130.876 123.356 179.142 [2,] 182.4387 187.124 192.244 274.258 $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(102.5, 118.1, 149.6, 166.8, 203.2, 75.4, 83.7, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5gv6l1259494641.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,] -52.4 -13.2 -6.4 6.5 -3.4 -34.8 1.2 -14.2 0.4 -7.2 43.6 -85.00 [2,] -40.9 0.3 -3.5 13.2 7.0 -19.8 7.7 -10.5 6.1 0.3 48.6 -72.30 [3,] -40.4 11.8 0.6 22.1 14.2 -15.8 8.9 -9.7 8.3 5.4 67.0 -61.40 [4,] -31.4 14.1 23.2 26.4 22.6 -9.5 14.4 -3.5 10.9 8.1 68.5 -47.65 [5,] -24.8 28.8 48.4 33.3 40.6 -0.2 19.4 1.2 17.9 12.3 83.5 -42.10 $n [1] 9 9 9 9 9 9 9 9 9 9 9 8 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] -45.40333 4.532 -13.462 15.148 5.984 -21.22467 5.371333 -13.386667 [2,] -35.39667 19.068 14.662 29.052 22.416 -10.37533 12.428667 -6.013333 [,9] [,10] [,11] [,12] [1,] 5.772 1.292 56.51933 -75.16984 [2,] 10.828 9.508 77.48067 -47.63016 $out [1] -11.5 $group [1] 4 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-52.4, -40.9, -40.4, -31.4, -24.8, -13.2000000000000, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6vm621259494641.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,] 77.30 75.40 107.20 91.8 108.70 153.7 122.50 141.30 162.40 NA [2,] 89.75 93.45 109.20 118.1 133.30 154.1 154.30 180.10 199.25 NA [3,] 99.60 104.25 113.10 134.2 148.85 165.2 175.75 200.30 213.15 NA [4,] 104.15 111.35 125.55 142.6 158.40 171.8 188.10 215.75 227.35 NA [5,] 107.20 116.30 130.70 151.2 162.50 183.9 196.10 230.70 228.10 NA $n [1] 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 93.03206 96.08569 105.6427 123.0254 137.4017 157.1269 160.3336 184.0398 [2,] 106.16794 112.41431 120.5573 145.3746 160.2983 173.2731 191.1664 216.5602 [,9] [,10] [1,] 200.3334 NA [2,] 225.9666 NA $out [1] 151.2 164.9 83.7 84.0 174.3 201.5 226.7 122.3 117.6 238.4 264.6 288.2 [13] 149.2 311.6 $group [1] 1 2 3 3 3 4 5 6 6 6 7 8 9 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" NA Warning message: In bxp(list(stats = c(77.3, 89.75, 99.6, 104.15, 107.2, 75.4, 93.45, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7x9ih1259494641.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,] 109.5333 108.70 114.500 [2,] 138.2056 133.30 136.925 [3,] 148.7278 148.85 144.425 [4,] 160.9389 158.40 155.925 [5,] 163.3000 162.50 163.400 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 138.3590 137.4017 135.7590 [2,] 159.0966 160.2983 153.0910 $out [1] 224.60 226.70 103.10 219.45 $group [1] 1 2 3 3 $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(109.533333333333, 138.205555555556, 148.727777777778, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1nv2a1259494641.ps tmp/1nv2a1259494641.png") > system("convert tmp/2pxjg1259494641.ps tmp/2pxjg1259494641.png") > system("convert tmp/32bth1259494641.ps tmp/32bth1259494641.png") > system("convert tmp/4acnc1259494641.ps tmp/4acnc1259494641.png") > system("convert tmp/5gv6l1259494641.ps tmp/5gv6l1259494641.png") > system("convert tmp/6vm621259494641.ps tmp/6vm621259494641.png") > system("convert tmp/7x9ih1259494641.ps tmp/7x9ih1259494641.png") > > > proc.time() user system elapsed 1.190 0.941 1.501