A library for working with phylogenetic data.
v0.25.0
AlleleFrequencyWindow Class Reference

#include <genesis/population/window/af_spectrum.hpp>

Detailed Description

Definition at line 56 of file af_spectrum.hpp.

Public Member Functions

 AlleleFrequencyWindow (AlleleFrequencyWindow &&)=default
 
 AlleleFrequencyWindow (AlleleFrequencyWindow const &)=default
 
 AlleleFrequencyWindow (size_t width, size_t number_of_bins=100)
 
 ~AlleleFrequencyWindow ()
 
void enqueue (std::string const &chromosome, size_t position, double frequency)
 
void enqueue (VcfRecord const &record)
 
size_t number_of_bins () const
 
AlleleFrequencyWindowoperator= (AlleleFrequencyWindow &&)=default
 
AlleleFrequencyWindowoperator= (AlleleFrequencyWindow const &)=default
 
void run_vcf (std::string const &vcf_file)
 
bool skip_invalid_records () const
 
self_typeskip_invalid_records (bool value)
 

Public Types

using AFWindow = Window< double >
 
using self_type = AlleleFrequencyWindow
 
using Spectrum = HeatmapColorization::Spectrum
 

Public Attributes

std::function< void(Spectrum const &)> on_chromosome_finish
 
std::function< void(Spectrum const &)> on_chromosome_start
 

Constructor & Destructor Documentation

◆ AlleleFrequencyWindow() [1/3]

AlleleFrequencyWindow ( size_t  width,
size_t  number_of_bins = 100 
)

Definition at line 52 of file af_spectrum.cpp.

◆ ~AlleleFrequencyWindow()

Definition at line 70 of file af_spectrum.cpp.

◆ AlleleFrequencyWindow() [2/3]

◆ AlleleFrequencyWindow() [3/3]

Member Function Documentation

◆ enqueue() [1/2]

void enqueue ( std::string const &  chromosome,
size_t  position,
double  frequency 
)

Definition at line 86 of file af_spectrum.cpp.

◆ enqueue() [2/2]

void enqueue ( VcfRecord const &  record)

Definition at line 98 of file af_spectrum.cpp.

◆ number_of_bins()

size_t number_of_bins ( ) const
inline

Definition at line 92 of file af_spectrum.hpp.

◆ operator=() [1/2]

AlleleFrequencyWindow& operator= ( AlleleFrequencyWindow &&  )
default

◆ operator=() [2/2]

AlleleFrequencyWindow& operator= ( AlleleFrequencyWindow const &  )
default

◆ run_vcf()

void run_vcf ( std::string const &  vcf_file)

Definition at line 79 of file af_spectrum.cpp.

◆ skip_invalid_records() [1/2]

bool skip_invalid_records ( ) const
inline

Definition at line 97 of file af_spectrum.hpp.

◆ skip_invalid_records() [2/2]

self_type& skip_invalid_records ( bool  value)
inline

Definition at line 102 of file af_spectrum.hpp.

Member Typedef Documentation

◆ AFWindow

using AFWindow = Window<double>

Definition at line 64 of file af_spectrum.hpp.

◆ self_type

Definition at line 65 of file af_spectrum.hpp.

◆ Spectrum

Definition at line 66 of file af_spectrum.hpp.

Member Data Documentation

◆ on_chromosome_finish

std::function<void( Spectrum const& )> on_chromosome_finish

Definition at line 86 of file af_spectrum.hpp.

◆ on_chromosome_start

std::function<void( Spectrum const& )> on_chromosome_start

Definition at line 85 of file af_spectrum.hpp.


The documentation for this class was generated from the following files: