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(392,394,392,396,392,396,419,421,420,418,410,418,426,428,430,424,423,427,441,449,452,462,455,461,461,463,462,456,455,456,472,472,471,465,459,465,468,467,463,460,462,461,476,476,471,453,443,442,444,438,427,424,416,406,431,434,418,412,404,409,412) > 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] 61 > (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] 6 5 5 5 5 5 5 5 5 5 5 5 > arr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 392 426 461 468 444 412 [2,] 394 428 463 467 438 NA [3,] 392 430 462 463 427 NA [4,] 396 424 456 460 424 NA [5,] 392 423 455 462 416 NA [6,] 396 427 456 461 406 NA [7,] 419 441 472 476 431 NA [8,] 421 449 472 476 434 NA [9,] 420 452 471 471 418 NA [10,] 418 462 465 453 412 NA [11,] 410 455 459 443 404 NA [12,] 418 461 465 442 409 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 2 2 2 -1 -6 NA [2,] -2 2 -1 -4 -11 NA [3,] 4 -6 -6 -3 -3 NA [4,] -4 -1 -1 2 -8 NA [5,] 4 4 1 -1 -10 NA [6,] 23 14 16 15 25 NA [7,] 2 8 0 0 3 NA [8,] -1 3 -1 -5 -16 NA [9,] -2 10 -6 -18 -6 NA [10,] -8 -7 -6 -10 -8 NA [11,] 8 6 6 -1 5 NA [12,] 8 0 3 2 3 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/15wfw1258136091.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/2asw31258136091.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/332q61258136091.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/48u3s1258136091.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,] 392 394 392 396 392 396 419 421 418 412 404 409 [2,] 412 428 427 424 416 406 431 434 420 418 410 418 [3,] 435 438 430 424 423 427 441 449 452 453 443 442 [4,] 461 463 462 456 455 456 472 472 471 462 455 461 [5,] 468 467 463 460 462 461 476 476 471 465 459 465 $n [1] 6 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 403.3934 413.2691 405.2691 401.3889 395.4427 391.6701 412.0295 422.1493 [2,] 466.6066 462.7309 454.7309 446.6111 450.5573 462.3299 469.9705 475.8507 [,9] [,10] [,11] [,12] [1,] 415.9635 421.9097 411.2031 411.6163 [2,] 488.0365 484.0903 474.7969 472.3837 $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(392, 412, 435, 461, 468, 394, 428, 438, 463, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5az3a1258136091.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,] -1 -4 -6 -8 -1 14 0 -5 -6 -8 5 2 [2,] -1 -4 -6 -4 -1 15 0 -5 -6 -8 5 2 [3,] 2 -2 -3 -1 1 16 2 -1 -6 -8 6 3 [4,] 2 -1 -3 -1 4 23 3 -1 -2 -7 6 3 [5,] 2 2 -3 2 4 25 3 3 -2 -6 6 3 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.1197924 -4.1197924 -5.1197924 -3.119792 -2.532987 10.34722 -0.1197924 [2,] 4.1197924 0.1197924 -0.8802076 1.119792 4.532987 21.65278 4.1197924 [,8] [,9] [,10] [,11] [,12] [1,] -3.82639 -8.82639 -8.706597 5.293403 2.293403 [2,] 1.82639 -3.17361 -7.293403 6.706597 3.706597 $out [1] -6 -11 4 -10 8 -16 10 -18 -10 8 -1 8 0 $group [1] 1 2 3 5 7 8 9 9 10 11 11 12 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-1, -1, 2, 2, 2, -4, -4, -2, -1, 2, -6, -6, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6k9sb1258136091.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] [1,] 392.0 423.0 455.0 442.0 404.0 412 [2,] 393.0 426.5 457.5 456.5 410.5 412 [3,] 403.0 435.5 462.5 462.5 421.0 412 [4,] 418.5 453.5 468.0 469.5 432.5 412 [5,] 421.0 462.0 472.0 476.0 444.0 412 $n [1] 12 12 12 12 12 1 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 391.3693 423.1851 457.7109 456.5706 410.9657 412 [2,] 414.6307 447.8149 467.2891 468.4294 431.0343 412 $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(392, 393, 403, 418.5, 421, 423, 426.5, 435.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7c8s51258136091.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,] 429.2000 423.0 431.0000 [2,] 432.9167 428.5 435.8125 [3,] 436.4000 439.5 440.0000 [4,] 444.2000 446.0 445.5000 [5,] 450.4000 453.0 453.0000 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 431.2536 431.5181 435.5815 [2,] 441.5464 447.4819 444.4185 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(429.2, 432.916666666667, 436.4, 444.2, 450.4, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/15wfw1258136091.ps tmp/15wfw1258136091.png") > system("convert tmp/2asw31258136091.ps tmp/2asw31258136091.png") > system("convert tmp/332q61258136091.ps tmp/332q61258136091.png") > system("convert tmp/48u3s1258136091.ps tmp/48u3s1258136091.png") > system("convert tmp/5az3a1258136091.ps tmp/5az3a1258136091.png") > system("convert tmp/6k9sb1258136091.ps tmp/6k9sb1258136091.png") > system("convert tmp/7c8s51258136091.ps tmp/7c8s51258136091.png") > > > proc.time() user system elapsed 1.183 0.969 1.498