Extract components from marginaleffects objects
# S3 method for marginaleffects
components(object, component = NULL, ...)
The requested component from the mfx object
A marginaleffects object (predictions, comparisons, slopes, or hypotheses)
Character string specifying which component to extract. Must be a valid
slot name from the internal S4 object. If NULL
(the default), components()
prints a message with
all available component names. Common components include: "model", "newdata",
"modeldata", "call", "jacobian", "vcov_model", "type", "by", "comparison", "variables", etc.
Ignored.
This function provides access to the internal components stored in the mfx
attribute of marginaleffects objects. The mfx
attribute contains an S4 object of
class "marginaleffects_internal" with various slots containing model information,
data, and computational details used by the marginaleffects functions.
Warning: the internal slot names are not considered part of the public API and may change without warning in future versions of the marginaleffects package.