Description Usage Arguments Details Value Author(s) Examples
The inbreedR
working format is an i * l genotype matrix, whereby each individual is a row
and each column is a locus.
Heterozygosity at a given locus should be coded as 1
, homozygosity as 0
and missing values
should be coded as NA
.
1 | check_data(genotypes, num_ind = NULL, num_loci = NULL)
|
genotypes |
|
num_ind |
Number of individuals |
num_loci |
Number of loci / markers |
Checks that (1) the genotype data just contains 3 elements, which is 0
for homozygote,
1
for heterozygote and NA
for missing data, (2) the number
of individuals corresponds to the number of rows and the number of loci corresponds to the
number of columns, (3) the data type is numeric.
.
TRUE if the data format is correct, error message if any test failed
Martin A. Stoffel (martin.adam.stoffel@gmail.com)
1 2 3 4 5 | data(mouse_msats)
# tranform raw genotypes into 0/1 format
genotypes <- convert_raw(mouse_msats)
# check data
check_data(genotypes, num_ind = 36, num_loci = 12)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.