# Multivariate relationship between categorical and beta-distributed dependent variables

Dear Stan Community,

I am figuring out how to model a relationship between two dependent variables, where one of them is categorical (in a simplest case, binary), and the second bounded and continuous (Beta-distributed).

To be more concrete, I want to model the influence of common and unique factors on choices C (binary) and confidence ratings R (continuous, bounded between (0,1)), assuming that they are generated from a common underlying latent value.

Let’s assume that the two outcomes C and R are both generated from V, representing latent value. Additionally, they are both influenced by unique factors: F_C and F_D, such that:
C = f(V, F_C)
R = f(V, F_R)

In separation, we can model choices using a Bernoulli, and the ratings using a Beta distribution:
C \sim Bern(\beta_{1}V + \beta_{2}F_C)
R \sim Beta(\mu=\beta_{3}V + \beta_{4}F_R, \kappa)
(NOTE: Beta here is parametrized using mean \mu and dispersion \kappa)

This however does not fully capture the interdependency between the two outcome variables. I’d like to have a single likelihood function, assuming a joint distribution of choices and ratings, something like:
p(C, R |V, F_C, F_R)

Please correct me if I’m wrong, but am I correct in thinking that copulas are a tool that can achieve this? And if so, does anyone have any specific tips for implementing this?

Thanks for any feedback you can offer!