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. 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(121.67,121.65,121.61,121.5,121.41,121.41,121.4,121.38,121.34,121.19,120.96,120.96,120.96,120.9,120.86,120.73,120.53,120.53,120.53,120.52,120.51,120.43,120.29,120.27,120.27,120.24,120.21,120.06,119.86,119.85,119.85,119.83,119.71,119.57,119.2,119.13,119.13,119.09,118.9,118.54,118.12,118.11,118.1,118.08,117.91,117.63,117.28,117.2,117.17,117.14,116.96,116.34,115.99,115.99,115.97,115.92,115.63,115.31,115.13,115.09,115.07,115.01,114.64,113.86,113.34,113.33,113.32,113.26,113.2,112.61,112.28,112.16) > 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] 72 > (np <- floor(n / par1)) [1] 6 > 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 6 6 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 121.67 120.96 120.27 119.13 117.17 115.07 NA [2,] 121.65 120.90 120.24 119.09 117.14 115.01 NA [3,] 121.61 120.86 120.21 118.90 116.96 114.64 NA [4,] 121.50 120.73 120.06 118.54 116.34 113.86 NA [5,] 121.41 120.53 119.86 118.12 115.99 113.34 NA [6,] 121.41 120.53 119.85 118.11 115.99 113.33 NA [7,] 121.40 120.53 119.85 118.10 115.97 113.32 NA [8,] 121.38 120.52 119.83 118.08 115.92 113.26 NA [9,] 121.34 120.51 119.71 117.91 115.63 113.20 NA [10,] 121.19 120.43 119.57 117.63 115.31 112.61 NA [11,] 120.96 120.29 119.20 117.28 115.13 112.28 NA [12,] 120.96 120.27 119.13 117.20 115.09 112.16 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -0.02 -0.06 -0.03 -0.04 -0.03 -0.06 NA [2,] -0.04 -0.04 -0.03 -0.19 -0.18 -0.37 NA [3,] -0.11 -0.13 -0.15 -0.36 -0.62 -0.78 NA [4,] -0.09 -0.20 -0.20 -0.42 -0.35 -0.52 NA [5,] 0.00 0.00 -0.01 -0.01 0.00 -0.01 NA [6,] -0.01 0.00 0.00 -0.01 -0.02 -0.01 NA [7,] -0.02 -0.01 -0.02 -0.02 -0.05 -0.06 NA [8,] -0.04 -0.01 -0.12 -0.17 -0.29 -0.06 NA [9,] -0.15 -0.08 -0.14 -0.28 -0.32 -0.59 NA [10,] -0.23 -0.14 -0.37 -0.35 -0.18 -0.33 NA [11,] 0.00 -0.02 -0.07 -0.08 -0.04 -0.12 NA [12,] 0.00 0.00 0.00 -0.03 -0.02 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/13xfk1272293995.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/23xfk1272293995.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/33xfk1272293995.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/4w6wn1272293995.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] [1,] 115.07 115.010 114.640 113.86 113.34 113.33 113.320 113.260 113.20 112.61 [2,] 117.17 117.140 116.960 116.34 115.99 115.99 115.970 115.920 115.63 115.31 [3,] 119.70 119.665 119.555 119.30 118.99 118.98 118.975 118.955 118.81 118.60 [4,] 120.96 120.900 120.860 120.73 120.53 120.53 120.530 120.520 120.51 120.43 [5,] 121.67 121.650 121.610 121.50 121.41 121.41 121.400 121.380 121.34 121.19 [,11] [,12] [1,] 112.28 112.160 [2,] 115.13 115.090 [3,] 118.24 118.165 [4,] 120.29 120.270 [5,] 120.96 120.960 $n [1] 6 6 6 6 6 6 6 6 6 6 6 6 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 117.2553 117.2397 117.0394 116.4683 116.0616 116.0516 116.0337 115.9879 [2,] 122.1447 122.0903 122.0706 122.1317 121.9184 121.9084 121.9163 121.9221 [,9] [,10] [,11] [,12] [1,] 115.6622 115.2974 114.9116 114.8237 [2,] 121.9578 121.9026 121.5684 121.5063 $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(115.07, 117.17, 119.7, 120.96, 121.67, 115.01, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/5w6wn1272293995.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] [1,] -0.060 -0.37 -0.780 -0.520 -0.010 -0.02 -0.06 -0.29 -0.320 -0.37 -0.120 [2,] -0.060 -0.19 -0.620 -0.420 -0.010 -0.01 -0.05 -0.17 -0.320 -0.35 -0.080 [3,] -0.035 -0.11 -0.255 -0.275 -0.005 -0.01 -0.02 -0.09 -0.215 -0.28 -0.055 [4,] -0.030 -0.04 -0.130 -0.200 0.000 0.00 -0.02 -0.04 -0.140 -0.18 -0.020 [5,] -0.020 -0.03 -0.110 -0.090 0.000 0.00 -0.01 -0.01 -0.080 -0.14 0.000 [,12] [1,] -0.03 [2,] -0.02 [3,] 0.00 [4,] 0.00 [5,] 0.00 $n [1] 6 6 6 6 6 6 6 6 6 6 6 5 $conf [,1] [,2] [,3] [,4] [,5] [,6] [1,] -0.05435097 -0.20675484 -0.57106583 -0.4169071 -0.011450323 -0.016450323 [2,] -0.01564903 -0.01324516 0.06106583 -0.1330929 0.001450323 -0.003549677 [,7] [,8] [,9] [,10] [,11] [,12] [1,] -0.039350969 -0.173854199 -0.33110581 -0.3896555 -0.09370194 -0.01413195 [2,] -0.000649031 -0.006145801 -0.09889419 -0.1703445 -0.01629806 0.01413195 $out [1] -0.59 $group [1] 9 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-0.0599999999999881, -0.0599999999999881, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/6ofwq1272293995.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] [1,] 120.960 120.270 119.130 117.200 115.09 112.160 NA [2,] 121.265 120.470 119.640 117.770 115.47 112.905 NA [3,] 121.405 120.530 119.850 118.105 115.98 113.325 NA [4,] 121.555 120.795 120.135 118.720 116.65 114.250 NA [5,] 121.670 120.960 120.270 119.130 117.17 115.070 NA $n [1] 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] 121.2727 120.3818 119.6242 117.6717 115.4418 112.7115 NA [2,] 121.5373 120.6782 120.0758 118.5383 116.5182 113.9385 NA $out numeric(0) $group numeric(0) $names [1] "1" "2" "3" "4" "5" "6" NA Warning message: In bxp(list(stats = c(120.96, 121.265, 121.405, 121.555, 121.67, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/7ofwq1272293995.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,] 117.4683 118.1650 117.8012 [2,] 117.9200 118.7050 118.1538 [3,] 118.1992 118.9775 118.4356 [4,] 118.6842 119.4275 118.8987 [5,] 119.0450 119.7000 119.2237 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 117.8506 118.6480 118.0958 [2,] 118.5477 119.3070 118.7754 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(117.468333333333, 117.92, 118.199166666667, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/13xfk1272293995.ps tmp/13xfk1272293995.png",intern=TRUE)) character(0) > try(system("convert tmp/23xfk1272293995.ps tmp/23xfk1272293995.png",intern=TRUE)) character(0) > try(system("convert tmp/33xfk1272293995.ps tmp/33xfk1272293995.png",intern=TRUE)) character(0) > try(system("convert tmp/4w6wn1272293995.ps tmp/4w6wn1272293995.png",intern=TRUE)) character(0) > try(system("convert tmp/5w6wn1272293995.ps tmp/5w6wn1272293995.png",intern=TRUE)) character(0) > try(system("convert tmp/6ofwq1272293995.ps tmp/6ofwq1272293995.png",intern=TRUE)) character(0) > try(system("convert tmp/7ofwq1272293995.ps tmp/7ofwq1272293995.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.877 1.467 2.272