a_freq_list: Convert data frame of allele frequencies to nested lists

View source: R/data_conversion.R

a_freq_listR Documentation

Convert data frame of allele frequencies to nested lists

Description

List-izes the output of reference_allele_counts into a usable format for allelic_list

Usage

a_freq_list(D, pop_level = "collection")

Arguments

D

the long-format dataframe of counts by collection, locus, and allele, output by reference_allele_counts, to be made into a nested list

Value

a_freq_list returns a list named by loci, each element of which is a matrix containing that locus's allele count data. Rows in the matrix mark alleles, and columns collections

Examples


 # Generate a list of individual genotypes by allele from
 # the alewife data's reference allele count tables
 example(reference_allele_counts)
 ale_ac <- a_freq_list(ale_rac)

benmoran11/rubias documentation built on Feb. 1, 2024, 10:52 p.m.