Wednesday, May 27, 2009

R on the cluster

Running Bayesian models on Ubuntu using WinBUGS in R. A downside of it is that WinBUGS window will not close automatically. Running the same bugs code using loop works in windows system. Dr. Gleman suggested to use OpenBUGS on Linux system through version=2 option. It allows the code run on back stage. But insalling OpenBUGS on linux is a little bit painful. Before jumping to OpenBUGS, I first tried to run some bugs jobs on HPCC cluster. loading modu R: @brody:~> module unload mvapich @brody:~> module load openmpi @brody:~> module load R @brody:~> R ~> library(Rmpi) # to get a code editor so you can try some code. This is not a good idea. Try code on local #computer may be preferable. > install.packages(Rcmdr) I failed to call it on the cluster. I may let it go and find another route. Now I am going to try JAGA. http://www-fis.iarc.fr/~martyn/software/jags/ It has been suggested to be used in linux. http://www.nabble.com/Re:-R-vs.-Bugs-p18060894.html

Saturday, May 16, 2009

Combine biased and unbiased samples

It appears on Statistical Science V21 N.4 2006 Nov. p517 biased sample: non-random sample/ convenient sample Graves et al (2006) developed a hypergeometric model with a bias parameter to identify the feature-prevalence in a population when convenient samples are used. MCMC was used and the prior on bias parameter was set as lognormal. Graves et al (2006) was on Technometrics.