Function to call ChrX copy number based on LogR (suitable for male samples). Copy number cannot be called for the non-PAR region of ChrX due to the hemizygosity of all 1000G SNPs. This function enables calling subclonal copy number for the non-PAR region by segmenting LogR. A number of correction steps are undertaken to account for the noisy nature of LogR. This function requires the following libraries: copynumber, data.table and ggplot2. It reads in three files generated by previous steps of Battenberg, namely samplename_mutantLogR_gcCorrected.tab, samplename_purity_ploidy.txt and samplename_copynumber_extended.txt. This function will also update the Battenberg genome-wide profile plots (average.png and subclones.png) to include the chrX profile by also reading in the samplename.BAFsegmented.txt and samplename_rho_psi.txt files
callChrXsubclones(
tumourname,
X_gamma = 1000,
X_kmin = 100,
genomebuild,
AR = TRUE,
prior_breakpoints_file = NULL,
chrom_names,
data_type = "wgs"
)The sample name used for Battenberg (i.e. the tumour BAM file name without the .bam extension)
The PCF gamma value for segmentation of 1000G SNP LogR values (Default 1000)
The min number of SNPs to support a segment in PCF of LogR values (Default 100)
The genome build used in running Battenberg (hg19 or hg38)
Should the segment carrying the androgen receptor (AR) locus to be visually distinguished in average plot? (Default TRUE)
A two column text file with prior genome-wide breakpoints, possibly from structural variants. This file must contain two columns with headers "chr" and "pos" representing chromosome and position.
A vector containing the names of chromosomes to be included in the final genome-wide Battenberg copy number plot with chrX