CompetingRiskComparison

Competing-risk comparison family

Description

CompetingRiskComparison implements nested, heterogeneity, group, and pairwise comparison workflows for Fine-Gray models and competing-risk curves.

Summary rows follow associate.schema.comparison.

Super class

PolyGenius::ComparisonFamily -> CompetingRiskComparison

Methods

Public methods

Inherited methods

Method new()

Register the canonical family key for competing-risk comparisons.

Usage
CompetingRiskComparison$new()
Returns

The initialized family object with family.name = “crr”.


Method validate.frame()

Validate the resolved frame for the requested competing-risk comparison.

Usage
CompetingRiskComparison$validate.frame(frame, cell, options)
Arguments
frame

Resolved analysis frame restricted to the current fit cell.

cell

Named list describing the current fit-grid cell.

options

Normalized comparison options from the engine.

Returns

Invisibly TRUE when the frame is compatible with the requested comparison.


Method prepare.frame()

Build the complete-case competing-risk comparison frame for one Fine-Gray comparison cell.

Usage
CompetingRiskComparison$prepare.frame(frame, cell, options)
Arguments
frame

Resolved analysis frame restricted to the current fit cell.

cell

Named list describing the current fit-grid cell.

options

Normalized comparison options from the engine.

Returns

A plain data frame ready for Fine-Gray fitting.


Method fit.comparison()

Fit the base and full Fine-Gray models required by the requested comparison.

Usage
CompetingRiskComparison$fit.comparison(frame, cell, options, ...)
Arguments
frame

Prepared comparison frame returned by prepare.frame().

cell

Named list describing the current fit-grid cell.

options

Normalized comparison options from the engine.

Additional fitting arguments passed to cmprsk::crr().

Returns

A named list of fitted Fine-Gray model objects and design matrices.


Method build.summary.rows()

Convert fitted competing-risk comparison objects to shared comparison-schema rows.

Usage
CompetingRiskComparison$build.summary.rows(fit, frame, cell, options)
Arguments
fit

Fitted comparison object returned by fit.comparison().

frame

Prepared comparison frame.

cell

Named list describing the current fit-grid cell.

options

Normalized comparison options from the engine.

Returns

A data.table of rows following associate.schema.comparison.


Method build.artifacts()

Return cumulative-incidence artifacts for downstream visualization.

Usage
CompetingRiskComparison$build.artifacts(fit, frame, cell, options)
Arguments
fit

Fitted comparison object returned by fit.comparison().

frame

Prepared comparison frame.

cell

Named list describing the current fit-grid cell.

options

Normalized comparison options from the engine.

Returns

A named list with curves and group.summary.


Method clone()

The objects of this class are cloneable with this method.

Usage
CompetingRiskComparison$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.