|
A library for working with phylogenetic and population genetic data.
v0.32.0
|
|
Go to the documentation of this file.
79 if (max_placements_per_edge == 0) {
86 for(
auto const& edge : smp.
tree().
edges() ) {
87 auto const placements_on_edge = place_map[ edge.index() ].size();
89 if( placements_on_edge > 0) {
92 val = placements_on_edge / max_placements_per_edge;
94 val = log( placements_on_edge ) / log( max_placements_per_edge );
PlacementTree & tree()
Get the PlacementTree of this Sample.
std::pair< PlacementTreeEdge const *, size_t > placement_count_max_edge(Sample const &smp)
Get the number of placements on the edge with the most placements, and a pointer to this edge.
Manage a set of Pqueries along with the PlacementTree where the PqueryPlacements are placed on.
Provides functions for working with Placements and Pqueries.
Container namespace for all symbols of genesis in order to keep them separate when used as a library.
Color operators and functions.
Color heat_gradient(double percentage)
Return a Color that represents a heat gradient for a given percentage value.
utils::Range< IteratorEdges > edges()
std::vector< std::vector< PqueryPlacement const * > > placements_per_edge(Sample const &smp, bool only_max_lwr_placements)
Return a mapping from each PlacementTreeEdges to the PqueryPlacements that are placed on that edge.
std::vector< utils::Color > placement_color_count_gradient(Sample const &smp, bool linear)
Returns a vector with a Color for each edge that visualizes the number of placements on that edge.
size_t edge_count() const
Return the number of TreeEdges of the Tree.