var P = function() {
return flip(theta) ? 'a' : 'b';
}
var fn = function() {
return sample(Beta({a: 1, b: 1}))
}
//var x = sample(Beta({a: 1, b: 1}));
var theta = 0.1;
theta;
var dist = Infer(
{method: 'MCMC', kernel: 'MH', samples: 1000},
P);
viz.auto(dist)
This code runs fine but when I uncomment the line initializing x, the code gives an error 'theta is not defined' . I am not sure how/why this is happening. Apologies if it isn't a bug.
This code runs fine but when I uncomment the line initializing x, the code gives an error
'theta is not defined'. I am not sure how/why this is happening. Apologies if it isn't a bug.