powered by
For genotype data (markers x individuals) on a set of individuals, count the unique genotypes for each marker
count_unique_geno(genotypes, na.strings = c("N", "H", "NA", ""), cores = 1)
Vector of counts of unique genotypes.
Matrix of genotypes (markers x individuals)
Genotypes to be considered as missing values.
Number of CPU cores to use, for parallel calculations. (If 0, use parallel::detectCores().) Alternatively, this can be links to a set of cluster sockets, as produced by parallel::makeCluster().
0
parallel::detectCores()
parallel::makeCluster()
find_unique_geno()
g <- rbind(c("NA", "A", "A", "A", "T"), c("NA", "NA", "NA", "A", "A"), c("A", "A", "T", "G", "G"), c("C", "C", "G", "G", "NA")) counts <- count_unique_geno(g)
Run the code above in your browser using DataLab