A library for working with phylogenetic and population genetic data.
v0.27.0
variant_input_iterator.hpp File Reference

Go to the source code of this file.

Classes

struct  VariantInputIteratorData
 Data storage for input-specific information when traversing a variant file. More...
 

Namespaces

 genesis
 Container namespace for all symbols of genesis in order to keep them separate when used as a library.
 
 genesis::population
 

Typedefs

using VariantInputIterator = utils::LambdaIterator< Variant, VariantInputIteratorData >
 Iterate Variants, using a variety of input file formats. More...
 

Functions

VariantInputIterator make_variant_input_iterator_from_individual_vcf_file (std::string const &filename, bool use_allelic_depth=false, bool only_biallelic=true, bool only_filter_pass=true)
 Create a VariantInputIterator to iterate the contents of a VCF file as Variants, treating each sample as an individual, and combining them all into one BaseCounts sample. More...
 
VariantInputIterator make_variant_input_iterator_from_individual_vcf_file (std::string const &filename, std::vector< std::string > const &sample_names, bool inverse_sample_names=false, bool use_allelic_depth=false, bool only_biallelic=true, bool only_filter_pass=true)
 Create a VariantInputIterator to iterate the contents of a VCF file as Variants, treating each sample as an individual, and combining them all into one BaseCounts sample. More...
 
VariantInputIterator make_variant_input_iterator_from_pileup_file (std::string const &filename, SimplePileupReader const &reader=SimplePileupReader{})
 Create a VariantInputIterator to iterate the contents of a (m)pileup file as Variants. More...
 
VariantInputIterator make_variant_input_iterator_from_pileup_file (std::string const &filename, std::vector< bool > const &sample_filter, SimplePileupReader const &reader=SimplePileupReader{})
 Create a VariantInputIterator to iterate the contents of a (m)pileup file as Variants. More...
 
VariantInputIterator make_variant_input_iterator_from_pileup_file (std::string const &filename, std::vector< size_t > const &sample_indices, bool inverse_sample_indices=false, SimplePileupReader const &reader=SimplePileupReader{})
 Create a VariantInputIterator to iterate the contents of a (m)pileup file as Variants. More...
 
VariantInputIterator make_variant_input_iterator_from_pool_vcf_file (std::string const &filename, bool only_biallelic=true, bool only_filter_pass=true)
 Create a VariantInputIterator to iterate the contents of a VCF file as Variants, treating each sample as a pool of individuals. More...
 
VariantInputIterator make_variant_input_iterator_from_pool_vcf_file (std::string const &filename, std::vector< std::string > const &sample_names, bool inverse_sample_names=false, bool only_biallelic=true, bool only_filter_pass=true)
 Create a VariantInputIterator to iterate the contents of a VCF file as Variants, treating each sample as a pool of individuals. More...
 
VariantInputIterator make_variant_input_iterator_from_sam_file (std::string const &filename, SamVariantInputIterator const &reader=SamVariantInputIterator{})
 Create a VariantInputIterator to iterate the contents of a SAM/BAM/CRAM file as Variants. More...
 
VariantInputIterator make_variant_input_iterator_from_sync_file (std::string const &filename)
 Create a VariantInputIterator to iterate the contents of a PoPoolation2 sync file as Variants. More...
 
VariantInputIterator make_variant_input_iterator_from_sync_file (std::string const &filename, std::vector< bool > const &sample_filter)
 Create a VariantInputIterator to iterate the contents of a PoPoolation2 sync file as Variants. More...
 
VariantInputIterator make_variant_input_iterator_from_sync_file (std::string const &filename, std::vector< size_t > const &sample_indices, bool inverse_sample_indices=false)
 Create a VariantInputIterator to iterate the contents of a PoPoolation2 sync file as Variants. More...
 
VariantInputIterator make_variant_input_iterator_from_variant_parallel_input_iterator (VariantParallelInputIterator const &parallel_input, bool allow_ref_base_mismatches=false, bool allow_alt_base_mismatches=true, std::string const &source_sample_separator=":")
 Create a VariantInputIterator to iterate multiple input sources at once, using a VariantParallelInputIterator. More...