Description Usage Arguments Value Examples
The core function to compute the total likelihood of the joint model given the selected marginal distribution for the multivariate count outcome and the dataset
1 |
params |
A vector of fixed effect and standard deviations of the random effects. |
method |
An argument of either "dirmult" or "multl" defining the marginal distribution of the multivariate count outcome. |
data |
A complete observation for all subjects including the multivariate count outcome, the covariates and the continuous outcomes for two time points. |
The total loglikelihood values for the given parameters values.
1 2 3 4 5 6 7 8 9 | # params should be in the format of params = {betas_C, betas_Y,uC's, uS's,theta or rho,uY,ev}, where
# The following example is for the multinomial logistics mixed model
betas_C <- c(0.5,3.5,1.3,0.8,0.15)
betas_Y <- c(2.3,0.1)
uC<- c(1,0.8)
uS <- c(0.5,0.6)
uY <- 0.9; ev <- 0.7; rho <- 0.1;
params <- c(betas_C,betas_Y, uC,uS,rho,uY,ev)
ll <- loglik(params,method = "multl",data)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.