Struct MetacommunityParameters

Struct Documentation

struct MetacommunityParameters

Contains a set of metacommunity parameters that have been applied, or are to be applied, to the coalescence tree.

Public Functions

MetacommunityParameters()

Default constructor.

~MetacommunityParameters()

Trivial destructor.

MetacommunityParameters(const unsigned long &reference_in, const unsigned long &metacommunity_size_in, const long double &speciation_rate_in, const string &option_in, const unsigned long &external_reference_in)

Constructor for MetacommunityParameters, storing a previously applied metacommunity.

Parameters
  • reference_in: the metacommunity reference number
  • metacommunity_size_in: the speciation rate used for metacommunity generation
  • speciation_rate_in: size of the tested metacommunity
  • option: the metacommunity option (“simulated”, “analytical” or a path to a database)
  • external_reference: the reference for the external database

bool compare(unsigned long metacommunity_size_in, long double speciation_rate_in, const string &option_in, const unsigned long &ext_reference_in)

Compare these set of parameters with the input set. If they match, return true, otherwise return false.

Return
true if the two parameter sets are identical
Parameters
  • speciation_rate_in: speciation rate to compare with stored community parameter
  • metacommunity_size_in: size of the tested metacommunity
  • option_in: the metacommunity option (“simulated”, “analytical” or a path to a database)
  • external_reference_in: the reference for the external database

bool compare(const MetacommunityParameters &metacomm_in)

Compare these set of parameters with the input set. If they match, return true, otherwise return false.

Return
true if the two parameter sets are identical
Parameters
  • metacomm_in:

bool compare(unsigned long reference_in)

Checks if the supplied reference is the same in the metacommunity reference.

Return
Parameters
  • reference_in: the reference to check against

bool isMetacommunityOption() const

Checks if this combination of metacommunity parameters is not a null option.

Return
true if the combination is valid (i.e. not null)

void clear()

Wipes the metacommunity parameters.

MetacommunityParameters &operator=(const MetacommunityParameters &parameters)
bool operator==(const MetacommunityParameters &parameters)
bool operator!=(const MetacommunityParameters &parameters)

Public Members

unsigned long reference = {}
unsigned long metacommunity_size = {}
long double speciation_rate = {}
string option
unsigned long external_reference = {}