I’m trying to find the correlation between “boldness” and “aggression” - what is known as a behavioural syndrome. One of the methods is to fit a multivariate mixed model with boldness and aggression as response variables, and see how much of correlation is partitioned among “between-individuals” vs. “within-individuals”. Boldness (continuous response variable) and aggression (ordinal ranks) were repeatedly assayed on 320 animals (ID) from 12 colonies (colonyID). As individual animals are not independent from their colonies, ID has to be nested within colonyID.
The question is if I can fit a multivariate model with two different response distributions? If I understand correctly, the vignette says different families can be specified as a list. However, when I tried the following formula,
mod<-brm(mvbind(Boldness,Aggression)~Trial+(1|ID/colony),family = c(gaussian,sratio),data=mydata,chains=2,cores=2)
I get the following error message " Error: Argument ‘family’ is invalid".
I’m unable to find an example in the internet where two different response variables with different error structures are used. Or maybe I’m missing something, so I might need a fool’s guide…
My second question is if I can use the brms package to partition the co-variances into between-individual and among-individual variances and co-variances? This has often been done using MCMCglmm, but I would like to use brms because I feel this package is easier to use and easier to diagnose the model. Any help would be much appreciated!