Thank you very much! I will try this out! The thing is that the total amount of money is changing. So, I guess I should make n_pennies the total number of dollars. (This can be a decimal) and observed the amount of money spent on one good?
I am actually not sure this would work. The amount given to a particular good is like a sloped line. So one dollar change in good one will result in a slope dollar change in the other good. Since this slope changes randomly, I am not sure how n_pennies can be known, unless I may n_pennies something constant. I guess I will put it as amount to one specific good.
Once I have this, how can I use the MAP to predict on test data?
I changed to use the pm.Data so that I can set the data like this?
with model_others:
pm.set_data({"slopes": test_x_values, "subject_id":subject_id_test, "n_tokens":test_n_tokens})
post_pred = pm.sample_posterior_predictive(trace_new, samples=10000)
predicted = pd.DataFrame(post_pred['obs']).mode(axis=0).mean().values/test_n_tokens
actual = test_y_discrete/test_n_tokens
With Bayesian methods, how do people generally asset predictive ability? I know AIC and BIC are used, but do people tend to use R^2 over MSE?
This method seems to be much slower than previous methods and I actually seem to obtain a worse R^2.
Thank you so much!