compute_allele_specific_scna_table {CLONETv2}R Documentation

Function to compute allele specific somatic copy number

Description

This function takes the beta table of a tumor sample together with the associated ploidy and admixtures tables and computes the allele specific copy number of each segment in the beta table.

Usage

compute_allele_specific_scna_table(beta_table, ploidy_table,
  admixture_table, error_tb = error_table, allelic_imbalance_th = 0.5,
  n_digits = 3, n_cores = 1, debug = F)

Arguments

beta_table

data.frame formatted as the output of function compute_beta_table

ploidy_table

data.frame formatted as the output of function compute_ploidy

admixture_table

data.frame formatted as the output of function compute_dna_admixture

error_tb

data.frame that reports for each combination of coverage and number informative SNPs the expected estimation error around beta. The data.frame error_tb must contains 3 columns:

mean.cov

mean coverage

n.info.snps

number of informative SNPs

adm.estimation.error

estimated error on computed beta on a segment with coverage mean.cov and n.info.snps informative SNPs

Package CLONETv2 have built in error_tb named error_table (default=error_table)

allelic_imbalance_th

maximum distance from allele spefici copy number of a segment to define integer alelle specific copy number value. Value 0.5 corresponds to round cnA and cnB (default=0.5)

n_digits

number of digits in the output table (default=3)

n_cores

number of cores (default=1)

debug

return extra columns for debugging (default=F)

Value

A data.frame that extends input beta_table with columns

log2.corr

log2 ratio adjusted by ploidy and admixture

cnA

copy number of the major allele

cnB

copy number of the minor allele

cnA.int

integet copy number of the major allele

cnB.int

integet copy number of the minor allele

Author(s)

Davide Prandi

Examples


## Compute clonality table with default parameters
allele_specific_cna_table_toy <- compute_allele_specific_scna_table(
  beta_table = bt_toy, ploidy_table = pl_table_toy,
  admixture_table = adm_table_toy)


[Package CLONETv2 version 2.2.1 Index]