Thanks for your reply, jessegrabowski
The link would be logit.
As there is no single marginal effect as it depends where on the slope we look at. Thus I would need to consider the other coefficients as well. I currently use a very naive approach (where don’t consider other coefficients bar the intercept) just taking
mean_effect = model_fitted.posterior.data_vars[coef].mean().item()
naive_marginal_effect = expit(intercept + 1*mean_effect) - expit(intercept) #for dummy
Multiple ways to go about it with pros and cons (Econometrics - Marginal Effects for Probit and Logit (and Marginal Effects in R) - YouTube)
-Calculate each observations marginal effect
-Marginal Effect of a Representative: Pick some set of of variables and calculate the marginal effect
-Average Marginal Effect (AME): Calculate each observations marginal effect and take the mean
-Marginal Effect at the Mean (MEM): Calculate the average of each variable (like 25% blonde), then get the marginal effect for some hypothetical observation with those mean values.
I’d prefer AME but I fail to program it correctly let alone efficiently in python. That is why I am asking if there was some resources where it i described to how to do it cleanly in a bambi/pymc3/python way like in the article by Andrew Heiss for R, I linked in the original post.