Learn R Programming

LncMod (version 1.1)

tri.surv: Survival Analysis of Triplets

Description

Generate plots describing expression and survival comparison for train/test sample groups of a triplet (or triplets).

Usage

tri.surv(tri, exp.sur, train, test, index = 1)

Arguments

tri
a character string dataframe (or matrix) specifying triplets in which the first column is modulator,the second is effector,the third is target.
exp.sur
a dataframe specifying expression and survival information.Its rownames are sample names.Its colnames are factor names in triplets and survival tag (see example data in details).
train
a character string vector specifying train sample names.
test
a character string vector specifying test sample names.
index
a numeric vector (default 1) reprsenting rowindex of triplets analyed.

Value

A dataframe whose rows represent different triplets while columns represent 15 kinds of information on the triplet. The columns are:
  • modulator the modulator name;
  • effector the effector name;
  • target the target name;
  • coef_modulator the coxph coefficient of modulator;
  • p_modulator the significance of coef_lnc;
  • coef_effector the coxph coefficient of effector;
  • p_effector the significance of coef_effector;
  • coef_target the coxph coefficient of target;
  • p_target the significance of coef_target;
  • N_train1 the sample number with low risk score in train sameples;
  • N_train2 the sample number with high risk score in train sameples;
  • dif_train the significance of survival difference between low/high risk sameples in train samples;
  • N_test1 the sample number with low risk score in test sameples;
  • N_test2 the sample number with high risk score in test sameples;
  • dif_test the significance of survival difference between low/high risk sameples in test samples;

Details

Note:All the arguments without default value must be assigned.

For the output,a triplet corresponds 6 plots,3 for train samples and 3 for test samples.For train sameples,one plot is to show expression of triplet,another is to show risk scores,the other is comparison of survivorship curve between highrisk and lowrisk sameples.

See Also

coxph,Surv,survdiff

Examples

Run this code
#a triplet
tri.surv(tri=datatests[["tri_bs"]],exp.sur=datatests[["exp_sur"]],
         train=datatests[["train"]],test=datatests[["test"]])
#two triplets(or more)
tri.surv(tri=datatests[["tri_bs"]],exp.sur=datatests[["exp_sur"]],
         train=datatests[["train"]],test=datatests[["test"]],
		 index=c(1,2))

Run the code above in your browser using DataLab