C, taxonomy: new function to get the lowest common ancestor of two taxa

This commit is contained in:
Celine Mercier
2018-11-27 16:00:29 +01:00
parent f942dd856f
commit ef8dc85f3c
2 changed files with 69 additions and 0 deletions

View File

@ -320,6 +320,18 @@ int obi_taxo_add_preferred_name_with_taxid(OBIDMS_taxonomy_p tax, int32_t taxid,
int obi_taxo_add_preferred_name_with_taxon(OBIDMS_taxonomy_p tax, ecotx_t* taxon, const char* preferred_name);
/**
* @brief Function returning the last common ancestor of two taxa.
*
* @param taxon1 A pointer on the first taxon.
* @param taxon2 A pointer on the second taxon.
*
* @returns A pointer on the last common ancestor of the two taxa.
* @retval NULL if an error occurred.
*/
ecotx_t* obi_taxo_get_lca(ecotx_t* taxon1, ecotx_t* taxon2);
/**
* @brief Function returning the parent of a taxon at a given rank.
*