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(591000,589000,584000,573000,567000,569000,621000,629000,628000,612000,595000,597000,593000,590000,580000,574000,573000,573000,620000,626000,620000,588000,566000,557000,561000,549000,532000,526000,511000,499000,555000,565000,542000,527000,510000,514000,517000,508000,493000,490000,469000,478000,528000,534000,518000,506000,502000,516000,528000,533000,536000,537000,524000,536000,587000,597000,581000,564000,558000,575000) > 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] 60 > (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] 5 5 5 5 5 5 5 5 5 5 5 5 > arr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 591000 593000 561000 517000 528000 NA [2,] 589000 590000 549000 508000 533000 NA [3,] 584000 580000 532000 493000 536000 NA [4,] 573000 574000 526000 490000 537000 NA [5,] 567000 573000 511000 469000 524000 NA [6,] 569000 573000 499000 478000 536000 NA [7,] 621000 620000 555000 528000 587000 NA [8,] 629000 626000 565000 534000 597000 NA [9,] 628000 620000 542000 518000 581000 NA [10,] 612000 588000 527000 506000 564000 NA [11,] 595000 566000 510000 502000 558000 NA [12,] 597000 557000 514000 516000 575000 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] -2000 -3000 -12000 -9000 5000 NA [2,] -5000 -10000 -17000 -15000 3000 NA [3,] -11000 -6000 -6000 -3000 1000 NA [4,] -6000 -1000 -15000 -21000 -13000 NA [5,] 2000 0 -12000 9000 12000 NA [6,] 52000 47000 56000 50000 51000 NA [7,] 8000 6000 10000 6000 10000 NA [8,] -1000 -6000 -23000 -16000 -16000 NA [9,] -16000 -32000 -15000 -12000 -17000 NA [10,] -17000 -22000 -17000 -4000 -6000 NA [11,] 2000 -9000 4000 14000 17000 NA [12,] -4000 4000 3000 12000 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/1f9h01289828895.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/27iy31289828895.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/37iy31289828895.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/47iy31289828895.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,] 517000 508000 493000 490000 469000 478000 528000 534000 518000 506000 [2,] 528000 533000 532000 526000 511000 499000 555000 565000 542000 527000 [3,] 561000 549000 536000 537000 524000 536000 587000 597000 581000 564000 [4,] 591000 589000 580000 573000 567000 569000 620000 626000 620000 588000 [5,] 593000 590000 584000 574000 573000 573000 621000 629000 628000 612000 [,11] [,12] [1,] 502000 514000 [2,] 510000 516000 [3,] 558000 557000 [4,] 566000 575000 [5,] 595000 597000 $n [1] 5 5 5 5 5 5 5 5 5 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 516484.4 509430.5 502083.3 503789.9 484430.5 486538.2 541071.2 553897.6 [2,] 605515.6 588569.5 569916.7 570210.1 563569.5 585461.8 632928.8 640102.4 [,9] [,10] [,11] [,12] [1,] 525885.4 520897.6 518430.5 515310.7 [2,] 636114.6 607102.4 597569.5 598689.3 $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(517000, 528000, 561000, 591000, 593000, 508000, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/50rf61289828895.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] [1,] -12000 -17000 -6000 -21000 -12000 47000 6000 -23000 -17000 -22000 -9000 [2,] -9000 -15000 -6000 -15000 0 50000 6000 -16000 -17000 -17000 2000 [3,] -3000 -10000 -6000 -13000 2000 51000 8000 -16000 -16000 -17000 4000 [4,] -2000 -5000 -3000 -6000 9000 52000 10000 -6000 -15000 -6000 14000 [5,] 5000 3000 1000 -1000 12000 52000 10000 -1000 -12000 -4000 17000 [,12] [1,] -4000 [2,] -500 [3,] 3500 [4,] 8000 [5,] 12000 $n [1] 5 5 5 5 5 5 5 5 5 5 5 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -7946.182 -17065.975 -8119.792 -19359.377 -4359.377 49586.81 5173.61 [2,] 1946.182 -2934.025 -3880.208 -6640.623 8359.377 52413.19 10826.39 [,8] [,9] [,10] [,11] [,12] [1,] -23065.975 -17413.19 -24772.572 -4479.17 -3215 [2,] -8934.025 -14586.81 -9227.428 12479.17 10215 $out [1] -11000 56000 -32000 $group [1] 3 6 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-12000, -9000, -3000, -2000, 5000, -17000, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/60rf61289828895.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,] 567000 557000 499000 469000 524000 NA [2,] 578500 573000 512500 491500 534500 NA [3,] 593000 584000 529500 507000 547500 NA [4,] 616500 606500 552000 517500 578000 NA [5,] 629000 626000 565000 534000 597000 NA $n [1] 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 575668 568720.4 511483.8 495141.2 527659.4 NA [2,] 610332 599279.6 547516.2 518858.8 567340.6 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(567000, 578500, 593000, 616500, 629000, 557000, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7t1f91289828895.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,] 528800 524000 534000 [2,] 542500 536500 542250 [3,] 552800 557500 556750 [4,] 568600 572500 571000 [5,] 590200 597000 595500 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 540895.6 541080.2 543636.9 [2,] 564704.4 573919.8 569863.1 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(528800, 542500, 552800, 568600, 590200, 524000, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1f9h01289828895.ps tmp/1f9h01289828895.png",intern=TRUE)) character(0) > try(system("convert tmp/27iy31289828895.ps tmp/27iy31289828895.png",intern=TRUE)) character(0) > try(system("convert tmp/37iy31289828895.ps tmp/37iy31289828895.png",intern=TRUE)) character(0) > try(system("convert tmp/47iy31289828895.ps tmp/47iy31289828895.png",intern=TRUE)) character(0) > try(system("convert tmp/50rf61289828895.ps tmp/50rf61289828895.png",intern=TRUE)) character(0) > try(system("convert tmp/60rf61289828895.ps tmp/60rf61289828895.png",intern=TRUE)) character(0) > try(system("convert tmp/7t1f91289828895.ps tmp/7t1f91289828895.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.179 0.937 1.534