Skip to contents

Utilities for variant allele frequency

Usage

make_vaf(graph, samples, mu)

make_longer_vaf(graph, samples, mu, threshold = 0.05)

longer_vaf(vaf)

filter_detectable(vaf, threshold)

sort_vaf(vaf, method = c("average", "ward.D2", "complete", "single"))

Arguments

graph

igraph

samples

list of integer IDs

mu

mutation rate per cell division (ignored if segsites is given)

threshold

minimum detectable frequency

vaf

output of make_vaf()

method

passed to stats::hclust

Details

make_vaf generates neutral VAF pattern from cell genealogy.

make_longer_vaf is a shortcut to make VAF in longer format.

longer_vaf transforms vaf table.

filter_detectable removes sites where freq < threshold.

sort_vaf reorders rows and columns of VAF table.