t;- numeric(n)
>
> and then see how fast it works.
>
> On Sun, Nov 8, 2009 at 2:11 PM, Jens Malmros wrote:
>> Hello,
>>
>> I have written a simple Metropolis-Hastings MCMC algorithm for a
>> binomial parameter:
>>
>> MHastings = function(n,p0,d){
&g
Hello,
I have written a simple Metropolis-Hastings MCMC algorithm for a
binomial parameter:
MHastings = function(n,p0,d){
theta = c()
theta[1] = p0
t =1
while(t<=n){
phi = log(theta[t]/(1-theta[t]))
phisim = phi + rnorm(1,0,d)
2 matches
Mail list logo