5.7 mutationLoad

Estimating mutation load across the genome

mutationLoad estimates the proportion of sites in the genome which are homozygous for the preferred allele (Pi_rr), heterozygous for the preferred and any derived allele (Pi_ra), homozygous for any derived allele, with both derived alleles being the same base (Pi_aa) or heterozygous for two different derived alleles (Pi_ab). Recessive load is defined as Pi_aa + Pi_ab and dominant load is defined as Pi_ra + Pi_aa + Pi_ab.

The task accepts either a glf or a bam file as input and requires a file defining the preferred allele at every position where mutation load is estimated from. This file can take on two different formats. i) It can be in the format of an alleles file with custom preferred allele at every position, usually generated by assuming that the ancestral allele of outgroup data (the ancestral state) is the preferred allele, e.g. generated using the task alleleCounts followed by ancestralAlleles. ii) It can be in the format of a bed file. In that case, the task requires the reference genome to be provided as well and will automatically take the reference base at each position as the preferred allele.

5.7.1 Input

Required inputs :

--bam Input_bam_file.bam Input bam file (can be replaced with a glf file)
--glf Input_glf_file.glf.gz Input glf file (can be replaced with a bam file)
--alleles Input_ancestral_alleles.alleles Input alleles file defining the position to be used and the preferred allele at every position (can be replaced with a bed + reference genome)
--regions Input_regions.bed Input bed file defining the positions to be used. Using this option also requires a reference genome. (can be replaced with an alleles file)
--fasta Input_refrence_genome_file.fasta Reference genome. Required if a bed file is provided (can be replaced with an alleles file)

Example alleles file:

Chr Pos Allele1
chr1 1000 A
chr1 1001 T
chr2 3000 C

See Filter parameters to apply specific filters for bases, reads and parsing window setting. Engine parameters that are common to all tasks can be found here.

5.7.2 Output

\*_mutationLoad.txt Genomewide mutation load output file showing proportions of sites in mutation load as described above.

5.7.3 Usage Example

# Simulate a BAM File
atlas simulate --chrLength 100000

## Option 1
# Create a bed file with the positions of interest (eg. highly conserved positions).
# To simplify for this example, we create a bed file with every 7th position. Be aware that this is not a realistic example.
printf "chr1\t0\t1\n" > bed.bed
for i in {7..10000..7}; do
    printf "chr1\t$i\t$((i+1))\n" >> bed.bed
done

# Calculate mutation load using sites in bed.bed
atlas mutationLoad --bam ATLAS_simulations.bam --fasta ATLAS_simulations.fasta --regions bed.bed


## Option 2
# Create an alleles file with the positions of interest (eg. highly conserved positions) and specify the preferred allele.
# To simplify for this example, we create a bed file with every 7th position and set all preferred alleles to 'A'. Be aware that this is not a realistic example.
printf "Chr\tPos\tAllele1\n" > alleles.txt
for i in {7..10000..7}; do
    printf "chr1\t$((i+1))\tA\n" >> alleles.txt
done

# Calculate mutation load using sites in alleles.txt
atlas mutationLoad --bam ATLAS_simulations.bam --alleles alleles.txt