segSites2allDoses: Site frequency spectrum

View source: R/quantgen.R

segSites2allDosesR Documentation

Site frequency spectrum

Description

Convert the SFS of independent replicates into a matrix of allele doses.

Usage

segSites2allDoses(seg.sites, ind.ids = NULL, snp.ids = NULL, verbose = 0)

Arguments

seg.sites

list of haplotypes returned by scrm::scrm, each component of which corresponds to a matrix with haplotypes in rows and SNP in columns

ind.ids

vector with the identifiers of the genotypes

snp.ids

vector with the identifiers of the SNPs (if NULL, the SNP identifiers from seg.sites will be used if they aren't NULL, too)

verbose

verbosity level (0/1)

Value

matrix with diploid genotypes in rows and SNPs in columns

Author(s)

Timothee Flutre


timflutre/rutilstimflutre documentation built on Feb. 7, 2024, 8:17 a.m.