Identifies mutations that occur multiple times at the same genomic location across different cells in a lineage.

identify_recurrent_mutations(cell_mutations)

Arguments

cell_mutations

Data frame containing mutation information with columns: clone, cell_index, haplotype, chrom, pos, time

Value

A data frame containing only the recurrent mutations (mutations that appear more than once at the same genomic location)

Details

This function identifies recurrent mutations by:

  1. Creating a unique key for each mutation based on its haplotype, chromosome, and position

  2. Identifying duplicate keys, which indicate the same mutation occurring multiple times

  3. Extracting and returning only the recurrent mutations