R version 2.10.1 (2009-12-14) Copyright (C) 2009 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. > library(coda) Loading required package: lattice > > S<-11000 ; burn<-1000 ; odens<-1 > > R0<-6 > KS<-8 > seeds<- 1:10 + (KS-1)*10 > MS<-NULL > > for(seed in seeds) + { + set.seed(seed) + source("datagen.r") # generate data + for(R in 1:8) # for each presumed rank + { + source("hbayes.r") + mse<-c(mean(Y^2), # size of matrix + mean((Y-M0)^2), # MSE of Y + mean((Y-M.ps/nss)^2) , # RSS of mean + mean((M0-M.ps/nss)^2), # MSE of of mean + mean((Y-M.mode)^2) , # RSS of mode + mean((M0-M.mode)^2), # MSE of mode + mean((Y-M.ols)^2), # RSS of ols + mean((M0-M.ols)^2)) # MSE of ols + cat(seed,R,round(100*mse,3)," ",round(DIC,2),"\n") + MS<-rbind(MS,c(seed,R,mse,DIC,eSS)) + } + dput(MS,paste("hbayes.SS",KS,".R0",R0,".results",sep="")) + } 71 1 126.02 23.783 55.32 29.225 55.457 29.331 55.336 29.269 1126.1 71 2 126.02 23.783 30.108 9.565 30.255 9.651 30.033 9.829 881.2 71 3 126.02 23.783 22.971 5.718 23.228 5.809 22.737 6.445 798.91 71 4 126.02 23.783 20.298 4.809 21.14 4.904 19.965 6.364 796.12 71 5 126.02 23.783 19.049 4.651 20.766 4.737 17.481 8.188 796.63 71 6 126.02 23.783 17.918 4.674 20 4.755 15.195 10.167 800.47 71 7 126.02 23.783 16.394 4.798 18.723 4.731 13.043 12.541 807.68 71 8 126.02 23.783 15.123 4.967 17.725 4.88 11.233 13.533 810.37 72 1 129.264 24.972 24.796 3.075 24.805 3.076 24.793 3.118 740.01 72 2 129.264 24.972 22.02 3.019 23.19 3.101 22.039 5.289 744.15 72 3 129.264 24.972 19.675 3.212 22.215 3.1 19.588 7.736 752.03 72 4 129.264 24.972 18.231 3.352 21.049 3.261 17.228 8.929 749.68 72 5 129.264 24.972 17.909 3.277 20.318 3.186 14.922 11.176 746.07 72 6 129.264 24.972 16.292 3.711 18.725 3.649 13.062 12.893 747.66 72 7 129.264 24.972 13.484 4.916 16.362 4.803 11.164 14.631 752.85 72 8 129.264 24.972 11.633 5.896 14.8 5.686 9.675 16.014 761.86 73 1 121.132 23.264 37.17 16.668 37.213 16.699 37.181 16.685 934.82 73 2 121.132 23.264 21.855 4.411 21.911 4.427 21.652 4.629 727.35 73 3 121.132 23.264 19.744 4.139 21.109 4.314 19.329 6.511 733.15 73 4 121.132 23.264 17.953 4.138 19.899 4.01 17.21 7.71 737.71 73 5 121.132 23.264 17.214 4.07 19.172 3.968 15.307 9.75 733.25 73 6 121.132 23.264 16.746 4.104 18.739 4.012 13.474 11.33 733.1 73 7 121.132 23.264 16.189 4.192 18.045 4.131 11.724 12.955 735.1 73 8 121.132 23.264 13.109 5.078 15.992 4.856 10.133 13.954 754.41 74 1 128.628 25.776 39.482 18.065 39.532 18.101 39.482 18.2 963.66 74 2 128.628 25.776 26.201 6.081 26.327 6.094 26.148 6.075 815.33 74 3 128.628 25.776 22.293 3.99 22.792 4.044 22.083 4.745 785.5 74 4 128.628 25.776 20.046 4.128 22.438 4.042 19.716 7.142 800.28 74 5 128.628 25.776 18.652 4.211 21.777 4.082 17.475 8.891 804.06 74 6 128.628 25.776 17.681 4.303 20.552 4.173 15.022 11.961 806.28 74 7 128.628 25.776 16.978 4.452 19.631 4.363 12.873 13.417 805.59 74 8 128.628 25.776 15.058 4.966 17.793 4.822 11.03 15.078 816.57 75 1 127.069 26.098 35.901 11.768 35.937 11.791 35.899 11.831 917.7 75 2 127.069 26.098 25.108 3.456 25.242 3.477 25.087 3.734 793.5 75 3 127.069 26.098 22.153 3.234 23.574 3.326 22.052 6.804 794.69 75 4 127.069 26.098 20.695 3.333 22.455 3.272 19.067 7.984 789 75 5 127.069 26.098 18.936 3.685 21.207 3.618 16.801 10.282 787.6 75 6 127.069 26.098 18.602 3.724 20.513 3.684 14.639 12.016 786.88 75 7 127.069 26.098 14.999 5.099 17.164 4.992 12.5 14.012 789.7 75 8 127.069 26.098 15.25 4.862 17.594 4.709 10.745 16.047 787.42 76 1 123.635 22.124 23.665 3.327 23.674 3.329 23.665 3.358 717.57 76 2 123.635 22.124 20.396 2.47 20.733 2.505 20.248 2.799 694.16 76 3 123.635 22.124 19.009 2.362 20.259 2.35 18.288 4.719 700.19 76 4 123.635 22.124 17.866 2.397 19.626 2.379 16.271 6.708 703.35 76 5 123.635 22.124 16.932 2.522 18.78 2.485 14.438 8.506 706.28 76 6 123.635 22.124 15.802 2.693 17.898 2.638 12.705 10.164 713 76 7 123.635 22.124 14.21 3.03 16.978 2.886 11.059 11.776 724.91 76 8 123.635 22.124 15.12 2.797 16.954 2.738 9.559 13.303 712 77 1 128.182 27.677 45.459 21.787 45.518 21.827 45.467 21.851 1031.42 77 2 128.182 27.677 35.159 12.804 36.492 13.806 35.838 13.81 978.62 77 3 128.182 27.677 26.108 5.683 26.426 5.736 25.894 5.918 861.74 77 4 128.182 27.677 23.687 5.276 25.698 5.458 22.886 7.75 866.69 77 5 128.182 27.677 21.242 5.368 23.62 5.422 20.251 9.179 871.11 77 6 128.182 27.677 20.057 5.442 22.308 5.41 17.995 11.067 872.77 77 7 128.182 27.677 19.038 5.582 21.725 5.578 15.886 12.949 876.32 77 8 128.182 27.677 17.083 5.984 20.495 5.793 13.423 15.09 888.16 78 1 129.507 23.381 34.557 12.979 34.588 12.999 34.56 13.095 899.5 78 2 129.507 23.381 26.283 6.962 26.645 7.149 26.079 6.991 822.75 78 3 129.507 23.381 21.032 4.351 21.697 4.468 21.053 5.093 773.4 78 4 129.507 23.381 19.468 4.181 20.495 4.239 18.777 5.784 767.2 78 5 129.507 23.381 18.537 4.101 19.878 4.097 16.783 7.791 770.53 78 6 129.507 23.381 16.703 4.342 19.213 4.283 14.87 9.822 784.65 78 7 129.507 23.381 15.783 4.463 18.609 4.389 12.926 11.321 790.03 78 8 129.507 23.381 15.319 4.488 17.79 4.46 11.159 13.111 790.76 79 1 122.697 27.273 27.1 1.603 27.11 1.604 27.095 1.539 782.59 79 2 122.697 27.273 24.633 1.638 26.22 1.692 24.259 4.365 788.85 79 3 122.697 27.273 22.76 1.827 24.948 1.767 21.417 7.076 790.74 79 4 122.697 27.273 19.504 2.761 22.123 2.608 18.903 9.666 796.36 79 5 122.697 27.273 18.462 2.958 21.044 2.821 16.54 11.271 793.21 79 6 122.697 27.273 17.868 3.106 20.166 2.979 14.283 13.339 789.53 79 7 122.697 27.273 16.298 3.711 18.877 3.542 12.33 15.265 791.62 79 8 122.697 27.273 15.636 3.973 17.863 3.832 10.66 16.924 789.95 80 1 137.609 28.589 28.941 3.308 28.952 3.311 28.936 3.445 814.15 80 2 137.609 28.589 25.799 2.686 26.74 2.718 25.58 4.497 812.16 80 3 137.609 28.589 23.595 2.832 25.664 2.792 22.917 6.807 817.82 80 4 137.609 28.589 21.369 3.13 24.786 3.011 20.26 9.443 822.51 80 5 137.609 28.589 21.265 3.053 23.846 2.947 17.61 12.043 817.23 80 6 137.609 28.589 18.075 3.943 21.226 3.759 15.149 14.588 824.51 80 7 137.609 28.589 18.388 3.715 21.073 3.576 13.084 16.427 822.76 80 8 137.609 28.589 15.004 5.183 18.094 4.956 11.189 18.224 828.14 > > > >