calculate_alignment_stats: Calculate summary statistics for an alignment.

Description Usage Arguments Value

Description

Including the original alignment in the output with include_aln can be useful for mapping calculate_alignment_stats over a list of alignments with map_df to sort and filter alignments by their summary statistics.

Usage

1
2
3
4
5
6
calculate_alignment_stats(
  alignment,
  cutoff = 120,
  cutoff_any = FALSE,
  include_aln = FALSE
)

Arguments

alignment

Input alignment; must be a matrix of class "DNAbin".

cutoff

Numeric value indicating minimum exon length (optional); flag this alignment if any/all exons are less than the cutoff length.

cutoff_any

Logical; Should the alignment be flagged if any exons are shorter than the cutoff? The default, FALSE, means that the alignment will only be flagged if all exons are shorter than the cutoff value.

include_aln

Logical; Should the original alignment be included in the output list?

Value

A list including the following summary statistics:

intron_lengths

List including vector of intron lengths

exon_lengths

List including vector of exon lengths

num_introns

Number of introns

num_exons

Number of introns

mean_dist

Mean genetic distance between sequences in alignment

max_dist

Maximum genetic distance between sequences in alignment

GC_content

Total %GC content

pars_inf

Fraction of sites that are parsimony informative

total_exon_length

Total exon length

less_than_cutoff

Logical flag indicating whether alignment passed the minimum exon length cutoff or not

alignment

The original input alignment


joelnitta/baitfindR documentation built on May 7, 2020, 6:21 p.m.