plink-ng
plink-ng copied to clipboard
Feature Request: reading variants as sparse in pgenlibr
Hi,
We rely on the C++ pgenlibr to read PGEN format genotype data in REGENIE. The current functions available (RPgenReader::ReadIntHardcalls/RPgenReader::Read) reads in the genotype data for all samples. In the case of rare variants, it seems PGEN stores the data sparsely based on the format documentation (i.e. only indices and genotypes of carriers are stored). Could this functionality be provided in the C++ pgenlibr, i.e. a flag identifying whether a variant is stored sparsely (given its index) as well as a function that returns the indices & genotypes (or dosages) of the carriers only?
Thanks, Joelle