title: Simple Bayesian Network via Monte Carlo Markov Chain ported to PyMC3
body: <p>I was porting the example of a <a href="https://bugra.github.io/work/notes/2014-05-23/simple-bayesian-network-via-monte-carlo-markov-chain-mcmc-pymc/" rel="nofollow noreferrer">Simple Bayesian Network via Monte Carlo Markov Chain</a> from <code>PyMC2</code> to <code>PyMC3</code> and it works. <br>The result can be found in the following <a href="https://gist.github.com/cs224/9a19b4ba2c7511e317be90c32a4d40d7" rel="nofollow noreferrer">gist</a> on <kbd>GitHub</kbd> in the file  <code>pymc3_rain_sprinkler_grass_simple_bayesian_network.py.</code></p>
  
  <p>I wanted to extend the original example by providing evidence, e.g. that the grass is wet and then let <code>PyMC3</code> give me the answer for questions like "given grass is wet, what is the probability that it has rained?".</p>
  
  <p>It seems that the resulting trace is "constant", e.g. there is no element of randomness in it any more. Have a look at  <code>pymc3_rain_sprinkler_grass_simple_bayesian_network_with_evidence.py</code> in the gist and execute the <code>df.drop_duplicates()</code> to see what I mean.</p>
  
  <p>What am I doing wrong?</p>