Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

For hierachical logistic regression why is mu_beta a single number and not a vector in the shape of self.num_pred #3

Open
grechasneak opened this issue Dec 2, 2019 · 0 comments

Comments

@grechasneak
Copy link

In the library the parent distribution mean value for the betas is a single number, but we can use a number of features for our model. Some of those features might have a positive effect and some might be negative, and I am wondering if it is correct to group them all under one mean value

Basically what you have written is:
mu_beta = pm.Normal('mu_beta', mu=0, sd=100)
sigma_beta = pm.HalfNormal('sigma_beta', sd=100)

And my thoughts are that it should be:

mu_beta = pm.Normal('mu_beta', mu=0, sd=100, shape=(self.num_pred,))
sigma_beta = pm.HalfNormal('sigma_beta', sd=100, shape=(self.num_pred,))

So instead of having a single mu_beta for all of the features, each feature has a unique mu_beta.

Let me know what your thoughts are on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant