get_datelife_result_datelifequery: Get a list of patristic matrices from a given 'datelifeQuery'...

View source: R/datelife_result.R

get_datelife_result_datelifequeryR Documentation

Get a list of patristic matrices from a given datelifeQuery object

Description

Get a list of patristic matrices from a given datelifeQuery object

Usage

get_datelife_result_datelifequery(
  datelife_query = NULL,
  partial = TRUE,
  cache = "opentree_chronograms",
  update_opentree_chronograms = FALSE,
  ...
)

Arguments

datelife_query

A datelifeQuery object, usually an output of make_datelife_query().

partial

Whether to return or exclude partially matching source chronograms, i.e, those that match some and not all of taxa given in datelife_query. Options are TRUE or FALSE. Defaults to TRUE: return all matching source chronograms.

cache

A character vector of length one, with the name of the data object to cache. Default to "opentree_chronograms", a data object storing Open Tree of Life's database chronograms and other associated information.

update_opentree_chronograms

Whether to update the chronogram database or not. Defaults to FALSE.

...

Arguments passed on to make_datelife_query

input

Taxon names as one of the following:

A character vector of taxon names

With taxon names as a single comma separated starting or concatenated with c().

A phylogenetic tree with taxon names as tip labels

As a phylo or multiPhylo object, OR as a newick character string.

use_tnrs

Whether to use Open Tree of Life's Taxonomic Name Resolution Service (TNRS) to process input taxon names. Default to TRUE, it corrects misspellings and taxonomic name variations with tnrs_match(), a wrapper of rotl::tnrs_match_names().

get_spp_from_taxon

Whether to search ages for all species belonging to a given taxon or not. Default to FALSE. If TRUE, it must have same length as input. If input is a newick string with some clades it will be converted to a phylo object, and the order of get_spp_from_taxon will match phy$tip.label.

reference_taxonomy

A character vector specifying the reference taxonomy to use for TNRS. Options are "ott", "ncbi", "gbif" or "irmng". The function defaults to "ott".

Details

If there is just one taxon name in input$cleaned_names, the function will run make_datelife_query() setting get_spp_from_taxon = TRUE. The datelifeQuery used as input can be accessed with attributes(datelifeResult)$query.

Value

A datelifeResult object – a named list of patristic matrices.


datelife documentation built on July 10, 2023, 2:02 a.m.