A toolkit for working with phylogenetic data.
v0.24.0
balances.hpp File Reference
#include "genesis/tree/tree.hpp"
#include "genesis/utils/containers/matrix.hpp"
#include <vector>
#include <unordered_set>

Go to the source code of this file.

Classes

struct  BalanceData
 Data needed to calculate balances. More...
 
struct  BalanceSettings
 Settings to calculate balances and the Phylogenetic ILR Transform. More...
 

Namespaces

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

Functions

std::vector< double > mass_balance (BalanceData const &data, std::unordered_set< size_t > const &numerator_edge_indices, std::unordered_set< size_t > const &denominator_edge_indices)
 Calculate the balance of edge masses between two sets of edges. More...
 
double mass_balance (BalanceData const &data, std::unordered_set< size_t > const &numerator_edge_indices, std::unordered_set< size_t > const &denominator_edge_indices, size_t tree_index)
 Calculate the balance of edge masses between two sets of edges. More...
 
BalanceData mass_balance_data (std::vector< MassTree > const &trees, BalanceSettings settings={})
 Calculate the data needed to calculate balances on MassTrees. More...
 
BalanceData mass_balance_data (MassTree const &tree, BalanceSettings settings={})
 Calculate the data needed to calculate balances of a MassTree. More...