R version 2.13.0 (2011-04-13) Copyright (C) 2011 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i486-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. 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(5115,5105,5094,5074,5280,5270,5115,5012,5022,5022,5032,5053,5053,4960,4919,4960,5105,5084,4888,4722,4691,4629,4671,4722,4702,4660,4578,4660,4733,4712,4474,4371,4268,4185,4175,4237,4154,4123,4092,4268,4288,4185,3906,3782,3586,3503,3544,3606,3606,3555,3544,3710,3844,3782,3575,3472,3255,3121,3224,3327,3327,3193,3183,3358,3472,3431,3224,3090,2800,2687,2728,2904,2914,2656,2749,2976,3079,3017,2738,2542,2315,2139,2211,2366,2325,2098,2170,2397,2521,2449,2170,2046,1860,1664,1695,1850,1870,1684,1715,1974,2036,1932,1550,1354,1095,837,920,1033,1013,816,930,1209,1333,1271,1023,827,620,382,424,496) > 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)) > 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] 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,] 5115 5053 4702 4154 3606 3327 2914 2325 1870 1013 NA [2,] 5105 4960 4660 4123 3555 3193 2656 2098 1684 816 NA [3,] 5094 4919 4578 4092 3544 3183 2749 2170 1715 930 NA [4,] 5074 4960 4660 4268 3710 3358 2976 2397 1974 1209 NA [5,] 5280 5105 4733 4288 3844 3472 3079 2521 2036 1333 NA [6,] 5270 5084 4712 4185 3782 3431 3017 2449 1932 1271 NA [7,] 5115 4888 4474 3906 3575 3224 2738 2170 1550 1023 NA [8,] 5012 4722 4371 3782 3472 3090 2542 2046 1354 827 NA [9,] 5022 4691 4268 3586 3255 2800 2315 1860 1095 620 NA [10,] 5022 4629 4185 3503 3121 2687 2139 1664 837 382 NA [11,] 5032 4671 4175 3544 3224 2728 2211 1695 920 424 NA [12,] 5053 4722 4237 3606 3327 2904 2366 1850 1033 496 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/wessaorg/rcomp/tmp/10l6s1311846943.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/wessaorg/rcomp/tmp/2lr1l1311846943.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/wessaorg/rcomp/tmp/3blej1311846943.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/wessaorg/rcomp/tmp/4zn9r1311846943.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] [,12] [1,] 1013.0 816 930.0 1209 1333 1271.0 1023.0 827 620.0 382 424 496.0 [2,] 2325.0 2098 2170.0 2397 2521 2449.0 2170.0 2046 1860.0 1664 1695 1850.0 [3,] 3466.5 3374 3363.5 3534 3658 3606.5 3399.5 3281 3027.5 2904 2976 3115.5 [4,] 4702.0 4660 4578.0 4660 4733 4712.0 4474.0 4371 4268.0 4185 4175 4237.0 [5,] 5115.0 5105 5094.0 5074 5280 5270.0 5115.0 5012 5022.0 5022 5032 5053.0 $n [1] 10 10 10 10 10 10 10 10 10 10 10 10 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 2278.856 2093.923 2160.367 2403.315 2552.797 2475.815 2248.33 2119.337 [2,] 4654.144 4654.077 4566.633 4664.685 4763.203 4737.185 4550.67 4442.663 [,9] [,10] [,11] [,12] [1,] 1824.367 1644.408 1736.893 1922.86 [2,] 4230.633 4163.592 4215.107 4308.14 $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(1013, 2325, 3466.5, 4702, 5115, 816, 2098, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/5n5t81311846943.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] [,10] [,11] [1,] 5012 4629.0 4175.0 3503.0 3121.0 2687.0 2139.0 1664 837 382.0 NA [2,] 5027 4706.5 4252.5 3596.0 3291.0 2852.0 2340.5 1855 1064 558.0 NA [3,] 5084 4903.5 4526.0 3999.0 3549.5 3188.0 2697.0 2134 1617 878.5 NA [4,] 5115 5006.5 4681.0 4169.5 3658.0 3342.5 2945.0 2361 1901 1116.0 NA [5,] 5115 5105.0 4733.0 4288.0 3844.0 3472.0 3079.0 2521 2036 1333.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,] 5043.863 4766.668 4330.558 3737.423 3382.109 2964.28 2421.283 1903.21 [2,] 5124.137 5040.332 4721.442 4260.577 3716.891 3411.72 2972.717 2364.79 [,9] [,10] [,11] [1,] 1235.239 623.9925 NA [2,] 1998.761 1133.0075 NA $out [1] 5280 5270 $group [1] 1 1 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" NA Warning message: In bxp(list(stats = c(5012, 5027, 5084, 5115, 5115, 4629, 4706.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/6ujhv1311846943.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,] 1319.098 3865.0 1961.250 [2,] 1371.037 4045.5 2020.125 [3,] 1414.621 4174.5 2096.500 [4,] 1510.653 4479.5 2167.500 [5,] 1571.815 4640.0 2288.250 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 1350.941 3976.55 2029.281 [2,] 1478.300 4372.45 2163.719 $out numeric(0) $group numeric(0) $names [1] "S.D." "Range" "IQR" Warning message: In bxp(list(stats = c(1319.09760400392, 1371.03726892136, 1414.62059223734, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/10l6s1311846943.ps tmp/10l6s1311846943.png",intern=TRUE)) character(0) > try(system("convert tmp/2lr1l1311846943.ps tmp/2lr1l1311846943.png",intern=TRUE)) character(0) > try(system("convert tmp/3blej1311846943.ps tmp/3blej1311846943.png",intern=TRUE)) character(0) > try(system("convert tmp/4zn9r1311846943.ps tmp/4zn9r1311846943.png",intern=TRUE)) character(0) > try(system("convert tmp/5n5t81311846943.ps tmp/5n5t81311846943.png",intern=TRUE)) character(0) > try(system("convert tmp/6ujhv1311846943.ps tmp/6ujhv1311846943.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.363 0.274 1.640