R version 2.11.1 (2010-05-31) Copyright (C) 2010 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(145,621,262,208,362,424,339,736,291,58,498,643,390,332,750,368,659,234,396,300,343,536,543,217,298,1103,406,254,862,204,206,250,21,298,350,800,726,370,536,291,808,543,149,350,242,198,213,296,317,482,155,802,200,282,573,388,250,396,572) > 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] 59 > (np <- floor(n / par1)) [1] 4 > 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 4 > arr [,1] [,2] [,3] [,4] [,5] [1,] 145 390 298 726 317 [2,] 621 332 1103 370 482 [3,] 262 750 406 536 155 [4,] 208 368 254 291 802 [5,] 362 659 862 808 200 [6,] 424 234 204 543 282 [7,] 339 396 206 149 573 [8,] 736 300 250 350 388 [9,] 291 343 21 242 250 [10,] 58 536 298 198 396 [11,] 498 543 350 213 572 [12,] 643 217 800 296 NA > darr [,1] [,2] [,3] [,4] [,5] [1,] 476 -58 805 -356 165 [2,] -359 418 -697 166 -327 [3,] -54 -382 -152 -245 647 [4,] 154 291 608 517 -602 [5,] 62 -425 -658 -265 82 [6,] -85 162 2 -394 291 [7,] 397 -96 44 201 -185 [8,] -445 43 -229 -108 -138 [9,] -233 193 277 -44 146 [10,] 440 7 52 15 176 [11,] 145 -326 450 83 NA [12,] -253 81 -74 21 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/rcomp/tmp/11qij1290641358.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/rcomp/tmp/2uzh41290641358.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/rcomp/tmp/3uzh41290641358.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/rcomp/tmp/448zp1290641358.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,] 298 332 155 208 200 204 149 250 242 58 213 217.0 [2,] 298 370 262 254 362 234 206 300 242 198 350 256.5 [3,] 317 482 406 291 659 282 339 350 250 298 498 469.5 [4,] 390 621 536 368 808 424 396 388 291 396 543 721.5 [5,] 390 621 750 368 862 543 573 388 343 536 572 800.0 $n [1] 5 5 5 5 5 5 5 5 5 5 5 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 251.9930 304.6440 212.3923 210.4479 343.8575 147.7465 204.7465 287.8194 [2,] 382.0070 659.3560 599.6077 371.5521 974.1425 416.2535 473.2535 412.1806 [,9] [,10] [,11] [,12] [1,] 215.3767 158.0937 361.6267 102.15 [2,] 284.6233 437.9063 634.3733 836.85 $out [1] 145 726 1103 802 736 21 $group [1] 1 1 2 4 8 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(298, 298, 317, 390, 390, 332, 370, 482, 621, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/548zp1290641358.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,] -356 -697 -382 154 -658 -394 -185 -229 -233 7 -326.0 -253.0 [2,] -58 -359 -245 154 -425 -85 -96 -229 -44 15 -121.5 -163.5 [3,] 165 -327 -152 291 -265 2 44 -138 146 52 114.0 -26.5 [4,] 476 166 -54 517 62 162 201 -108 193 176 297.5 51.0 [5,] 805 418 -54 608 82 291 397 43 277 176 450.0 81.0 $n [1] 5 5 5 5 5 5 5 5 5 5 4 4 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -212.3231 -697.96368 -286.96012 34.50511 -609.11297 -172.5296 -165.8595 [2,] 542.3231 43.96368 -17.03988 547.49489 79.11297 176.5296 253.8595 [,8] [,9] [,10] [,11] [,12] [1,] -223.4983 -21.46360 -61.7622 -217.01 -195.955 [2,] -52.5017 313.46360 165.7622 445.01 142.955 $out [1] 647 -602 -445 440 $group [1] 3 4 8 10 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-356, -58, 165, 476, 805, -697, -359, -327, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/648zp1290641358.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] [1,] 58.0 217.0 21 149.0 155 [2,] 235.0 316.0 228 227.5 266 [3,] 350.5 379.0 298 323.0 388 [4,] 559.5 539.5 603 539.5 527 [5,] 736.0 750.0 1103 808.0 802 $n [1] 12 12 12 12 11 $conf [,1] [,2] [,3] [,4] [,5] [1,] 202.4934 277.0601 126.9600 180.6947 263.6628 [2,] 498.5066 480.9399 469.0400 465.3053 512.3372 $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" NA Warning message: In bxp(list(stats = c(58, 235, 350.5, 559.5, 736, 217, 316, 379, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/7xhga1290641358.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,] 229.4 250.00 266.500 [2,] 335.0 294.50 306.000 [3,] 394.7 344.50 344.000 [4,] 462.1 475.75 462.875 [5,] 581.6 659.00 585.000 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 336.7288 261.8307 272.4483 [2,] 452.6712 427.1693 415.5517 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(229.4, 335, 394.7, 462.1, 581.6, 250, 294.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/11qij1290641358.ps tmp/11qij1290641358.png",intern=TRUE)) character(0) > try(system("convert tmp/2uzh41290641358.ps tmp/2uzh41290641358.png",intern=TRUE)) character(0) > try(system("convert tmp/3uzh41290641358.ps tmp/3uzh41290641358.png",intern=TRUE)) character(0) > try(system("convert tmp/448zp1290641358.ps tmp/448zp1290641358.png",intern=TRUE)) character(0) > try(system("convert tmp/548zp1290641358.ps tmp/548zp1290641358.png",intern=TRUE)) character(0) > try(system("convert tmp/648zp1290641358.ps tmp/648zp1290641358.png",intern=TRUE)) character(0) > try(system("convert tmp/7xhga1290641358.ps tmp/7xhga1290641358.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 2.000 0.600 2.586