Xcontrast: Xcontrast

View source: R/Xcontrast.r

XcontrastR Documentation

Xcontrast

Description

Produce Design Matrices for Contrasts

Usage

Xcontrast(
  fit,
  a,
  b = NULL,
  a2 = NULL,
  b2 = NULL,
  ycut = NULL,
  weights = "equal",
  expand = TRUE
)

Arguments

fit

an 'rms' or 'rmsb' fit object, not necessarily complete

a

see [rms::contrast.rms()]

b

see [rms::contrast.rms()]

a2

see [rms::contrast.rms()]

b2

see [rms::contrast.rms()]

ycut

see [rms::contrast.rms()]

weights

see [rms::contrast.rms()]

expand

see [rms::contrast.rms()]

Details

This is a simpler version of 'contrast.rms' that creates design matrices or differences of them and does not require the fit object to be complete (i.e., to have coefficients). This is used for the 'pcontrast' option in [rmsb::blrm()].

Value

numeric matrix

Author(s)

Frank Harrell


rms documentation built on Sept. 12, 2023, 9:07 a.m.