R version 2.12.1 (2010-12-16) Copyright (C) 2010 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i686-pc-linux-gnu (32-bit) 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(1394,1657,2411,3595,3336,3249,2920,2113,2040,1853,1832,2093,2164,2368,2072,2521,1819,1947,2226,1754,1787,2072,1846,2137,2467,2154,2289,2628,2074,2798,2194,2442,2565,2063,2069,2539,1898,2139,2408,2725,2201,2311,2548,2276,2351,2280,2057,2479,2379,2295,2456,2546,2844,2260,2981,2678,3440,2842,2450,2669,2570,2540,2318,2930,2947,2799,2695,2498,2260,2160,2058,2533,2150,2172,2155,3016,2333,2355,2825,2214,2360,2299,1746,2069,2267,1878,2266,2282,2085,2277,2251,1828,1954,1851,1570,1852,2187,1855,2218) > 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] 99 > (np <- floor(n / par1)) [1] 8 > arr <- array(NA,dim=c(par1,np+1)) > ari <- array(0,dim=par1) > j <- 0 > for (i in 1:n) + { + j = j + 1 + ari[j] = ari[j] + 1 + arr[j,ari[j]] <- x[i] + if (j == par1) j = 0 + } > ari [1] 9 9 9 8 8 8 8 8 8 8 8 8 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [1,] 1394 2164 2467 1898 2379 2570 2150 2267 2187 [2,] 1657 2368 2154 2139 2295 2540 2172 1878 1855 [3,] 2411 2072 2289 2408 2456 2318 2155 2266 2218 [4,] 3595 2521 2628 2725 2546 2930 3016 2282 NA [5,] 3336 1819 2074 2201 2844 2947 2333 2085 NA [6,] 3249 1947 2798 2311 2260 2799 2355 2277 NA [7,] 2920 2226 2194 2548 2981 2695 2825 2251 NA [8,] 2113 1754 2442 2276 2678 2498 2214 1828 NA [9,] 2040 1787 2565 2351 3440 2260 2360 1954 NA [10,] 1853 2072 2063 2280 2842 2160 2299 1851 NA [11,] 1832 1846 2069 2057 2450 2058 1746 1570 NA [12,] 2093 2137 2539 2479 2669 2533 2069 1852 NA > arr.sd <- array(NA,dim=par1) > arr.range <- array(NA,dim=par1) > arr.iqr <- array(NA,dim=par1) > for (j in 1:par1) + { + arr.sd[j] <- sqrt(var(arr[j,],na.rm=TRUE)) + arr.range[j] <- max(arr[j,],na.rm=TRUE) - min(arr[j,],na.rm=TRUE) + arr.iqr[j] <- quantile(arr[j,],0.75,na.rm=TRUE) - quantile(arr[j,],0.25,na.rm=TRUE) + } > overall.sd <- sqrt(var(x)) > overall.range <- max(x) - min(x) > overall.iqr <- quantile(x,0.75) - quantile(x,0.25) > postscript(file="/var/www/html/freestat/rcomp/tmp/1s9s31304973644.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.sd,type='b',ylab='S.D.',main='Standard Deviation Plot',xlab='Periodic Index') > mtext(paste('# blocks = ',np)) > abline(overall.sd,0) > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/2b32u1304973644.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.range,type='b',ylab='range',main='Range Plot',xlab='Periodic Index') > mtext(paste('# blocks = ',np)) > abline(overall.range,0) > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/3tjj91304973644.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(arr.iqr,type='b',ylab='IQR',main='Interquartile Range Plot',xlab='Periodic Index') > mtext(paste('# blocks = ',np)) > abline(overall.iqr,0) > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/4r7691304973644.ps",horizontal=F,onefile=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] [1,] 1898 1657 2072 2282.0 1819.0 1947.0 2194.0 1754.0 1787.0 1851.0 1570.0 [2,] 2150 1878 2218 2533.5 2079.5 2268.5 2238.5 1970.5 1997.0 1958.0 1789.0 [3,] 2187 2154 2289 2676.5 2267.0 2333.0 2621.5 2245.0 2305.5 2116.0 1951.5 [4,] 2379 2295 2408 2973.0 2895.5 2798.5 2872.5 2470.0 2462.5 2289.5 2063.5 [5,] 2570 2540 2456 3595.0 3336.0 3249.0 2981.0 2678.0 2565.0 2299.0 2450.0 [,12] [1,] 1852 [2,] 2081 [3,] 2308 [4,] 2536 [5,] 2669 $n [1] 9 9 9 8 8 8 8 8 8 8 8 8 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 2066.393 1934.38 2188.933 2430.989 1811.171 2036.934 2267.338 1965.972 [2,] 2307.607 2373.62 2389.067 2922.011 2722.829 2629.066 2975.662 2524.028 [,9] [,10] [,11] [,12] [1,] 2045.465 1930.819 1798.160 2053.830 [2,] 2565.535 2301.181 2104.840 2562.170 $out [1] 1394 3440 2842 $group [1] 1 9 10 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(1898, 2150, 2187, 2379, 2570, 1657, 1878, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/5czm81304973644.ps",horizontal=F,onefile=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] [1,] 1394.0 1754.0 2063.0 1898.0 2260.0 2058.0 2069.0 1570.0 1855.0 [2,] 1842.5 1832.5 2114.0 2170.0 2414.5 2289.0 2152.5 1851.5 2021.0 [3,] 2103.0 2072.0 2365.5 2295.5 2607.5 2536.5 2256.5 2019.5 2187.0 [4,] 3084.5 2195.0 2552.0 2443.5 2843.0 2747.0 2357.5 2266.5 2202.5 [5,] 3595.0 2521.0 2798.0 2725.0 3440.0 2947.0 2360.0 2282.0 2218.0 $n [1] 12 12 12 12 12 12 12 12 3 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 1536.515 1906.661 2165.725 2170.755 2412.058 2327.603 2162.998 1830.216 [2,] 2669.485 2237.339 2565.275 2420.245 2802.942 2745.397 2350.002 2208.784 [,9] [1,] 2021.433 [2,] 2352.567 $out [1] 3016 2825 1746 $group [1] 7 7 7 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" NA Warning message: In bxp(list(stats = c(1394, 1842.5, 2103, 3084.5, 3595, 1754, 1832.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/675o51304973644.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > z <- data.frame(cbind(arr.sd,arr.range,arr.iqr)) > names(z) <- list('S.D.','Range','IQR') > (boxplot(z,notch=TRUE,col='grey',ylab='Overall Variability',main='Notched Box Plots')) $stats [,1] [,2] [,3] [1,] 126.6802 384.0 190.00 [2,] 285.4772 848.5 262.25 [3,] 322.3515 957.5 413.00 [4,] 409.4374 1307.5 486.50 [5,] 525.8331 1653.0 787.50 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 265.8124 748.147 310.7181 [2,] 378.8905 1166.853 515.2819 $out numeric(0) $group numeric(0) $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(126.680152790842, 285.477236305187, 322.351450399362, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1s9s31304973644.ps tmp/1s9s31304973644.png",intern=TRUE)) character(0) > try(system("convert tmp/2b32u1304973644.ps tmp/2b32u1304973644.png",intern=TRUE)) character(0) > try(system("convert tmp/3tjj91304973644.ps tmp/3tjj91304973644.png",intern=TRUE)) character(0) > try(system("convert tmp/4r7691304973644.ps tmp/4r7691304973644.png",intern=TRUE)) character(0) > try(system("convert tmp/5czm81304973644.ps tmp/5czm81304973644.png",intern=TRUE)) character(0) > try(system("convert tmp/675o51304973644.ps tmp/675o51304973644.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.631 0.198 1.990