R version 3.3.1 (2016-06-21) -- "Bug in Your Hair" Copyright (C) 2016 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu (64-bit) 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(700,700,620,680,700,670,660,730,680,680,650,800,660,710,660,590,660,710,620,700,690,680,640,810,620,700,720,620,630,680,670,720,660,630,620,810,540,690,720,620,650,690,660,700,630,590,570,760,500,660,750,680,710,620,640,720,680,580,530,740,480,640,690,600,640,580,690,690,720,550,510,680,450,560,730,650,680,580,750,670,670,590,480,810,350,570,710,650,710,510,800,680,660,620,580,830,480,550,720,620,730,520,870,660,650,620,560,820) > par1 = '12' > 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,] 700 660 620 540 500 480 450 350 480 NA [2,] 700 710 700 690 660 640 560 570 550 NA [3,] 620 660 720 720 750 690 730 710 720 NA [4,] 680 590 620 620 680 600 650 650 620 NA [5,] 700 660 630 650 710 640 680 710 730 NA [6,] 670 710 680 690 620 580 580 510 520 NA [7,] 660 620 670 660 640 690 750 800 870 NA [8,] 730 700 720 700 720 690 670 680 660 NA [9,] 680 690 660 630 680 720 670 660 650 NA [10,] 680 680 630 590 580 550 590 620 620 NA [11,] 650 640 620 570 530 510 480 580 560 NA [12,] 800 810 810 760 740 680 810 830 820 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] 0 50 80 150 160 160 110 220 70 NA [2,] -80 -50 20 30 90 50 170 140 170 NA [3,] 60 -70 -100 -100 -70 -90 -80 -60 -100 NA [4,] 20 70 10 30 30 40 30 60 110 NA [5,] -30 50 50 40 -90 -60 -100 -200 -210 NA [6,] -10 -90 -10 -30 20 110 170 290 350 NA [7,] 70 80 50 40 80 0 -80 -120 -210 NA [8,] -50 -10 -60 -70 -40 30 0 -20 -10 NA [9,] 0 -10 -30 -40 -100 -170 -80 -40 -30 NA [10,] -30 -40 -10 -20 -50 -40 -110 -40 -60 NA [11,] 150 170 190 190 210 170 330 250 260 NA [12,] -140 -190 -270 -260 -260 -230 -460 -350 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/wessaorg/rcomp/tmp/1r0qx1471294691.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/2foml1471294691.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/3yxq71471294691.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/4bu811471294691.ps",horizontal=F,onefile=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,] 350 550 660 590 630 510 620 660 630 550 480 740 [2,] 480 570 690 620 650 580 660 680 660 590 530 760 [3,] 500 660 720 620 680 620 670 700 670 620 570 810 [4,] 620 700 720 650 710 680 750 720 680 630 620 810 [5,] 700 710 750 680 730 710 870 730 690 680 650 830 $n [1] 9 9 9 9 9 9 9 9 9 9 9 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [1,] 426.2667 591.5333 704.2 604.2 648.4 567.3333 622.6 678.9333 659.4667 [2,] 573.7333 728.4667 735.8 635.8 711.6 672.6667 717.4 721.0667 680.5333 [,10] [,11] [,12] [1,] 598.9333 522.6 783.6667 [2,] 641.0667 617.4 836.3333 $out [1] 620 720 680 $group [1] 3 9 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(350, 480, 500, 620, 700, 550, 570, 660, 700, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/5nf371471294691.ps",horizontal=F,onefile=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,] 0 -80 -100 10 -210 -90 -210 -70 -100 -60 150 -460 [2,] 70 20 -100 30 -100 -10 -80 -50 -80 -50 170 -310 [3,] 110 50 -80 30 -60 20 40 -20 -40 -40 190 -260 [4,] 160 140 -70 60 40 170 70 -10 -30 -30 250 -210 [5,] 220 170 -60 70 50 350 80 30 0 -10 330 -140 $n [1] 9 9 9 9 9 9 9 9 9 9 9 8 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [1,] 62.6 -13.2 -95.8 14.2 -133.73333 -74.8 -39 -41.066667 -66.33333 [2,] 157.4 113.2 -64.2 45.8 13.73333 114.8 119 1.066667 -13.66667 [,10] [,11] [,12] [1,] -50.53333 147.8667 -315.8614 [2,] -29.46667 232.1333 -204.1386 $out [1] 60 110 -170 -110 $group [1] 3 4 9 10 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(0, 70, 110, 160, 220, -80, 20, 50, 140, 170, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/61b4h1471294691.ps",horizontal=F,onefile=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,] 620 590 620 540 500 480 450 510 480 NA [2,] 665 650 625 605 600 565 570 575 555 NA [3,] 680 670 665 655 670 640 660 655 635 NA [4,] 700 705 710 695 715 690 705 710 725 NA [5,] 730 710 810 760 750 720 810 830 870 NA $n [1] 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 664.0363 644.9141 626.2309 613.9504 617.5477 582.9867 598.4256 593.4256 [2,] 695.9637 695.0859 703.7691 696.0496 722.4523 697.0133 721.5744 716.5744 [,9] [,10] [1,] 557.4619 NA [2,] 712.5381 NA $out [1] 800 810 350 $group [1] 1 2 8 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" NA Warning message: In bxp(list(stats = c(620, 665, 680, 700, 730, 590, 650, 670, 705, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/7bpko1471294691.ps",horizontal=F,onefile=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.1111 570 550.0 [2,] 616.6667 620 620.0 [3,] 656.6667 665 652.5 [4,] 699.4444 690 702.5 [5,] 784.4444 720 785.0 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 618.9112 633.0725 614.8712 [2,] 694.4222 696.9275 690.1288 $out [1] 500 810 $group [1] 2 2 $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(531.111111111111, 616.666666666667, 656.666666666667, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1r0qx1471294691.ps tmp/1r0qx1471294691.png",intern=TRUE)) character(0) > try(system("convert tmp/2foml1471294691.ps tmp/2foml1471294691.png",intern=TRUE)) character(0) > try(system("convert tmp/3yxq71471294691.ps tmp/3yxq71471294691.png",intern=TRUE)) character(0) > try(system("convert tmp/4bu811471294691.ps tmp/4bu811471294691.png",intern=TRUE)) character(0) > try(system("convert tmp/5nf371471294691.ps tmp/5nf371471294691.png",intern=TRUE)) character(0) > try(system("convert tmp/61b4h1471294691.ps tmp/61b4h1471294691.png",intern=TRUE)) character(0) > try(system("convert tmp/7bpko1471294691.ps tmp/7bpko1471294691.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 2.539 0.242 2.845