get_model_data: Get data from model object (works with S3 and S4)

View source: R/m2dt_utils.R

get_model_dataR Documentation

Get data from model object (works with S3 and S4)

Description

Retrieves the original data used to fit a model. Checks multiple locations including model attributes, $data slot, $model slot, and @frame for S4.

Usage

get_model_data(model)

Arguments

model

Fitted model object (S3 or S4).

Value

Data frame or data.table used to fit the model, or NULL if unavailable.


summata documentation built on May 7, 2026, 5:07 p.m.