Learn R Programming

bhm (version 1.16)

brm: Fitting Biomarker Continuous Threshold Models

Description

{brm} is a R package for Continuous Threshold Models. It uses the maximum likehood method (Liu and Chen, 2020) to identify a cut-point (thershold parameter) for the biomarker in the Cox proportional hazards model. The model is specified by giving a symbolic description of the linear predictor and a description of the distribution family.

Usage

brm(x, ...)

# S3 method for formula brm(formula, data = list(...), method = c("gradient", "profile"), epsilon = NULL, ...)

# use # brm(y ~ biomarker) # # to fit a prognostic model with biomarker term only (will be implement in the future) # # use # # brm(y ~ biomarker+treatment+x1+x2+...) # # to fit a predictive model with interaciton between biomarker # and treatment, adjusted for x1, x2, etc. # # use # brm(x, y, method, ...) # # to fit a model without formula # # Biomarker shall be in the first dependent variable

Arguments

formula

an object of class "formula"(or one that can be coerced to that class): a symbolic description of the model to be fitted. The details of model specification are given under 'Details'.

data

an optional data frame, list or environment (or object coercible by 'as.data.frame' to a data frame) containing the variables in the model. If not found in data, the variables are taken from environment(formula), typically the environment from which glm is called.

method

Method to fit a brm model. The default method is "Gradient". We will expend to the single-index model in this package soon.

x

For "brm.default", x is a design matrix of dimension n * p and y is a vector of observations of length n for a "Surv" survival object for "coxph" models.

additional arguments to be passed to the low level regression fitting functions (see below).

epsilon

Step width for the profile likelihood method, default is (max(w)-min(w))/20.

Value

brm returns an object of class inheriting from "brm" which inherits from the class glm or 'coxph'. See later in this section.

The function "summary" (i.e., "summary.brm") can be used to obtain or print a summary of the results, for example, the 95

An object of class "brm" is a list containing at least the following components:

c.max

a vector of the mean estimates for the threshold parameter(s)

coefficients

a named vector of coefficients from 'brm'

c.fit

fitted conditional regression model given c = c.max

Details

'biomarker' is a Biomarker variable. This variable is required and shall be the first dependent variable in the formula.

"interaction" is an option of fitting model with itneractin term. When interaction = TRUE, a predictive biomarker model will be fitted. When interaction = FALSE, a prognostic biomarker model will be fitted. Both Biomarker and Treatment variables are required if 'interaction' = TRUE and 'treatment' shall be the second variable in the formula.

"brm.default" is the workhorse functions: they are not normally called directly but can be more efficient where the response vector, design matrix and family have already been calculated.

References

Liu, S. S. and Chen, B. E. (2020). Continuous threshold models with two-way interactions in survival analysis. Canadian Journal of Statistics.

See Also

bhm, coxph, plot.brm, print.brm, residuals.brm, summary.brm,

Examples

Run this code
# NOT RUN {
##
## Generate a random data set
n = 100
b = c(0.5, 1, 1.5)
data = gendat.surv(n, c0 = 0.40, beta = b, type="brm")
age = runif(n, 0, 1)*100
tm = data[, 1]
status = data[, 2]
trt = data[, 3]
ki67 = data[, 4]
## fit a biomarker threshold survival model with one single cut point

   fit = brm(Surv(tm, status)~ki67+trt+age)
##
## fit a prognostic continuous threshold model with biomarker only
##
#    fit = brm(Surv(tm, status)~ki67)
##
## To print the output, use
##
#    print(fit)
##
# }

Run the code above in your browser using DataLab