report_mm: Print and Plot a Michaelis-Menten Fit

View source: R/report_mm.R

report_mmR Documentation

Print and Plot a Michaelis-Menten Fit

Description

Convenience wrapper that prints a fitted-model summary and draws the fitted curve with a confidence or prediction band. Higher-moment fits support pointwise mean-confidence bands, not prediction bands, because their working moments do not specify predictive quantiles.

Usage

report_mm(object, level = object$interval_level,
  method = c("wald", "bootstrap"), B = 399L,
  bootstrap_type = c("wild", "pairs"),
  bootstrap_ci = c("studentized", "basic", "percentile"),
  wild_weights = c("mammen", "rademacher"), seed = NULL,
  interval_type = c("confidence", "prediction", "none"),
  digits = max(3L, getOption("digits") - 2L), ...)

Arguments

object

A fitted object returned by fit_mm, fit_mm_moments, or cluster_mm.

level

Confidence level used in the printed summary and plot.

method

Interval method used in the printed summary: "wald" or "bootstrap".

B

Number of bootstrap resamples when method = "bootstrap".

bootstrap_type

Bootstrap scheme used when method = "bootstrap": "wild" or "pairs". Higher-moment fits default to and require "pairs".

bootstrap_ci

Bootstrap interval calibration used when method = "bootstrap": "studentized", "basic", or "percentile".

wild_weights

Wild-bootstrap multipliers used when bootstrap_type = "wild": "mammen" or "rademacher".

seed

Deprecated and ignored. Call set.seed() before bootstrap-based summaries if reproducibility is needed.

interval_type

Character string indicating whether the plotted band should be "confidence", "prediction", or "none".

digits

Number of printed digits.

...

Additional graphical arguments passed to plot.

Value

The original fitted object, returned invisibly. When method = "bootstrap" and the object inherits from "fit_mm", the printed summary uses bootstrap standard errors and confidence intervals; the plotted band remains the usual pointwise confidence or prediction band from plot.fit_mm(). For very small curves (fewer than 20 observations or fewer than 6 distinct substrate concentrations), the printed summary reports point estimates only by default and leaves interval construction to an explicit confint() call. For sparse clustered fits, the printed summary similarly suppresses interval output by default and treats confint() as an explicit sensitivity analysis; bootstrap summaries are not currently available for "cluster_mm" objects.

Examples

one_curve <- subset(sdl_demo, enzyme == "1111")
fit <- fit_mm(
  x = one_curve$s_uM,
  y = one_curve$v_uM_per_min,
  variance = "sqrt"
)


report_mm(fit, interval_type = "confidence")
set.seed(1)
report_mm(
  fit,
  method = "bootstrap",
  B = 99,
  bootstrap_ci = "studentized",
  wild_weights = "mammen",
  interval_type = "confidence"
)

cluster_fit <- cluster_mm(
  data = subset(alves_demo, enzyme == "BG"),
  s = "substrate_conc",
  v = "activity",
  cluster = "core",
  variance = "sqrt"
)
report_mm(cluster_fit, interval_type = "confidence")


inferMM documentation built on Oct. 30, 2026, 9:06 a.m.