[R] BUGS

stephen sefick ssefick at gmail.com
Wed Aug 19 19:13:20 CEST 2009


Naively it seems that there is no school.txt file in your specified directory.

Stephen Sefick

On Wed, Aug 19, 2009 at 12:05 PM, James
Lenihan<jameslenihan at sbcglobal.net> wrote:
>
> I am running a BUGS function with following
>
> schools.sim <-bugs(data,inits,
>                              parameters,
>                              model.file="schools.txt",
>                              n.chains=3,
>                              n.iter=1000,
>                              bugs.directory="E:/Rprograms")
>
> My model.file IS in the directory ="E:/Rprograms" and the code is:
>
> model{
>     for (j in 1:J){
>             y[j] ~ dnorm (theta[j], tau.y[j])
>             theta[j] ~ dnorm (mu.theta, tau.theta)
>             tau.y[j] <- pow(sigma.y[j], -2)
>     }
>     mu.theta ~ dnorm (0.0, 1.0E-6)
>     tau.theta <- pow(sigma.theta, -2)
>     sigma.theta ~ dunif (0, 1000)
>
> I am getting the following error which I can't understand.
>
> Error in bugs(data, inits, parameters, model.file = "schools.txt", n.chains = 3,  :
>   schools.txt does not exist.
>
>        [[alternative HTML version deleted]]
>
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
>



-- 
Stephen Sefick

Let's not spend our time and resources thinking about things that are
so little or so large that all they really do for us is puff us up and
make us feel like gods.  We are mammals, and have not exhausted the
annoying little problems of being mammals.

								-K. Mullis


More information about the R-help mailing list