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(25,24,23,21,41,40,25,15,16,16,17,19,18,19,20,21,46,47,30,16,15,18,30,31,32,36,30,31,61,57,45,33,31,36,46,49,34,40,41,48,75,77,71,54,50,56,66,66,48,63,71,70,88,92,91,80,81,81,98,106,85,93,96,92,115,109,119,107,107,106,132,143,120,123,132,136,158,151,155,138,143,139,168,182,154,158,167,170,197,190,196,174,180,171,200,215,184,186,197,186,211,205,218,199,213,207,236,248,211,220,235,223,245,236,253,246,255,248,274,288) > 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] 120 > (np <- floor(n / par1)) [1] 10 > 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] 10 10 10 10 10 10 10 10 10 10 10 10 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [1,] 25 18 32 34 48 85 120 154 184 211 NA [2,] 24 19 36 40 63 93 123 158 186 220 NA [3,] 23 20 30 41 71 96 132 167 197 235 NA [4,] 21 21 31 48 70 92 136 170 186 223 NA [5,] 41 46 61 75 88 115 158 197 211 245 NA [6,] 40 47 57 77 92 109 151 190 205 236 NA [7,] 25 30 45 71 91 119 155 196 218 253 NA [8,] 15 16 33 54 80 107 138 174 199 246 NA [9,] 16 15 31 50 81 107 143 180 213 255 NA [10,] 16 18 36 56 81 106 139 171 207 248 NA [11,] 17 30 46 66 98 132 168 200 236 274 NA [12,] 19 31 49 66 106 143 182 215 248 288 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [1,] -1 1 4 6 15 8 3 4 2 9 NA [2,] -1 1 -6 1 8 3 9 9 11 15 NA [3,] -2 1 1 7 -1 -4 4 3 -11 -12 NA [4,] 20 25 30 27 18 23 22 27 25 22 NA [5,] -1 1 -4 2 4 -6 -7 -7 -6 -9 NA [6,] -15 -17 -12 -6 -1 10 4 6 13 17 NA [7,] -10 -14 -12 -17 -11 -12 -17 -22 -19 -7 NA [8,] 1 -1 -2 -4 1 0 5 6 14 9 NA [9,] 0 3 5 6 0 -1 -4 -9 -6 -7 NA [10,] 1 12 10 10 17 26 29 29 29 26 NA [11,] 2 1 3 0 8 11 14 15 12 14 NA [12,] -1 1 -15 -18 -21 -23 -28 -31 -37 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/rcomp/tmp/1430o1282236295.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/2430o1282236295.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/3wuh91282236295.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/4wuh91282236295.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,] 18.0 19 20.0 21 41.0 40.0 25 15.0 15 16.0 17 19.0 [2,] 32.0 36 30.0 31 61.0 57.0 45 33.0 31 36.0 46 49.0 [3,] 66.5 78 83.5 81 101.5 100.5 105 93.5 94 93.5 115 124.5 [4,] 154.0 158 167.0 170 197.0 190.0 196 174.0 180 171.0 200 215.0 [5,] 211.0 220 235.0 223 245.0 236.0 253 246.0 255 248.0 274 288.0 $n [1] 10 10 10 10 10 10 10 10 10 10 10 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 5.543936 17.04394 15.04934 11.55006 33.54898 34.0479 29.55438 [2,] 127.456064 138.95606 151.95066 150.44994 169.45102 166.9521 180.44562 [,8] [,9] [,10] [,11] [,12] [1,] 23.05078 19.55366 26.04862 38.05546 41.55978 [2,] 163.94922 168.44634 160.95138 191.94454 207.44022 $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(18, 32, 66.5, 154, 211, 19, 36, 78, 158, 220, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/5wuh91282236295.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 -6.0 -12 18 -9 -17.0 -22 -4 -9.0 1.0 0.0 -37 [2,] 2 1.0 -4 22 -7 -12.0 -17 -1 -6.0 10.0 2.0 -28 [3,] 4 5.5 0 24 -5 1.5 -13 1 -0.5 21.5 9.5 -21 [4,] 8 9.0 3 27 1 10.0 -11 6 3.0 29.0 14.0 -15 [5,] 15 15.0 7 30 4 17.0 -7 14 6.0 29.0 15.0 1 $n [1] 10 10 10 10 10 10 10 10 10 10 10 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 1.002161 1.502881 -3.497479 21.5018 -8.997119 -9.492077 -15.99784 [2,] 6.997839 9.497119 3.497479 26.4982 -1.002881 12.492077 -10.00216 [,8] [,9] [,10] [,11] [,12] [1,] -2.497479 -4.996759 12.00684 3.504322 -27.84667 [2,] 4.497479 3.996759 30.99316 15.495678 -14.15333 $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(-1, 2, 4, 8, 15, -6, 1, 5.5, 9, 15, -12, -4, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/6p4gu1282236295.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] [,7] [,8] [,9] [,10] [,11] [1,] 15.0 15.0 30.0 34.0 48.0 85.0 120.0 154.0 184.0 211.0 NA [2,] 16.5 18.0 31.5 44.5 70.5 94.5 134.0 168.5 191.5 229.0 NA [3,] 22.0 20.5 36.0 55.0 81.0 107.0 141.0 177.0 206.0 245.5 NA [4,] 25.0 30.5 47.5 68.5 91.5 117.0 156.5 196.5 215.5 254.0 NA [5,] 25.0 47.0 61.0 77.0 106.0 143.0 182.0 215.0 248.0 288.0 NA $n [1] 12 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 18.12309 14.79867 28.70229 44.05344 71.42176 96.7376 130.7376 164.229 [2,] 25.87691 26.20133 43.29771 65.94656 90.57824 117.2624 151.2624 189.771 [,9] [,10] [,11] [1,] 195.0534 234.0973 NA [2,] 216.9466 256.9027 NA $out [1] 41 40 $group [1] 1 1 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" NA Warning message: In bxp(list(stats = c(15, 16.5, 22, 25, 25, 15, 18, 20.5, 30.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/7p4gu1282236295.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,] 91.10 66.50 89.0000 [2,] 100.50 82.25 96.9375 [3,] 108.45 93.75 102.6250 [4,] 122.05 103.25 121.3125 [5,] 134.70 124.50 130.0000 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 98.6209 84.17176 91.5074 [2,] 118.2791 103.32824 113.7426 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(91.1, 100.5, 108.45, 122.05, 134.7, 66.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1430o1282236295.ps tmp/1430o1282236295.png",intern=TRUE)) character(0) > try(system("convert tmp/2430o1282236295.ps tmp/2430o1282236295.png",intern=TRUE)) character(0) > try(system("convert tmp/3wuh91282236295.ps tmp/3wuh91282236295.png",intern=TRUE)) character(0) > try(system("convert tmp/4wuh91282236295.ps tmp/4wuh91282236295.png",intern=TRUE)) character(0) > try(system("convert tmp/5wuh91282236295.ps tmp/5wuh91282236295.png",intern=TRUE)) character(0) > try(system("convert tmp/6p4gu1282236295.ps tmp/6p4gu1282236295.png",intern=TRUE)) character(0) > try(system("convert tmp/7p4gu1282236295.ps tmp/7p4gu1282236295.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.960 1.380 3.327