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. 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(900,899,898,896,916,915,900,890,891,891,892,894,896,889,878,883,901,897,881,866,867,866,862,871,865,856,847,859,870,872,856,839,829,825,822,827,822,812,810,816,820,823,810,793,777,772,765,765,753,742,736,740,742,742,728,707,699,696,689,692,673,653,642,648,654,653,630,609,598,601,592,591,568,538,523,530,529,534,513,491,480,478,462,461,437,411,400,405,395,407,385,366,349,343,332,327,306,276,269,268,260,274,247,226,212,199,188,179,155,124,117,116,105,112,86,64,53,42,32,24) > 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)) > 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] 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,] 900 896 865 822 753 673 568 437 306 155 NA [2,] 899 889 856 812 742 653 538 411 276 124 NA [3,] 898 878 847 810 736 642 523 400 269 117 NA [4,] 896 883 859 816 740 648 530 405 268 116 NA [5,] 916 901 870 820 742 654 529 395 260 105 NA [6,] 915 897 872 823 742 653 534 407 274 112 NA [7,] 900 881 856 810 728 630 513 385 247 86 NA [8,] 890 866 839 793 707 609 491 366 226 64 NA [9,] 891 867 829 777 699 598 480 349 212 53 NA [10,] 891 866 825 772 696 601 478 343 199 42 NA [11,] 892 862 822 765 689 592 462 332 188 32 NA [12,] 894 871 827 765 692 591 461 327 179 24 NA > darr [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [1,] -1 -7 -9 -10 -11 -20 -30 -26 -30 -31 NA [2,] -1 -11 -9 -2 -6 -11 -15 -11 -7 -7 NA [3,] -2 5 12 6 4 6 7 5 -1 -1 NA [4,] 20 18 11 4 2 6 -1 -10 -8 -11 NA [5,] -1 -4 2 3 0 -1 5 12 14 7 NA [6,] -15 -16 -16 -13 -14 -23 -21 -22 -27 -26 NA [7,] -10 -15 -17 -17 -21 -21 -22 -19 -21 -22 NA [8,] 1 1 -10 -16 -8 -11 -11 -17 -14 -11 NA [9,] 0 -1 -4 -5 -3 3 -2 -6 -13 -11 NA [10,] 1 -4 -3 -7 -7 -9 -16 -11 -11 -10 NA [11,] 2 9 5 0 3 -1 -1 -5 -9 -8 NA [12,] 2 -6 -5 -12 -19 -23 -24 -21 -24 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/1d7wx1281619425.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/26gdi1281619425.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/36gdi1281619425.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/4h8uk1281619425.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,] 155 124.0 117 116 105 112.0 86 64 53.0 42.0 32.0 24.0 [2,] 437 411.0 400 405 395 407.0 385 366 349.0 343.0 332.0 327.0 [3,] 713 697.5 689 694 698 697.5 679 658 648.5 648.5 640.5 641.5 [4,] 865 856.0 847 859 870 872.0 856 839 829.0 825.0 822.0 827.0 [5,] 900 899.0 898 896 916 915.0 900 890 891.0 891.0 892.0 894.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,] 499.1541 475.1603 465.661 467.1635 460.6711 465.1675 443.6696 421.6703 [2,] 926.8459 919.8397 912.339 920.8365 935.3289 929.8325 914.3304 894.3297 [,9] [,10] [,11] [,12] [1,] 408.6729 407.6736 395.6765 391.6801 [2,] 888.3271 889.3264 885.3235 891.3199 $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(155, 437, 713, 865, 900, 124, 411, 697.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/5h8uk1281619425.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,] -31.0 -15 -2 -11 -4.0 -27.0 -22 -17 -13.0 -16 -9.0 -24 [2,] -30.0 -11 -1 -8 -1.0 -23.0 -21 -14 -6.0 -11 -5.0 -23 [3,] -15.5 -8 5 3 2.5 -18.5 -20 -11 -3.5 -8 -0.5 -19 [4,] -9.0 -6 6 11 7.0 -15.0 -17 -8 -1.0 -4 3.0 -6 [5,] -1.0 -1 12 20 14.0 -13.0 -15 1 3.0 1 9.0 2 $n [1] 10 10 10 10 10 10 10 10 10 10 10 9 $conf [,1] [,2] [,3] [,4] [,5] [,6] [,7] [1,] -25.992437 -10.498199 1.502521 -6.493158 -1.497119 -22.49712 -21.99856 [2,] -5.007563 -5.501801 8.497479 12.493158 6.497119 -14.50288 -18.00144 [,8] [,9] [,10] [,11] [,12] [1,] -13.99784 -5.998199 -11.497479 -4.497119 -27.95333 [2,] -8.00216 -1.001801 -4.502521 3.497119 -10.04667 $out [1] -10 $group [1] 7 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" Warning message: In bxp(list(stats = c(-31, -30, -15.5, -9, -1, -15, -11, -8, -6, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/6h8uk1281619425.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] [,8] [,9] [,10] [,11] [1,] 890.0 862.0 822.0 765.0 689.0 591.0 461 327 179.0 24.0 NA [2,] 891.5 866.5 828.0 774.5 697.5 599.5 479 346 205.5 47.5 NA [3,] 897.0 879.5 851.5 810.0 732.0 636.0 518 390 253.5 95.5 NA [4,] 900.0 892.5 862.0 818.0 742.0 653.0 532 406 271.5 116.5 NA [5,] 900.0 901.0 872.0 823.0 753.0 673.0 568 437 306.0 155.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,] 893.1231 867.6412 835.9924 790.1594 711.7033 611.5983 493.8263 362.6336 [2,] 900.8769 891.3588 867.0076 829.8406 752.2967 660.4017 542.1737 417.3664 [,9] [,10] [,11] [1,] 223.3970 64.02864 NA [2,] 283.6030 126.97136 NA $out [1] 916 915 $group [1] 1 1 $names [1] "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" NA Warning message: In bxp(list(stats = c(890, 891.5, 897, 900, 900, 862, 866.5, 879.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > postscript(file="/var/www/html/freestat/rcomp/tmp/79zcn1281619425.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,] 563.1 640.5 586.0000 [2,] 573.4 648.5 596.5625 [3,] 607.8 684.0 632.5000 [4,] 619.6 697.5 643.4375 [5,] 637.5 713.0 662.0000 $n [1] 12 12 12 $conf [,1] [,2] [,3] [1,] 586.7279 661.6508 611.12 [2,] 628.8721 706.3492 653.88 $out numeric(0) $group numeric(0) $names [1] "mean" "median" "midrange" Warning message: In bxp(list(stats = c(563.1, 573.4, 607.8, 619.6, 637.5, 640.5, : some notches went outside hinges ('box'): maybe set notch=FALSE > dev.off() null device 1 > > try(system("convert tmp/1d7wx1281619425.ps tmp/1d7wx1281619425.png",intern=TRUE)) character(0) > try(system("convert tmp/26gdi1281619425.ps tmp/26gdi1281619425.png",intern=TRUE)) character(0) > try(system("convert tmp/36gdi1281619425.ps tmp/36gdi1281619425.png",intern=TRUE)) character(0) > try(system("convert tmp/4h8uk1281619425.ps tmp/4h8uk1281619425.png",intern=TRUE)) character(0) > try(system("convert tmp/5h8uk1281619425.ps tmp/5h8uk1281619425.png",intern=TRUE)) character(0) > try(system("convert tmp/6h8uk1281619425.ps tmp/6h8uk1281619425.png",intern=TRUE)) character(0) > try(system("convert tmp/79zcn1281619425.ps tmp/79zcn1281619425.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.990 1.506 2.255