View source: R/extract_model.R
extract_model | R Documentation |
Currently only extracts functional cox models not mixed functional cox models.
extract_model(mxFDAobject, metric, type, model_name)
mxFDAobject |
object of class |
metric |
metric functional PCA data to extract, e.g. 'uni k' |
type |
one of "cox", "mcox", or "sofr" to specify the type of model to extract |
model_name |
character string of the model name to retrieve |
fit functional model
Alex Soupir alex.soupir@moffitt.org
#load ovarian mxFDA object
data('ovarian_FDA')
#run the lfcm model
ovarian_FDA = run_fcm(ovarian_FDA, model_name = "fit_lfcm",
formula = survival_time ~ age, event = "event",
metric = "uni g", r = "r", value = "fundiff",
analysis_vars = c("age", "survival_time"),
afcm = FALSE)
#extract model
mod = extract_model(ovarian_FDA, 'uni g', 'cox', 'fit_lfcm')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.