Learn R Programming

Introduction

The Coxmos R package is an end-to-end pipeline designed for the study of survival analysis for high dimensional data. Updating classical methods and adding new ones based on sPLS technologies. Furthermore, includes multiblock functions to work with multiple sets of information to improve survival accuracy.

The pipeline includes three basic analysis blocks:

  1. Computing cross-validation functions and getting the models.

  2. Evaluating all the models to select the better one for multiple metrics.

  3. Understanding the results in terms of the global model and the original variables.

Coxmos contains the necessary functions and documentation to obtain from raw data the final models after compare them, evaluate with test data, study the performance individually and in terms of components and graph all the results to understand which variables are more relevant for each case of study.

Installation

Dependencies requiring manual installation

Some of the metrics available in Coxmos are optional based and will not be included in the standard Coxmos installation. A list of all optional packages are shown below:

  • nsROC:
  • smoothROCtime:
  • survivalROC:
  • risksetROC:
  • ggforce:
  • RColorConesa:

Installing Coxmos

The Coxmos R package and all the remaining dependencies can be installed from CRAN:

install.packages("Coxmos")

Or from GitHub using devtools

devtools::install_github("BiostatOmics/Coxmos")

In case of using Github, to access vignettes, you will need to force building with devtools::install_github(build_vignettes = TRUE). Please note that this will also install all suggested packages required for vignette build and might increase install time. Alternatively, an HTML version of the vignette is available under the vignettes folder.

Getting started

In order to use Coxmos, you will need the following items:

  • An explanatory X matrix.
  • A response survival Y matrix (with two columns, "time" and "event").

Please note that two toy datasets are included in the package. Details to load and use them can be found in the package's vignette.

Contact

If you encounter a problem, please open an issue via GitHub.

References

If you use Coxmos in your research, please cite the original publication:

Copy Link

Version

Install

install.packages('Coxmos')

Monthly Downloads

141

Version

1.1.3

License

CC BY 4.0

Issues

Pull Requests

Stars

Forks

Maintainer

Pedro Salguero Garcia

Last Published

June 2nd, 2025

Functions in Coxmos (1.1.3)

coxmos

Coxmos Modeling Function
coxEN

coxEN
cv.coxEN

coxEN Cross-Validation
cv.isb.splsdacox

Iterative SB.sPLS-DACOX-Dynamic Cross-Validation
cox

cox
coxSW

coxSW
cv.coxmos

Cross-Validation for COX Models
cenROC

Estimation of the time-dependent ROC curve for right censored survival data
cox.prediction

cox.prediction
cv.isb.splsdrcox

Iterative SB.sPLS-DRCOX-Dynamic Cross-Validation
cv.splsdacox

Cross validation splsdacox_dynamic
cv.mb.splsdrcox

MB.sPLS-DRCOX Cross-Validation
cv.isb.splsdrcox_penalty

Iterative SB.sPLS-DRCOX-Dynamic Cross-Validation
cv.sb.splsicox

Cross validation cv.sb.splsicox
cv.isb.splsicox

Iterative SB.sPLS-ICOX-Dynamic Cross-Validation
cv.sb.splsdacox

SB.sPLS-DACOX-Dynamic Cross-Validation
cv.sb.splsdrcox

SB.sPLS-DRCOX-Dynamic Cross-Validation
cv.mb.splsdacox

MB.sPLS-DACOX Cross-Validation
cv.sb.splsdrcox_penalty

SB.sPLS-DRCOX Cross-Validation
cv.mb.coxmos

Multiblock COX Cross-Validation Function
deleteNearZeroCoefficientOfVariation.mb

deleteNearZeroCoefficientOfVariation.mb
cv.splsdrcox

Cross validation sPLS-DRCOX
deleteNearZeroCoefficientOfVariation

deleteNearZeroCoefficientOfVariation
cv.splsicox

sPLS-ICOX Cross-Validation
deleteZeroOrNearZeroVariance

deleteZeroOrNearZeroVariance
eval_Coxmos_model_per_variable

eval_Coxmos_model_per_variable
eval_Coxmos_model_per_variable.list

eval_Coxmos_model_per_variable.list
deleteZeroOrNearZeroVariance.mb

deleteZeroOrNearZeroVariance.mb
dnorkernel

Derivative of normal distribution
cv.splsdrcox_penalty

sPLS-DRCOX Cross-Validation
getDesign.MB

getDesign.MB
getCutoffAutoKM

getCutoffAutoKM
getAutoKM

getAutoKM
getEPV.mb

getEPV.mb
getEPV

getEPV
factorToBinary

factorToBinary
getAutoKM.list

getAutoKM.list
eval_Coxmos_models

eval_Coxmos_models
getTestKM

getTestKM
getCutoffAutoKM.list

getCutoffAutoKM.list
kfunc

Function to evaluate the matrix of data vector minus the grid points divided by the bandwidth value.
isb.splsdrcox

Iterative single-block sPLS-DRCOX Dynamic
isb.splsdacox

Iterative single-block sPLS-DACOX Dynamic
isb.splsdrcox_penalty

Iterative single-block sPLS-DRCOX
integ

Numerical Integral function using Simpson's rule
getTestKM.list

getTestKM.list
ker_dis_i

Distribution function without the ith observation
isb.splsicox

Iterative single-block sPLS-ICOX
kfunction

Kernel distribution function
getTrainTest

getTrainTest
mb.coxmos

Multiblock COX Modeling Function
plot_Coxmos.MB.PLS.model

plot_Coxmos.MB.PLS.model
plot_Coxmos.PLS.model

plot_Coxmos.PLS.model
mb.splsdrcox

MB.sPLS-DRCOX
loadingplot.Coxmos

loadingplot.Coxmos
muro

The value of squared integral x^2 k(x) dx and integral x k(x) K(x) dx
norm01

norm01
plot_cox.event

plot_cox.event
loadingplot.fromVector.Coxmos

loadingplot.fromVector.Coxmos
plot_cox.event.list

plot_cox.event.list
plot_evaluation

plot_evaluation
plot_divergent.biplot

plot_divergent.biplot
mb.splsdacox

MB.sPLS-DACOX
plot_multipleObservations.LP.list

plot_multipleObservations.LP.list
plot_observation.eventDensity

plot_observation.eventDensity
plot_evaluation.list

plot_evaluation.list
plot_events

plot_events
plot_forest

plot_forest
plot_forest.list

plot_forest.list
plot_multipleObservations.LP

plot_multipleObservations.LP
plot_proportionalHazard

plot_proportionalHazard
plot_sPLS_Coxmos

plot_sPLS_Coxmos
plot_pseudobeta.list

plot_pseudobeta.list
plot_observation.pseudobeta.list

plot_observation.pseudobeta.list
predict.Coxmos

predict.Coxmos
plot_time.list

Time consuming plot.
plot_observation.eventHistogram

plot_observation.eventHistogram
plot_observation.pseudobeta

plot_pseudobeta.newObservation
plot_pseudobeta

plot_pseudobeta
plot_proportionalHazard.list

plot_proportionalHazard.list
splsdrcox

sPLS-DRCOX Dynamic
save_ggplot_lst

save_ggplot_lst
save_ggplot

save_ggplot
sb.splsdrcox

SB.sPLS-DRCOX-Dynamic
sb.splsicox

SB.sPLS-ICOX
sb.splsdrcox_penalty

SB.sPLS-DRCOX
sb.splsdacox

SB.sPLS-DACOX-Dynamic
splsdrcox_penalty

sPLS-DRCOX
print.Coxmos

print.Coxmos
splsdacox

sPLS-DACOX Dynamic
wquantile

Weighted quartile estimation
wvar

Weighted variance estimation
wbw

Function to select the bandwidth parameter needed for smoothing the time-dependent ROC curve.
wIQR

Weighted inter-quartile range estimation
splsicox

sPLS-ICOX
w.starplot.Coxmos

w.starplot.Coxmos
Beran

Estimation of the conditional distribution function of the response, given the covariate under random censoring.
Csurv

Survival probability conditional to the observed data estimation for right censored data.
CV

The cross-validation bandwidth selection for weighted data
PI

The plug-in bandwidth selection for weighted data
NR

The normal reference bandwidth selection for weighted data
X_multiomic

X_multiomic Data
X_proteomic

X_proteomic Data
Y_proteomic

Y_proteomic Data
Y_multiomic

Y_multiomic Data
RocFun

ROC estimation function