CosmonetTraining: Fit network-regularized Cox regression models on training set

Description Usage Arguments Value

View source: R/CosmonetTraining.R

Description

This function fits penalized Cox regression methods in order to incorporate gene regulatory relationships and to select signature genes using the training set T.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
CosmonetTraining(
  k,
  x,
  y,
  screenVars,
  family = "Cox",
  penalty = "Net",
  Omega,
  alpha = 0.5,
  lambda = NULL,
  nlambda = 50,
  nfolds = 5,
  foldid = NULL,
  selOptLambda = min("min", "1se"),
  optCutpoint = c("minPValue", "median", "survCutpoint")
)

Arguments

k

times to loop through cross validation.

x

input training matrix nxp. Each row is an observation vector.

y

response variable, y should be a two-column data frame with columns named time and status. The latter is a binary variable, with 1 indicating event, and 0 indicating right censored. The rownames indicate the sample names ordered as the samples in the input testing matrix.

screenVars

screened variables obtained from BMD- or DAD-, or BMD+DAD-screening or by the user. A list or a character string can be used.

family

Cox proportional hazards regression model. Family=Cox

penalty

penalty type. Can choose Net where Omega matrix is requested. For penalty = Net, the penalty is defined as λ*{α*||β||_1+(1-\lapha)/2*(β^{T}Lβ)}, where L is a Laplacian matrix calculated from Omega.

Omega

adjacency matrix with zero diagonal and non-negative off-diagonal used to calculate Laplacian matrix.

alpha

ratio between L_1 and Laplacian for Net. Default is alpha = 0.5.

lambda

a user supplied decreasing sequence. If lambda = NULL, a sequence of lambda is generated based on nlambda and rlambda (for more details, see APML0 package). Supplying a value of lambda overrides this.

nlambda

number of lambda values. Default is 50.

nfolds

number of folds performed for tuning optimal parameters over runs. Default is nfolds = 5.

foldid

an optional vector of values between 1 and nfolds specifying which fold each observation is in.

selOptLambda

a character string for selecting the lambda parameter. Options are min which uses the regularisation procedure implemented in the APML0 package or 1se" to select the lambda parameter within one standard error from the optimal value.

optCutpoint

a character string for choosing the optimal cutpoint on training set T based on prognostic index PI^{T}. Can choose minPValue, median and survCutpoint.

Value

The following objects are returned:

beta

a sparse Matrix of coefficients, stored in classdgCMatrix.

opt.lambdas

lambda values based on minimum cvm over runs and on 1se to select the lambda parameter within one standard error from the optimal value.

df

data frame composed by samples, relative prognostic indices, times, status and group risk for each quantile q_{gamma}, with γ=0.20, ..., 0.80.

summary

summary table on number of patients at risk, cutoff and p.value for each quantile.

opt.cutoff

optimal cutoff selected on the training.

p.value

resulting from the log-rank test (the significance level is p-value < 0.05).


cosmonet-package/COSMONET documentation built on Dec. 24, 2021, 9:12 p.m.