Modelling Categorial Variable

Hi Alex,

thanks for you reply! I added some comments above, maybe that makes the DGP and the model a bit clearer.

My main problem is that I do not understand why pm.Categorial can’t deal with 0 probabilites in pm_data_prob. And even if I add 0.01 to each element, sampling is extremely slow.

On your points:

  • ValueError: Any problems must come from the last part (pm_preference_lat). If I simulate 3000 observations, pm_data_prob has the shape (3000,11) and data_simulated_rev (3000,). Sampling like this work (if I guarantee strictly positive probabilites for each choice), but extremely slow.

  • Priors: The uniform priors with range (-10,10) actually work fine, I get posteriors quite close around the true values for pm_a, pm_b and the 10 elements of pm_p_slots_avail. For the Dirichlet-Prior of pm_preference_lat I may only vary “a” or use other starting values?

  • Yep, the pm_-prefix is probably not such a good idea, I somehow needed to distinguish the simulation variables from the pymc3-variables. I’ll change that.