aberration: Detect Copy Number Aberrations (Gains and Losses)

View source: R/aberration.R

aberrationR Documentation

Detect Copy Number Aberrations (Gains and Losses)

Description

Reads a CNV (Copy Number Variation) data file and identifies genomic segments showing significant aberrations (gains or losses) based on a user-defined effect size threshold. Results are split by chromosome and returned as a named list.

Usage

aberration(cnv_data_file, effect_size = 0.3)

Arguments

cnv_data_file

Character. Path to the CNV data file (whitespace-delimited, with a header). Must contain columns: Chromosome, Start, End, Num_Probes, Segment_Mean, and Sample.

effect_size

Numeric. Threshold for calling aberrations. Segments with Segment_Mean > effect_size are called Gains; segments with Segment_Mean < -effect_size are called Losses. Default is 0.3.

Details

Segments with Segment_Mean between -effect_size and effect_size (inclusive) are considered neutral and excluded from the output. The default threshold of 0.3 is widely used in TCGA-based CNV analyses. This function is cancer-type agnostic and can be applied to CNV data from any solid tumour.

Value

A named list where each element corresponds to a chromosome (e.g., "1", "2", ...) and contains a data frame of aberrant segments for that chromosome. Each data frame includes the columns: Chromosome, Start, End, Num_Probes, Segment_Mean, Sample, Aberration (Gain or Loss), and Aberration_Code (1 = Gain, 0 = Loss).

References

Mermel CH, et al. (2011). GISTIC2.0 facilitates sensitive and confident localization of the targets of focal somatic copy-number alteration in human cancers. Genome Biol, 12(4):R41.

Examples

cnv_file <- system.file("extdata", "cnv_data.txt", package = "RiskyCNV")
aberrations <- aberration(
  cnv_data_file = cnv_file,
  effect_size   = 0.3
)
print(aberrations[["2"]])


RiskyCNV documentation built on June 5, 2026, 5:07 p.m.