Learn R Programming

tidypopgen (version 0.4.3)

count_loci: Count the number of loci in a gen_tibble

Description

Count the number of loci in gen_tibble (or directly from its genotype column).

Usage

count_loci(.x, ...)

# S3 method for tbl_df count_loci(.x, ...)

# S3 method for vctrs_bigSNP count_loci(.x, ...)

Value

the number of loci

Arguments

.x

a gen_tibble, or a vector of class vctrs_bigSNP (usually the genotype column of a gen_tibble object).

...

currently unused.

Examples

Run this code
example_gt <- load_example_gt("gen_tbl")

example_gt %>% count_loci()

Run the code above in your browser using DataLab