R version 2.7.0 (2008-04-22) 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. 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(2187,1852,1570,1851,1954,1828,2251,2277,2085,2282,2266,1878,2267,2069,1746,2299,2360,2214,2825,2355,2333,3016,2155,2172,2150,2533,2058,2160,2259,2498,2695,2799,2945,2930,2318,2540,2570,2669,2450,2842,3439,2677,2979,2257,2842,2546,2455,2293,2379,2478,2054,2272,2351,2271,2542,2304,2194,2722,2395,2146,1894,2548,2087,2063,2481,2476,2212,2834,2148,2598) > 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] 70 > (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] 6 6 6 6 6 6 6 6 6 6 5 5 > arr [,1] [,2] [,3] [,4] [,5] [,6] [1,] 2187 2267 2150 2570 2379 1894 [2,] 1852 2069 2533 2669 2478 2548 [3,] 1570 1746 2058 2450 2054 2087 [4,] 1851 2299 2160 2842 2272 2063 [5,] 1954 2360 2259 3439 2351 2481 [6,] 1828 2214 2498 2677 2271 2476 [7,] 2251 2825 2695 2979 2542 2212 [8,] 2277 2355 2799 2257 2304 2834 [9,] 2085 2333 2945 2842 2194 2148 [10,] 2282 3016 2930 2546 2722 2598 [11,] 2266 2155 2318 2455 2395 NA [12,] 1878 2172 2540 2293 2146 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [1,] -335 -198 383 99 99 654 [2,] -282 -323 -475 -219 -424 -461 [3,] 281 553 102 392 218 -24 [4,] 103 61 99 597 79 418 [5,] -126 -146 239 -762 -80 -5 [6,] 423 611 197 302 271 -264 [7,] 26 -470 104 -722 -238 622 [8,] -192 -22 146 585 -110 -686 [9,] 197 683 -15 -296 528 450 [10,] -16 -861 -612 -91 -327 NA [11,] -388 17 222 -162 -249 NA [12,] 389 -22 30 86 -252 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/1874p1228482493.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/2w5cx1228482493.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/3tqkt1228482493.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/4rinf1228482493.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,] 1894 1852.0 1570 1851 1954.0 1828.0 2212.0 2257.0 2085.0 2282 2155 2146 [2,] 2150 2069.0 1746 2063 2259.0 2214.0 2251.0 2277.0 2148.0 2546 2266 2146 [3,] 2227 2505.5 2056 2216 2355.5 2373.5 2618.5 2329.5 2263.5 2660 2318 2172 [4,] 2379 2548.0 2087 2299 2481.0 2498.0 2825.0 2799.0 2842.0 2930 2395 2293 [5,] 2570 2669.0 2450 2299 2481.0 2677.0 2979.0 2834.0 2945.0 3016 2455 2293 $n [1] 6 6 6 6 6 6 6 6 6 6 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 2079.288 2196.530 1836.044 2063.772 2212.303 2190.311 2248.251 1992.793 [2,] 2374.712 2814.470 2275.956 2368.228 2498.697 2556.689 2988.749 2666.207 [,9] [,10] [,11] [,12] [1,] 1815.848 2412.308 2226.849 2068.13 [2,] 2711.152 2907.692 2409.151 2275.87 $out [1] 2842 3439 1878 2540 $group [1] 4 5 12 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(1894, 2150, 2227, 2379, 2570, 1852, 2069, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/576f21228482493.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,] -335 -475.0 -24.0 61 -146 197.0 -722 -686 -296.0 -861 -388 -22 [2,] -198 -461.0 102.0 79 -146 197.0 -470 -192 -15.0 -612 -249 -22 [3,] 99 -373.5 249.5 101 -103 286.5 -106 -66 323.5 -327 -162 30 [4,] 383 -282.0 392.0 418 -5 423.0 104 146 528.0 -91 17 86 [5,] 654 -219.0 553.0 597 -5 611.0 622 585 683.0 -16 222 86 $n [1] 6 6 6 6 6 6 6 6 6 5 5 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -275.7638 -488.9608 62.44063 -117.6659 -193.94955 140.7227 -476.2485 [2,] 473.7638 -258.0392 436.55937 319.6659 -12.05045 432.2773 264.2485 [,8] [,9] [,10] [,11] [,12] [1,] -284.0209 -26.75254 -695.13729 -349.95493 -46.31253 [2,] 152.0209 673.75254 41.13729 25.95493 106.31253 $out [1] 239 -762 -264 389 -252 $group [1] 5 5 6 12 12 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-335, -198, 99, 383, 654, -475, -461, -373.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6g6as1228482493.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,] 1570.0 2069.0 2058.0 2257.0 2054.0 1894 [2,] 1851.5 2163.5 2209.5 2452.5 2232.5 2087 [3,] 2019.5 2283.0 2515.5 2619.5 2327.5 2344 [4,] 2258.5 2357.5 2747.0 2842.0 2436.5 2548 [5,] 2282.0 2360.0 2945.0 2979.0 2722.0 2834 $n [1] 12 12 12 12 12 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] 1833.865 2194.515 2270.343 2441.846 2234.454 2113.666 [2,] 2205.135 2371.485 2760.657 2797.154 2420.546 2574.334 $out [1] 1746 2825 3016 3439 $group [1] 2 2 2 4 $names [1] "1" "2" "3" "4" "5" NA Warning message: In bxp(list(stats = c(1570, 1851.5, 2019.5, 2258.5, 2282, 2069, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7gcw91228482493.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,] 1994.167 2056.00 1951.375 [2,] 2244.500 2221.50 2237.312 [3,] 2342.750 2323.75 2359.062 [4,] 2472.500 2439.50 2461.500 [5,] 2682.333 2660.00 2718.500 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 2238.758 2224.319 2256.809 [2,] 2446.742 2423.181 2461.316 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(1994.16666666667, 2244.5, 2342.75, 2472.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > system("convert tmp/1874p1228482493.ps tmp/1874p1228482493.png") > system("convert tmp/2w5cx1228482493.ps tmp/2w5cx1228482493.png") > system("convert tmp/3tqkt1228482493.ps tmp/3tqkt1228482493.png") > system("convert tmp/4rinf1228482493.ps tmp/4rinf1228482493.png") > system("convert tmp/576f21228482493.ps tmp/576f21228482493.png") > system("convert tmp/6g6as1228482493.ps tmp/6g6as1228482493.png") > system("convert tmp/7gcw91228482493.ps tmp/7gcw91228482493.png") > > > proc.time() user system elapsed 2.585 1.601 2.827