plotBrier {psbcSpeedUp} | R Documentation |
Time-dependent Brier scores
Description
Predict time-dependent Brier scores based on Cox regression models
Usage
plotBrier(object, survObj.new = NULL, method = "mean", times = NULL, ...)
Arguments
object |
fitted object obtained with |
survObj.new |
a list containing observed data from new subjects with
components |
method |
option to use the posterior mean ( |
times |
maximum time point to evaluate the prediction |
... |
not used |
Details
psbcSpeedUp
Examples
# Load the example dataset
data("exampleData", package = "psbcSpeedUp")
p <- exampleData$p
q <- exampleData$q
survObj <- exampleData[1:3]
# Set hyperparameters
mypriorPara <- list(
"groupInd" = 1:p, "eta0" = 0.02, "kappa0" = 1, "c0" = 2, "r" = 10 / 9,
"delta" = 1e-05, "lambdaSq" = 1, "sigmaSq" = runif(1, 0.1, 10),
"beta.prop.var" = 1, "beta.clin.var" = 1)
# run Bayesian Lasso Cox
library("psbcSpeedUp")
set.seed(123)
fitBayesCox <- psbcSpeedUp(survObj,
p = p, q = q, hyperpar = mypriorPara,
nIter = 10, burnin = 0, outFilePath = tempdir()
)
# predict survival probabilities of the train data
plotBrier(fitBayesCox, times = 80)
[Package psbcSpeedUp version 2.0.7 Index]