cleverly.estimators.atmle_result.AdaptiveTMLESupport#

class cleverly.estimators.atmle_result.AdaptiveTMLESupport(n: int, n_trial: int, n_external: int, n_external_treated: int, controls_only: bool, external_source_min: float, external_source_quantiles: tuple[float, float, float], external_source_below_floor: float, trial_row_treatment_range: tuple[float, float], floor: float = 0.01, population: Literal['trial', 'pooled'] = 'pooled')[source]#

How well the trial covers the external rows, and the treatment range in the trial.

The effect averaged over every row is defined only where P(S = 1 | W) > 0 (assumption A3). The source gives no floor, so the report reads the cross-fitted pi(W) on the external rows against SOURCE_FLOOR and does not refuse. The effect averaged over the trial rows does not need A3, so adequate is then true and the shares are information only.

Parameters:
nint

Rows.

n_trialint

Trial rows.

n_externalint

External rows.

n_external_treatedint

External rows with the treated arm.

controls_onlybool

Whether the external rows hold controls only.

external_source_minfloat

The smallest cross-fitted P(S = 1 | W) on an external row, before bounds.

external_source_quantilestuple of float

Its 5%, 25% and 50% quantiles on the external rows.

external_source_below_floorfloat

The share of external rows with P(S = 1 | W) below floor.

trial_row_treatment_rangetuple of float

The smallest and largest bounded combined-data P(A = 1 | W) read on the trial rows.

floorfloat

The reading floor of P(S = 1 | W).

population{“trial”, “pooled”}

The rows the effect is averaged over.

Methods#

Attributes#

AdaptiveTMLESupport.adequate#

Whether A3 holds on the reading, which only the combined-rows effect needs.

AdaptiveTMLESupport.floor: float = 0.01#
AdaptiveTMLESupport.population: Literal['trial', 'pooled'] = 'pooled'#
AdaptiveTMLESupport.n: int#
AdaptiveTMLESupport.n_trial: int#
AdaptiveTMLESupport.n_external: int#
AdaptiveTMLESupport.n_external_treated: int#
AdaptiveTMLESupport.controls_only: bool#
AdaptiveTMLESupport.external_source_min: float#
AdaptiveTMLESupport.external_source_quantiles: tuple[float, float, float]#
AdaptiveTMLESupport.external_source_below_floor: float#
AdaptiveTMLESupport.trial_row_treatment_range: tuple[float, float]#