
Calculate rarefied diversity metrics through repeated subsampling
Source:R/clonality.R
iterativeSummary.RdNormalize diversity estimates across samples by subsampling to a common depth. This corrects for sequencing depth bias when comparing repertoires.
Arguments
- study_table
A tibble of antigen receptor sequences from
readImmunoSeq(). Must contain "junction_aa", "duplicate_count", and "duplicate_frequency" columns. Use productive junction sequences (not aggregated by amino acid) for accurate clonality estimates.- iterations
Number of bootstrap iterations for rarefaction (default 100). Higher values increase precision but take longer to compute.
- min_count
Target sequencing depth for rarefaction (default 1000). Repertoires with fewer sequences than this will be excluded with a warning.