I am unable to get the prior predictive distribution. Here is the reproducible code:
df = pd.read_csv('https://raw.githubusercontent.com/aloctavodia/Statistical-Rethinking-with-Python-and-PyMC3/master/Data/Howell1.csv',sep=';')
with pm.Model() as m4_3:
alpha = pm.Normal('alpha', mu=178, sd=100)
beta = pm.Normal('beta', mu=0, sd=10)
sigma = pm.Uniform('sigma', lower=0, upper=50)
mu = pm.Deterministic('mu', alpha + beta * (df.weight - df.weight.mean() )) # try uncomenting this line and comenting the above line
height = pm.Normal('height', mu=mu, sd=sigma)
trace_4_3 = pm.sample(1000, tune=1000)
I get
The error when converting the test value to that variable type:
Wrong number of dimensions: expected 0, got 1 with shape (544,).
beause I have put in a input of weight in beta, but not output of height. How do I generate Prior predicitive for this model?