copy_number_variation
- pylluminator.cnv.copy_number_variation(samples: Samples, sample_labels: str | list[str] | None = None, group_by: str | None = None, normalization_labels: str | list[str] | None = None) DataFrame | None
Perform copy number variation (CNV). The CNV calculation method on copy-number-normal samples to normalize probe signal intensity. It is strongly recommended to use normal samples that closely match the biological and technical characteristics of the target samples.
- Parameters:
samples (Samples) – Samples object that contains the samples to be analyzed, and the normalization samples if normalization_sample_labels are specified.
sample_labels (str) – name(s) of the samples to calculate CNV of. If None (default), all samples in the Samples object will be used, except the normalization samples if specified.
group_by (str) – name of the column in the sample sheet to group the samples by. If None (default), perfom CNV per sample (ie no grouping). If group_by is specified, sample_labels must be None.
normalization_labels (str | list[str] | None) – if group_by is specified, name(s) of the group(s) to use for normalization. Otherwise, name(s) of the samples to use for normalization. If None (default), default normalization samples will be loaded from pylluminator-data - but this only work for EPIC/hg38 and EPICv2/hg38; for other array versions, you need to normalization data. Default: None
- Returns:
the probe coordinates dataframe with the CNV information
- Return type:
pandas.DataFrame