Learn R Programming

GPTCM (version 1.1.3)

plotCoeff: Plot posterior estimates of regression coefficients

Description

create nice plots for estimated coefficients and 95

Usage

plotCoeff(
  dat,
  datMCMC,
  estimator = "beta",
  intercept = FALSE,
  bandwidth = NULL,
  xlim = NULL,
  xlab = NULL,
  label.y = NULL,
  first.coef = NULL,
  y.axis.size = 8,
  ...
)

Value

A ggplot2::ggplot object. See ?ggplot2::ggplot for more details of the object.

Arguments

dat

input data as a list containing survival data sub-list survObj with two vectors (event and time), clinical variable matrix x0, cluster-specific covariates X, and proportions data matrix proportion

datMCMC

returned object from the main function GPTCM()

estimator

print estimators, one of c("beta", "zeta", "gamma", "eta")

intercept

logical value to print intercepts

bandwidth

a value of bandwidth used for the ridgeplot

xlim

numeric vectors of length 2, giving the x-coordinate range.

xlab

a title for the x axis

label.y

a title for the y axis

first.coef

number of the first variables. Default NULL for all variables

y.axis.size

text size in pts

...

others

References

Zhao Z, Kızılaslan F, Wang S, Zucknick M (2025). Generalized promotion time cure model: A new modeling framework to identify cell-type-specific genes and improve survival prognosis. arXiv:2509.01001

Examples

Run this code

# simulate data
set.seed(123)
n <- 200 # subjects
p <- 10 # variable selection predictors
L <- 3 # cell types
dat <- simData(n, p, L)

# run a Bayesian GPTCM model: GPTCM-Ber2
fit <- GPTCM(dat, nIter = 10, burnin = 0)

plotCoeff(dat, datMCMC = fit, estimator = "beta")

Run the code above in your browser using DataLab