You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The standard errors reported by default are based on the empirical information matrix, as in `mjoint`. It is of course possible to use bootstrapped standard errors as follows:
Copy file name to clipboardExpand all lines: vignettes/joineRML.Rmd
+8-7Lines changed: 8 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -25,13 +25,14 @@ if (requireNamespace('joineR', quietly = TRUE)) {
25
25
Sys.setenv("OMP_THREAD_LIMIT" = 1)
26
26
Sys.setenv("OMP_NUM_THREADS" = 1)
27
27
options(Ncpus = 1)
28
+
options(cores = 2)
28
29
```
29
30
30
31
# Introduction
31
32
32
33
The `joineRML` package implements methods for analyzing data from *multiple* longitudinal studies in which the responses from each subject consists of time-sequences of repeated measurements and a possibly censored time-to-event outcome. The modelling framework for the repeated measurements is the multivariate linear mixed effects model. The model for the time-to-event outcome is a Cox proportional hazards model with log-Gaussian frailty. Stochastic dependence is captured by allowing the Gaussian random effects of the linear model to be correlated with the frailty term of the Cox proportional hazards model. For full details of the model, please consult the technical vignette by running
The simplest way to explain the concepts of the package is through an example. `joineRML` comes with the data set `heart.valve`. Details of this data can be found in the help file by running the command
43
44
44
-
```{r heart.valve_help, eval=FALSE}
45
+
```{r heart.valve_help, eval=FALSE, purl=FALSE}
45
46
help("heart.valve", package = "joineRML")
46
47
```
47
48
@@ -133,21 +134,21 @@ plot(fit, params = "beta")
133
134
134
135
Once an `mjoint` model has converged, and assuming the `pfs` argument is `TRUE` (default), then approximated standard errors are calculated based on the empirical information matrix of the profile likelihood at the maximizer. Theoretically, these standard errors will be underestimated (see the technical vignette). In principle, residual Monte Carlo error will oppose this through an increase in uncertainty.
135
136
136
-
```{r hvd_model_boot, eval=FALSE}
137
+
```{r hvd_model_boot, eval=FALSE, purl=FALSE}
137
138
fit.se <- bootSE(fit, nboot = 100)
138
139
```
139
140
140
141
Bootstrapping is a computationally intensive method, possibly taking many hours to fit. For this reason, one can relax the control parameter constraints on the optimization algorithm for each bootstrap model; however, this will be at the possible expense of inflated standard errors due to Monte Carlo error.
In addition to just comparing model parameter estimates, we can also extract the predicted (or posterior) random effects from each model and plot them.
0 commit comments