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(940,1070,1060,1070,1070,1040,950,1120,1150,1040,1040,1120,1000,960,1060,1060,1110,1030,960,1130,1150,1030,1040,1030,1070,1000,1020,1100,1080,990,1000,1110,1170,1030,1100,1020,1090,990,1060,1120,1030,1050,1030,1130,1140,980,1150,990,1020,1060,1080,1180,980,960,1020,1170,1150,950,1160,1120,1010,1010,1060,1130,1000,1000,1070,1150,1080,980,1210,1020,980,1030,1050,1190,970,950,1070,1170,1050,960,1300,1080,1030,1030,1070,1260,990,950,1080,1190,1050,950,1250,1140,1080,1020,1140,1320,1100,1040,1090,1280,1030,930,1280,1020) > 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] 108 > (np <- floor(n / par1)) [1] 9 > 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] 9 9 9 9 9 9 9 9 9 9 9 9 > arr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] 940 1000 1070 1090 1020 1010 980 1030 1080 NA [2,] 1070 960 1000 990 1060 1010 1030 1030 1020 NA [3,] 1060 1060 1020 1060 1080 1060 1050 1070 1140 NA [4,] 1070 1060 1100 1120 1180 1130 1190 1260 1320 NA [5,] 1070 1110 1080 1030 980 1000 970 990 1100 NA [6,] 1040 1030 990 1050 960 1000 950 950 1040 NA [7,] 950 960 1000 1030 1020 1070 1070 1080 1090 NA [8,] 1120 1130 1110 1130 1170 1150 1170 1190 1280 NA [9,] 1150 1150 1170 1140 1150 1080 1050 1050 1030 NA [10,] 1040 1030 1030 980 950 980 960 950 930 NA [11,] 1040 1040 1100 1150 1160 1210 1300 1250 1280 NA [12,] 1120 1030 1020 990 1120 1020 1080 1140 1020 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] 130 -40 -70 -100 40 0 50 0 -60 NA [2,] -10 100 20 70 20 50 20 40 120 NA [3,] 10 0 80 60 100 70 140 190 180 NA [4,] 0 50 -20 -90 -200 -130 -220 -270 -220 NA [5,] -30 -80 -90 20 -20 0 -20 -40 -60 NA [6,] -90 -70 10 -20 60 70 120 130 50 NA [7,] 170 170 110 100 150 80 100 110 190 NA [8,] 30 20 60 10 -20 -70 -120 -140 -250 NA [9,] -110 -120 -140 -160 -200 -100 -90 -100 -100 NA [10,] 0 10 70 170 210 230 340 300 350 NA [11,] 80 -10 -80 -160 -40 -190 -220 -110 -260 NA [12,] -120 40 70 30 -110 -40 -50 -60 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/wessaorg/rcomp/tmp/19c1p1313167599.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/2bf1v1313167599.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/3qkw21313167599.ps",horizontal=F,onefile=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/wessaorg/rcomp/tmp/40wep1313167599.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,] 940 960 1050 1060 970 950 950 1110 1030 930 1040 990 [2,] 1000 1000 1060 1100 990 960 1000 1130 1050 950 1100 1020 [3,] 1020 1020 1060 1130 1030 1000 1030 1150 1140 980 1160 1030 [4,] 1070 1030 1070 1190 1080 1040 1070 1170 1150 1030 1250 1120 [5,] 1090 1070 1080 1320 1110 1050 1090 1190 1170 1040 1300 1140 $n [1] 9 9 9 9 9 9 9 9 9 9 9 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 983.1333 1004.2 1054.733 1082.6 982.6 957.8667 993.1333 1128.933 [2,] 1056.8667 1035.8 1065.267 1177.4 1077.4 1042.1333 1066.8667 1171.067 [,9] [,10] [,11] [,12] [1,] 1087.333 937.8667 1081 977.3333 [2,] 1192.667 1022.1333 1239 1082.6667 $out [1] 1020 1140 1280 $group [1] 3 3 8 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(940, 1000, 1020, 1070, 1090, 960, 1000, 1020, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/5qmpm1313167599.ps",horizontal=F,onefile=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,] -100 -10 0 -270 -90 -90 80 -250 -200 0 -260 -120 [2,] -60 20 60 -220 -60 -20 100 -120 -140 70 -190 -85 [3,] 0 40 80 -130 -30 50 110 -20 -110 210 -110 -45 [4,] 40 70 140 -20 -20 70 170 20 -100 300 -40 35 [5,] 130 120 190 50 20 130 190 60 -90 350 80 70 $n [1] 9 9 9 9 9 9 9 9 9 9 9 8 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -52.66667 13.66667 37.86667 -235.33333 -51.066667 2.6 73.13333 [2,] 52.66667 66.33333 122.13333 -24.66667 -8.933333 97.4 146.86667 [,8] [,9] [,10] [,11] [,12] [1,] -93.73333 -131.06667 88.86667 -189 -112.03372 [2,] 53.73333 -88.93333 331.13333 -31 22.03372 $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(-100, -60, 0, 40, 130, -10, 20, 40, 70, 120, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/68evq1313167599.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] [1,] 1040 960 990 980 950 980 950 950 930 NA [2,] 1040 1015 1010 1010 1000 1005 975 1010 1025 NA [3,] 1065 1035 1050 1055 1070 1040 1050 1060 1085 NA [4,] 1095 1085 1100 1125 1155 1105 1125 1165 1210 NA [5,] 1150 1150 1170 1150 1180 1210 1300 1260 1320 NA $n [1] 12 12 12 12 12 12 12 12 12 0 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [1,] 1039.914 1003.073 1008.95 1002.548 999.3035 994.3893 981.584 989.3035 [2,] 1090.086 1066.927 1091.05 1107.452 1140.6965 1085.6107 1118.416 1130.6965 [,9] [,10] [1,] 1000.62 NA [2,] 1169.38 NA $out [1] 940 950 $group [1] 1 1 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" NA Warning message: In bxp(list(stats = c(1040, 1040, 1065, 1095, 1150, 960, 1015, 1035, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/73mgy1313167599.ps",horizontal=F,onefile=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,] 983.3333 980 990.0 [2,] 1021.6667 1020 1025.0 [3,] 1048.3333 1030 1050.0 [4,] 1133.3333 1135 1122.5 [5,] 1170.0000 1160 1175.0 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 997.4014 977.5477 1005.53 [2,] 1099.2652 1082.4523 1094.47 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(983.333333333333, 1021.66666666667, 1048.33333333333, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/19c1p1313167599.ps tmp/19c1p1313167599.png",intern=TRUE)) character(0) > try(system("convert tmp/2bf1v1313167599.ps tmp/2bf1v1313167599.png",intern=TRUE)) character(0) > try(system("convert tmp/3qkw21313167599.ps tmp/3qkw21313167599.png",intern=TRUE)) character(0) > try(system("convert tmp/40wep1313167599.ps tmp/40wep1313167599.png",intern=TRUE)) character(0) > try(system("convert tmp/5qmpm1313167599.ps tmp/5qmpm1313167599.png",intern=TRUE)) character(0) > try(system("convert tmp/68evq1313167599.ps tmp/68evq1313167599.png",intern=TRUE)) character(0) > try(system("convert tmp/73mgy1313167599.ps tmp/73mgy1313167599.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.673 0.364 2.033