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. Natural language support but running in an English locale 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(244,243,242,240,260,259,244,234,235,235,236,238,240,233,233,233,247,251,233,226,233,233,227,225,223,212,206,202,223,221,212,205,204,200,195,193,196,180,174,164,192,189,181,167,166,164,167,164,161,141,134,111,147,144,142,140,143,137,140,130,129,112,101,74,104,103,100,98,99,91,92,94,93,76,64,32,62,69,69,68,68,59,66,73,70,57,48,22,64,74,67,61,61,52,54,69,69,53,50,22,69,78,74,63,67,59,60,80,77,58,54,32,78,86,84,78,72,64,62,72) > 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,] 244 240 223 196 161 129 93 70 69 77 NA [2,] 243 233 212 180 141 112 76 57 53 58 NA [3,] 242 233 206 174 134 101 64 48 50 54 NA [4,] 240 233 202 164 111 74 32 22 22 32 NA [5,] 260 247 223 192 147 104 62 64 69 78 NA [6,] 259 251 221 189 144 103 69 74 78 86 NA [7,] 244 233 212 181 142 100 69 67 74 84 NA [8,] 234 226 205 167 140 98 68 61 63 78 NA [9,] 235 233 204 166 143 99 68 61 67 72 NA [10,] 235 233 200 164 137 91 59 52 59 64 NA [11,] 236 227 195 167 140 92 66 54 60 62 NA [12,] 238 225 193 164 130 94 73 69 80 72 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [1,] -1 -7 -11 -16 -20 -17 -17 -13 -16 -19 NA [2,] -1 0 -6 -6 -7 -11 -12 -9 -3 -4 NA [3,] -2 0 -4 -10 -23 -27 -32 -26 -28 -22 NA [4,] 20 14 21 28 36 30 30 42 47 46 NA [5,] -1 4 -2 -3 -3 -1 7 10 9 8 NA [6,] -15 -18 -9 -8 -2 -3 0 -7 -4 -2 NA [7,] -10 -7 -7 -14 -2 -2 -1 -6 -11 -6 NA [8,] 1 7 -1 -1 3 1 0 0 4 -6 NA [9,] 0 0 -4 -2 -6 -8 -9 -9 -8 -8 NA [10,] 1 -6 -5 3 3 1 7 2 1 -2 NA [11,] 2 -2 -2 -3 -10 2 7 15 20 10 NA [12,] 2 -2 3 -3 -1 -1 -3 0 -3 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/freestat/rcomp/tmp/1qdzj1281902275.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/freestat/rcomp/tmp/2qdzj1281902275.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/freestat/rcomp/tmp/31nhm1281902275.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/freestat/rcomp/tmp/41nhm1281902275.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,] 69 53.0 48.0 22.0 62.0 69.0 67 61 61 52 54 69 [2,] 77 58.0 54.0 32.0 69.0 78.0 74 68 68 59 62 73 [3,] 145 126.5 117.5 92.5 125.5 123.5 121 119 121 114 116 112 [4,] 223 212.0 206.0 202.0 223.0 221.0 212 205 204 200 195 193 [5,] 244 243.0 242.0 240.0 260.0 259.0 244 234 235 235 236 238 $n [1] 10 10 10 10 10 10 10 10 10 10 10 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 72.05258 49.55546 41.55474 7.561222 48.55546 52.0515 52.0497 [2,] 217.94742 203.44454 193.44526 177.438778 202.44454 194.9485 189.9503 [,8] [,9] [,10] [,11] [,12] [1,] 50.54934 53.04898 43.55078 49.5479 52.04322 [2,] 187.45066 188.95102 184.44922 182.4521 171.95678 $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(69, 77, 145, 223, 244, 53, 58, 126.5, 212, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/51nhm1281902275.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,] -20 -12 -32.0 14 -3.0 -18.0 -14.0 -6.0 -9 -6 -10 -3 [2,] -17 -9 -27.0 21 -2.0 -9.0 -10.0 -1.0 -8 -2 -2 -3 [3,] -16 -6 -22.5 30 1.5 -5.5 -6.5 0.5 -7 1 2 -1 [4,] -11 -3 -4.0 42 8.0 -2.0 -2.0 3.0 -2 3 10 0 [5,] -7 0 0.0 47 10.0 0.0 -1.0 7.0 0 7 20 3 $n [1] 10 10 10 10 10 10 10 10 10 10 10 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -18.99784 -8.997839 -33.99172 19.50756 -3.496399 -8.997479 -10.497119 [2,] -13.00216 -3.002161 -11.00828 40.49244 6.496399 -2.002521 -2.502881 [,8] [,9] [,10] [,11] [,12] [1,] -1.498559 -9.997839 -1.498199 -3.995678 -2.58 [2,] 2.498559 -4.002161 3.498199 7.995678 0.58 $out [1] -1 $group [1] 1 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-20, -17, -16, -11, -7, -12, -9, -6, -3, 0, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/6ceyp1281902275.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,] 234.0 225.0 193.0 164.0 130.0 91.0 59 48 50.0 54 NA [2,] 235.5 230.0 201.0 165.0 135.5 93.0 63 53 56.0 60 NA [3,] 241.0 233.0 205.5 170.5 140.5 99.5 68 61 65.0 72 NA [4,] 244.0 236.5 216.5 185.0 143.5 103.5 71 68 71.5 78 NA [5,] 244.0 240.0 223.0 196.0 147.0 112.0 76 74 80.0 86 NA $n [1] 12 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 237.1231 230.0353 198.4303 161.3779 136.8511 94.71088 64.35115 54.1584 [2,] 244.8769 235.9647 212.5697 179.6221 144.1489 104.28912 71.64885 67.8416 [,9] [,10] [,11] [1,] 57.93035 63.79008 NA [2,] 72.06965 80.20992 NA $out [1] 260 259 247 251 161 111 129 74 93 32 22 22 32 $group [1] 1 1 2 2 5 5 6 6 7 7 8 9 10 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" NA Warning message: In bxp(list(stats = c(234, 235.5, 241, 244, 244, 225, 230, 233, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/7ceyp1281902275.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,] 113.20 112.0 112.2500 [2,] 130.25 115.0 126.4375 [3,] 134.40 120.0 132.3750 [4,] 142.60 124.5 141.8125 [5,] 150.20 126.5 148.6250 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 128.7671 115.6670 125.3624 [2,] 140.0329 124.3330 139.3876 $out [1] 145.0 92.5 $group [1] 2 2 $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(113.2, 130.25, 134.4, 142.6, 150.2, 112, 115, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1qdzj1281902275.ps tmp/1qdzj1281902275.png",intern=TRUE)) character(0) > try(system("convert tmp/2qdzj1281902275.ps tmp/2qdzj1281902275.png",intern=TRUE)) character(0) > try(system("convert tmp/31nhm1281902275.ps tmp/31nhm1281902275.png",intern=TRUE)) character(0) > try(system("convert tmp/41nhm1281902275.ps tmp/41nhm1281902275.png",intern=TRUE)) character(0) > try(system("convert tmp/51nhm1281902275.ps tmp/51nhm1281902275.png",intern=TRUE)) character(0) > try(system("convert tmp/6ceyp1281902275.ps tmp/6ceyp1281902275.png",intern=TRUE)) character(0) > try(system("convert tmp/7ceyp1281902275.ps tmp/7ceyp1281902275.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.946 1.475 2.175