deviance: 'deviance' returns the deviance based on the conditional...

View source: R/deviance.R

devianceR Documentation

deviance returns the deviance based on the conditional likelihood associated with the survival part.

Description

deviance returns the deviance based on the conditional likelihood associated with the survival part.

Usage

deviance(object, M = 1000, conditional = "survival", verbose = TRUE)

Arguments

object

an object inheriting from class 'BQt'.

M

an integer indicating the number of draws used for the approximation of the integral with respect to random effects, M=1000 by default.

conditional

is "survival" by default because only this one is implemented until now.

verbose

A logical indicating if information about method's progress (included progress bars for each step) must be printed (default to TRUE). Adds a small extra overload.

Value

An object which is a list with the following elements:

deviance

Numerical object returning the deviance

likelihood

(Conditional) likelihood

sims.list

list of individual quantities like likelihood, draws of random effects, hazard and survival functions

control

list of arguments giving details about the deviance

Author(s)

Antoine Barbieri and Baptiste Courrèges

Examples


## Not run: 
data("aids", package = "joineR")

#---- Fit quantile regression joint model for the first quartile
qrjm_5 <- qrjm.BQt(formFixed = CD4 ~ obstime,
                   formRandom = ~ obstime,
                   formGroup = ~ id,
                   formSurv = Surv(time, death) ~ drug + gender + prevOI + AZT,
                   survMod = "weibull",
                   n.iter = 1000,
                   n.burnin = 500,
                   n.thin = 1,
                   n.adapt = 500,
                   param = "value",
                   timeVar= "obstime", save_va = TRUE, parallel = TRUE,
                   data = aids,
                   tau = 0.5)

deviance(qrjm_5, M=200)

## End(Not run)


AntoineBbi/BQt documentation built on June 25, 2022, 3:32 p.m.