Skip to contents

Recasts a taphonomy question as a treatment-effect estimate: how much of the observed preservation is attributable to burial processing (the treatment, e.g. quicklime desiccation), holding environment and handling fixed, and how strong an unmeasured cause (a "miracle") would need to be to explain the rest. A thin dispatch over morie_estimate_irm (DoubleML IRM, cross-fit ATE + SE; default) or morie_estimate_cate (meta-learner, per-unit heterogeneous effects) plus morie_e_value. Adds no new statistics.

Usage

morie_taphonomy_preservation_delta(
  data,
  treatment = "lime_treatment",
  outcome = "preservation_score",
  covariates = NULL,
  estimator = c("irm", "cate"),
  se_method = c("none", "bootstrap"),
  n_boot = 199L,
  boot_seed = 42L,
  ...
)

Arguments

data

A data.frame of real comparanda (see morie_taphonomy_schema). Must be non-empty.

treatment

Binary treatment column (default "lime_treatment").

outcome

Continuous preservation outcome (default "preservation_score").

covariates

Character vector of confounder/measurement columns. Defaults to every schema covariate + measurement present in data.

estimator

"irm" (DoubleML cross-fit ATE with an orthogonal SE; default) or "cate" (meta-learner per-unit effects, summarised to the mean delta, with the full per-unit vector in cate_per_unit and its dispersion in cate_sd).

se_method

Inference for the "cate" path only: "none" (default) reports the point estimate + cate_sd dispersion with no SE/CI/p-value; "bootstrap" resamples rows and refits the CATE procedure n_boot times to give a valid SE, percentile CI, and p-value for the mean effect. (sd(tau)/sqrt(n) is deliberately not offered: the per-unit effects are correlated fitted predictions, so it understates the true SE – use cate_sd for heterogeneity or bootstrap for inference.) Ignored for "irm", which carries its own orthogonal SE.

n_boot

Bootstrap resamples when se_method = "bootstrap" (default 199).

boot_seed

RNG seed for the bootstrap (default 42).

...

Passed to the chosen estimator (e.g. n_folds for IRM, meta_learner for CATE).

Value

A named list (RichResult-style; all estimates are double): value (the preservation delta = ATE / mean CATE), se, p_value (Wald; NA on the CATE path – no valid SE), ci_lower, ci_upper, n (integer count), e_value, e_value_ci, estimator, cate_per_unit and cate_sd (NULL unless estimator = "cate"), warnings, and a plain-language interpretation.

Examples

# \donttest{
if (requireNamespace("DoubleML", quietly = TRUE)) {
  df <- morie_taphonomy_schema()        # fill with REAL comparanda first
  # morie_taphonomy_preservation_delta(df)
}
# }