Butte: Calculate timing of SCNA

View source: R/butte.R

ButteR Documentation

Calculate timing of SCNA

Description

This function estimates the timing of SCNAs for the following two scenarios. For 2:0 3:1 3:0 4:1, where an identifiable history matrix is available, this function returns the time estimate and confidence interval for each stage For SCNAs with multiple or non-indentifible matrix, this function instead returns the bounds (lower and upper) of time period for the last stage of the corresponding SCNA evolution.

Usage

Butte(
  x,
  m,
  history,
  nt,
  nb,
  qmethod = c("fullMLE", "partialMLE"),
  type = c("identifiable", "butte"),
  seqError = 0,
  bootstrapCI = NULL,
  B = 500,
  CILevel = 0.9,
  purity = 1,
  verbose = TRUE,
  returnAssignments = TRUE,
  minMutations = 10,
  init = NULL,
  maxiter = 100,
  tol = 1e-04,
  mutationId = 1:length(x),
  ...
)

Arguments

x

vector of number of reads supporting SSNVs

m

vector of total read depth for SSNVs

history

a list of possible evolutionary history matrices, see also function "cnmutHistory"

nt

total copy number

nb

copy number of the minor allele

qmethod

suggest to use fullMLE, which is more accurate

type

set it to be either "identifiable" or "butte", or leave it unset

seqError

sequencing errors

bootstrapCI

set to "bootstrap" if non-parametric; or "parametric". This specify the confidence interval method. NULL if do not want to calculate CI

B

the number of bootstrapping samples

CILevel

confidence interval level

purity

tumor sample purity

verbose

logical. Turn on/off additional warnings.

returnAssignments

logical. Whether to return the probabilistic assignments of SSNVs to allele states generated by the EM algorithm, as well as the SSNV read counts (total depth and depth of the mutant allele).

minMutations

minimum number of SSNVs required for timing analysis

init

the initial value of vector q passed to function .estimateQ

maxiter

maximum number of iterations in EM algorithm when calculating the allele state distribution

tol

the tolerance in the convergence of q

mutationId

a vector of mutation IDs. The default is 1:length of x.

Value

A list of possible matrices


SunPathLab/Butte documentation built on Sept. 19, 2023, 9:42 a.m.