mut.lik.change: Calculate change in likelihood due to background mutations

Description Usage Arguments Value Note

View source: R/MADGiC.R

Description

This function calculates the change in likelihood for each existing mutation in the reformatted tables obtained from mut.type.converter given estimates of the relative rate parameters from fit.background.model.

Usage

1
2
  mut.lik.change(nonsil.mut.type, res, nonsilent, both_log,
    p_inframe, p_frameshift, p, r, s, epsilon, delta, gene)

Arguments

nonsil.mut.type

a reformatted mutation table that contains an extra two columns: 1. a mutation type indicator (1= transition, 2=transversion, and 3=indel), 2. SIFT score for the mutation. Second item returned from mut.type.converter.

res

a gene list obtained from generate.sel.exome and run through multiplyr for genes used for nonsilent rate estimation

nonsilent

logical value indicating whether genes are used for nonsilent rate estimation

both_log

logical value indicating whether genes are used for both silent and nonsilent rate estimation

p_inframe

numerical value representing the rate if in-frame indel mutations to A/T transitions

p_frameshift

numerical value representing the rate if frameshift indel mutations to A/T transitions

p

a vector of length 7 containing the mutation type relative rate parameters in the following order: A/T transition, A/T transversion, non-CpG transition, non-CpG transversion, CpG transition, CpG transversion, and Indel.

s

a vector of length 3 containing the relative rate parameters for the three replication timing regions (1=Early, 2=Middle, 3=Late)

epsilon

a vector of length 3 containing the relative rate parameters for the three expression levels (1=Low, 2=Medium, 3=High)

delta

vector of length 2 where the second element represents the relative rate of mutation in olfactory receptor (OR) genes compared to all others within a similar replication timing and expression level category. First element set to 1 (reference category).

gene

a list with one entry for each gene, each entry is another list of 5 elements: Ensembl name, chromosome, base pairs, replication timing region (1=Early, 2=Middle, 3=Late), and expression level (1=Low, 2=Medium, 3=High).

r

numeric value representing the relative rate parameter estimate for the ratio of mutations in genes with nonsilent vs only silent mutations (selection bias)

Value

a matrix containing the likelihood due to existing background mutations, to be utilized in calculate.bij

Note

This internal function is not intended to be called by the user.


kdkorthauer/MADGiC documentation built on June 13, 2020, 1:35 p.m.