| print.mfp2 | R Documentation |
Displays the choices made by mfp2() and the resulting fitted model.
Use print(fit) for the full report, or set detailed_settings = FALSE
for a shorter view.
## S3 method for class 'mfp2'
print(x, detailed_settings = TRUE, notes = TRUE, intercepts = NULL, ...)
x |
A fitted |
detailed_settings |
Show the Detailed Settings table. Default |
notes |
Show explanatory notes beneath the settings and model-fit
sections. Default |
intercepts |
Show ordinal threshold intercepts. By default ( |
... |
Additional print arguments. Use |
The report shows the original call and model details, selected and excluded
variables, preprocessing, selected functions, final coefficients with
standard errors, and model-fit statistics.
Preprocessing shifts and scales display without unnecessary trailing
zeros, independently of the digits print setting.
Function choices are grouped by type: standard MFP, approximate cumulative
distribution (ACD), and spike-at-zero (SAZ). Selected variables appear
before excluded variables in each table. In the SAZ table, prop_zero
is the proportion of fitting observations with a structural zero;
binary denotes an indicator for x = 0. For SAZ variables, the
continuous component is transformed only when x > 0.
The optional Detailed Settings table shows each variable's initial and final degrees of freedom, selection settings, and transformation flags. The coefficients table labels each fitted basis term and its standard error. If the fit was centered, it also displays the centering constant and explains how to read the estimate.
Model-fit measures depend on the family. GLMs report deviances, Cox models report minus twice the partial log likelihood, and other families display their applicable statistics. Multinomial fits show one coefficient block per non-reference outcome. Ordinal fits may include threshold intercepts.
Invisibly returns x, allowing the fitted object to be reused.
mfp2(), summary.mfp2()
data("prostate")
fit <- mfp2(lpsa ~ fp(age) + svi, data = prostate,
select = 1, alpha = 1, verbose = FALSE)
print(fit, detailed_settings = FALSE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.