dupGenotypes: Duplicate Genotypes

View source: R/dupGenotypes.R

dupGenotypesR Documentation

Duplicate Genotypes

Description

Identify duplicate or very similar genotypes.

Usage

dupGenotypes(g, num.shared = 0.8)

Arguments

g

a gtypes object.

num.shared

either number of loci or percentage of loci two individuals must share to be considered duplicate individuals.

Value

if no duplicates are present, the result is NULL, otherwise a data frame with the following columns is returned:

ids.1, ids.2 sample ids.
strata.1, strata.2 sample stratification.
mismatch.loci loci where the two samples do not match.
num.loci.genotyped number of loci genotyped for both samples.
num.loci.shared number of loci shared (all alleles the same) between both samples.
prop.loci.shared proportion of loci genotyped for both samples that are shared.

Author(s)

Eric Archer eric.archer@noaa.gov

Examples

data(msats.g)

# identify potential duplicates in Coastal strata
coastal <- msats.g[, , "Coastal"]
coastal.5 <- coastal[getIndNames(coastal)[1:5], , ]
dupes <- dupGenotypes(coastal.5)
dupes


EricArcher/strataG documentation built on Feb. 12, 2023, 4:11 a.m.