Plant Pft Statistics¶
Module: spectralbridge.plant_pft_statistics.
Conditional empirical PFT contrasts; fitted quantile curves are never replicates.
These are associational randomization diagnostics of the supplied sampled plants, conditional on exchangeability within recorded blocks, not causal/transfer tests.
API glossary ยท Workflow / scientific context
Signatures and documentation below are collected from the current source. Advanced objects are not newly declared stable by inclusion here.
Audience: advanced.
PFTStatisticsConfig
dataclass
¶
PFTStatisticsConfig(permutations: int = 9999, bootstraps: int = 999, min_plants: int = 10, seed: int = 20261014, stages: tuple[str, ...] = ('raw', 'corr', 'olioli'))
Explicit, reproducible inferential choices (not acceptance thresholds).
Audience: advanced.
Audience: advanced.
permute_within ¶
permute_within(labels, blocks, rng)
Shuffle whole plant labels jointly across bands, preserving block counts.
Audience: advanced.
contrast ¶
contrast(values, labels, blocks, *, permutations, bootstraps, seed)
Block-adjusted binary coefficient with fixed null scaling and max-T.
Mixed blocks only; beta weights block contrasts by nA*nB/(nA+nB). Null scaling uses block-centered variation independent of PFT labels. Whole-curve max |T| and each-band max-T probabilities share one permutation distribution. Bootstrap intervals are pointwise/descriptive, not simultaneous.
Audience: advanced.
run_pft_statistics ¶
run_pft_statistics(comparisons, output, *, config=None, crosswalk=None)
Read verified compact products in place and write resumable statistics.