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(569,580,578,565,547,555,562,561,555,544,537,543,594,611,613,611,594,595,591,589,584,573,567,569,621,629,628,612,595,597,593,590,580,574,573,573,620,626,620,588,566,557,561,549,532,526,511,499,555,565,542,527,510,514,517,508,493,490,469,478,528) > 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,] 569 594 621 620 555 528 [2,] 580 611 629 626 565 NA [3,] 578 613 628 620 542 NA [4,] 565 611 612 588 527 NA [5,] 547 594 595 566 510 NA [6,] 555 595 597 557 514 NA [7,] 562 591 593 561 517 NA [8,] 561 589 590 549 508 NA [9,] 555 584 580 532 493 NA [10,] 544 573 574 526 490 NA [11,] 537 567 573 511 469 NA [12,] 543 569 573 499 478 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 11 17 8 6 10 NA [2,] -2 2 -1 -6 -23 NA [3,] -13 -2 -16 -32 -15 NA [4,] -18 -17 -17 -22 -17 NA [5,] 8 1 2 -9 4 NA [6,] 7 -4 -4 4 3 NA [7,] -1 -2 -3 -12 -9 NA [8,] -6 -5 -10 -17 -15 NA [9,] -11 -11 -6 -6 -3 NA [10,] -7 -6 -1 -15 -21 NA [11,] 6 2 0 -12 9 NA [12,] 51 52 47 56 50 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/13j651229597051.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/2ys661229597051.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/3zg1g1229597051.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/4ss281229597051.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,] 528.0 565 542 527 510 514 517 508 493 490 469 478 [2,] 555.0 580 578 565 547 555 561 549 532 526 511 499 [3,] 581.5 611 613 588 566 557 562 561 555 544 537 543 [4,] 620.0 626 620 611 594 595 591 589 580 573 567 569 [5,] 621.0 629 628 612 595 597 593 590 584 574 573 573 $n [1] 6 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 539.5729 578.4965 583.3229 555.4965 532.7899 528.7361 540.8021 532.7361 [2,] 623.4271 643.5035 642.6771 620.5035 599.2101 585.2639 583.1979 589.2639 [,9] [,10] [,11] [,12] [1,] 521.0833 510.7899 497.4305 493.5382 [2,] 588.9167 577.2101 576.5695 592.4618 $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(528, 555, 581.5, 620, 621, 565, 580, 611, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5ofwv1229597051.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,] 6 -6 -16 -18 1 -4 -12 -17 -11 -21 0 47 [2,] 8 -6 -16 -18 1 -4 -9 -15 -11 -15 0 50 [3,] 10 -2 -15 -17 2 3 -3 -10 -6 -7 2 51 [4,] 11 -1 -13 -17 4 4 -2 -6 -6 -6 6 52 [5,] 11 2 -13 -17 8 7 -1 -5 -3 -1 9 52 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 7.880208 -5.532987 -17.11979 -17.70660 -0.1197924 -2.65278 -7.946182 [2,] 12.119792 1.532987 -12.88021 -16.29340 4.1197924 8.65278 1.946182 [,8] [,9] [,10] [,11] [,12] [1,] -16.359377 -9.532987 -13.3593773 -2.239585 49.58681 [2,] -3.640623 -2.467013 -0.6406227 6.239585 52.41319 $out [1] 17 -23 -2 -32 -22 -9 -12 56 $group [1] 1 2 3 3 4 5 11 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(6, 8, 10, 11, 11, -6, -6, -2, -1, 2, -16, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6f7uq1229597051.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,] 537.0 567.0 573.0 499 469.0 528 [2,] 545.5 578.5 577.0 529 491.5 528 [3,] 558.0 592.5 594.0 559 512.0 528 [4,] 567.0 603.0 616.5 604 534.5 528 [5,] 580.0 613.0 629.0 626 565.0 528 $n [1] 12 12 12 12 12 1 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 548.1937 581.3254 575.9838 524.792 492.3874 528 [2,] 567.8063 603.6746 612.0162 593.208 531.6126 528 $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(537, 545.5, 558, 567, 580, 567, 578.5, 592.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/75bjz1229597051.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,] 531.4000 537.00 534.00 [2,] 545.1000 549.50 552.75 [3,] 563.0000 561.50 572.75 [4,] 580.8833 584.75 587.00 [5,] 602.2000 613.00 603.00 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 546.679 545.4222 557.1283 [2,] 579.321 577.5778 588.3717 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(531.4, 545.1, 563, 580.883333333333, 602.2, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/13j651229597051.ps tmp/13j651229597051.png") > system("convert tmp/2ys661229597051.ps tmp/2ys661229597051.png") > system("convert tmp/3zg1g1229597051.ps tmp/3zg1g1229597051.png") > system("convert tmp/4ss281229597051.ps tmp/4ss281229597051.png") > system("convert tmp/5ofwv1229597051.ps tmp/5ofwv1229597051.png") > system("convert tmp/6f7uq1229597051.ps tmp/6f7uq1229597051.png") > system("convert tmp/75bjz1229597051.ps tmp/75bjz1229597051.png") > > > proc.time() user system elapsed 1.203 0.957 1.488