View source: R/check_pes_inputs.r
check_pes_inputs | R Documentation |
Function used by phy_or_env_spec. checks abunds_mat, env, hosts, and hosts_phylo inputs to phy_or_env_spec to make sure there are no problems. This could include missing species in trees, incompatible dimensions, non-numeric inputs, etc. Returns an input type, which is just a string that can be "mat", "dist", "vec", "phy", or "error".
check_pes_inputs(abunds_mat, env, hosts, hosts_phylo, verbose = TRUE)
abunds_mat |
(required, see phy_or_env_spec) |
env |
(required, can be NULL, see phy_or_env_spec) |
hosts |
(required, can be NULL, see phy_or_env_spec) |
hosts_phylo |
(required, can be NULL, see phy_or_env_spec) |
verbose |
logical. Should status messages be displayed? (default: TRUE). |
string. either "mat", "dist", "vec", "phy", or "error".
# library(specificity)
# attach(endophyte)
# m <- occ_threshold(prop_abund(otutable), threshold=10)
# check_pes_inputs(m, env=metadata$Elevation, hosts=NULL, hosts_phylo=NULL)
# check_pes_inputs(m, env=NULL, hosts=metadata$PlantGenus, hosts_phylo=supertree)
# aspect_dis <- circularize2dist(metadata$Aspect, 360)
# check_pes_inputs(m, env=aspect_dis, hosts=NULL, hosts_phylo=NULL)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.