View source: R/bigSurvSGD.na.omit.R
| partialbigSurvSGDv0 | R Documentation |
Loads a previously scaled design matrix and continues the stochastic gradient optimisation for a subset of variables.
partialbigSurvSGDv0(
name.col,
datapath,
ncores = 1,
resBigscale,
bigmemory.flag = FALSE,
parallel.flag = FALSE,
inf.mth = "none"
)
name.col |
Character vector containing the column names that should be included in the partial fit. |
datapath |
File system path or connection where the big-memory backing file for the scaled design matrix is stored. |
ncores |
Number of processor cores allocated to the partial fitting
procedure. Defaults to |
resBigscale |
Result object returned by |
bigmemory.flag |
Logical flag determining whether big-memory backed
matrices are used when loading and updating the design matrix. Defaults to
|
parallel.flag |
Logical flag toggling the use of parallelised
stochastic gradient updates. Defaults to |
inf.mth |
Inference method requested for the partial fit, such as
|
Either a numeric vector of log hazard-ratio coefficients or, when inference is requested, a matrix whose columns correspond to the inferred coefficient summaries for each penalisation setting.
bigscale(), bigSurvSGD.na.omit() and bigSurvSGD.
data(micro.censure, package = "bigPLScox")
surv_data <- stats::na.omit(
micro.censure[, c("survyear", "DC", "sexe", "Agediag")]
)
scaled <- bigscale(
survival::Surv(survyear, DC) ~ .,
data = surv_data,
norm.method = "standardize",
batch.size = 16
)
datapath <- tempfile(fileext = ".csv")
utils::write.csv(surv_data, datapath, row.names = FALSE)
continued <- partialbigSurvSGDv0(
name.col = c("Agediag", "sexe"),
datapath = datapath,
ncores = 1,
resBigscale = scaled,
bigmemory.flag = FALSE,
parallel.flag = FALSE,
inf.mth = "none"
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.