Description Usage Arguments Details Value References See Also Examples
View source: R/predict_bicSurv.R
This function predicts the risk scores for patient samples in the test set.
1  predictBicSurv(newdata.vec, postprob.vec, mle.mat)

newdata.vec 
A vector consisting of the data from a test sample. 
postprob.vec 
A vector consisting of the posterior probability of each BMA selected model. 
mle.mat 
A matrix with one row per model and one column per variable giving
the maximum likelihood estimate of each coefficient for each

The function begins by computing the risk score of each model k in
the selected set of models M. The risk score for a model k = sum
(coefficient in model k * corresponding expression level in newdata.vec).
The function then predicts a patient risk score by summing the product
of the posterior probability of model k and the risk score of model k
over all models in M. In other words, predicted patient risk score =
sum (postprob model k * risk score model k). This function is called
by iterateBMAsurv.train.predict.assess
.
A real number representing the predicted risk score of a given patient sample.
Annest, A., Yeung, K.Y., Bumgarner, R.E., and Raftery, A.E. (2008). Iterative Bayesian Model Averaging for Survival Analysis. Manuscript in Progress.
Raftery, A.E. (1995). Bayesian model selection in social research (with Discussion). Sociological Methodology 1995 (Peter V. Marsden, ed.), pp. 111196, Cambridge, Mass.: Blackwells.
Volinsky, C., Madigan, D., Raftery, A., and Kronmal, R. (1997) Bayesian Model Averaging in Proprtional Hazard Models: Assessing the Risk of a Stroke. Applied Statistics 46: 433448.
Yeung, K.Y., Bumgarner, R.E. and Raftery, A.E. (2005) Bayesian Model Averaging: Development of an improved multiclass, gene selection and classification tool for microarray data. Bioinformatics 21: 23942402.
iterateBMAsurv.train.predict.assess
,
iterateBMAsurv.train.wrapper
,
predictiveAssessCategory
,
trainData
,
trainSurv
,
trainCens
,
testData
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20  library (BMA)
library (iterativeBMAsurv)
data(trainData)
data(trainSurv)
data(trainCens)
data(testData)
## Training phase: select relevant genes. Assume the training data is sorted
## and includes the desired number of topranked genes.
ret.list < iterateBMAsurv.train.wrapper (x=trainData, surv.time=trainSurv, cens.vec=trainCens, nbest=5)
ret.bma < ret.list$obj
## Get the selected genes with probne0 > 0
selected.genes < ret.list$curr.names[ret.bma$probne0 > 0]
## Get the subset of test data with the genes from the last iteration of bic.surv
curr.test.dat < testData [, selected.genes]
## Compute the predicted risk scores for the test samples
y.pred.test < apply (curr.test.dat, 1, predictBicSurv, postprob.vec=ret.bma$postprob, mle.mat=ret.bma$mle)

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.