jmbayesBig | R Documentation |
function for joint model in BIG DATA using JMbayes2
jmbayesBig(
dtlong,
dtsurv,
longm,
survm,
samplesize = 50,
rd,
timeVar,
nchain = 1,
id,
niter = 2000,
nburnin = 1000
)
dtlong |
longitudinal dataset, which contains id,visit time,longitudinal measurements along with various covariates |
dtsurv |
survival dataset corresponding to the longitudinal dataset, with survival status and survival time |
longm |
fixed effect model for longitudinal response |
survm |
survival model |
samplesize |
sample size to divide the Big data |
rd |
random effect model part |
timeVar |
time variable in longitudinal model, included in the longitudinal data |
nchain |
number of chain for MCMC |
id |
name of id column in longitudinal dataset |
niter |
number of iteration for MCMC chain |
nburnin |
number of burnin sample for MCMC chain |
returns a list containing various output which are useful for prediction.
Atanu Bhattacharjee, Bhrigu Kumar Rajbongshi and Gajendra Kumar Vishwakarma
Rizopoulos, D., G. Papageorgiou, and P. Miranda Afonso. "JMbayes2: extended joint models for longitudinal and time-to-event data." R package version 0.2-4 (2022).
jmcsBig,jmstanBig,joinRMLBig
##
library(survival)
library(nlme)
library(dplyr)
fit5<-jmbayesBig(dtlong=long2,dtsurv = surv2,longm=y~ x7+visit,survm=Surv(time,status)~x1+visit,
rd= ~ visit|id,timeVar='visit',nchain=1,samplesize=200,id='id')
ydt<-long2%>%filter(id%in%c(900))
cdt<-surv2[,'id']%>%filter(id%in%c(900))
newdata<-full_join(ydt,cdt,by='id')
P2<-predJMbayes(model<-fit5,ids<-c(900),newdata=newdata,process = 'event')
plot(P2$p1[[1]])
##
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.