Learn R Programming

MetabolicSurv (version 1.1.1)

cvsim-class: The cvsim Class.

Description

Class of object returned by function CVSim.

Usage

# S4 method for cvsim
show(object)

# S4 method for cvsim summary(object)

# S4 method for cvsim,missing plot(x, y, type = 1, ...)

Arguments

object

A cvsim class object

x

A cvsim class object

y

missing

type

Plot type. 1 distribution of the HR under test For the Top K metabolites using PCA. 2 distribution of the HR under test For the Top K metabolites using PLS.

...

The usual extra arguments to generic functions <U+2014> see plot, plot.default

Slots

HRpca

A 3-way array in which first, second, and third dimensions correspond to number of metabolites, Hazard ratio infromation(Estimated HR, LowerCI and UpperCI), and number of cross validation respectively. This contains the estimated HR on test data and dimension reduction method is PCA.

HRpls

A 3-way array in which first, second, and third dimensions correspond to number of metabolites, Hazard ratio infromation(Estimated HR, LowerCI and UpperCI), and number of cross validation respectively. This contains the estimated HR on test data and dimension reduction method is PLS.

Nmets

The number of metabolites in the reduced matrix

Ncv

The number of cross validation done

Top

A sequence of top k metabolites considered. Default is Top=seq(5,100,by=5)

See Also

CVPcaPls, SurvPcaClass, SurvPlsClass

Examples

Run this code
# NOT RUN {
## GENERATE SOME METABOLIC SURVIVAL DATA WITH PROGNOSTIC FACTORS
Data<-MSData(nPatients=100,nMet=150,Prop=0.5)

## FIRST IS THE NETABOLITE BY METABOLITE ANALYSIS
w = CVMetSpecificCoxPh(Fold=3,Survival=Data$Survival,
Mdata=t(Data$Mdata),Censor= Data$Censor,Reduce=TRUE,
Select=150,Prognostic=Data$Prognostic,Quantile = 0.5,Ncv=3)

## USING THE FUNCTION
Result = CVSim(w, Top = seq(5, 100, by = 5), Survival=Data$Survival,
 Censor=Data$Censor, Prognostic = Data$Prognostic)

## GET THE CLASS OF THE OBJECT
class(Result)     # A "cvsim" Class

##  METHOD THAT CAN BE USED FOR THE RESULT
show(Result)
summary(Result)
plot(Result, type =2)
# }

Run the code above in your browser using DataLab