check_divent_args {divent}R Documentation

check_divent_args

Description

Checks the arguments of a function of the package divent

Usage

check_divent_args(
  abundances = NULL,
  alpha = NULL,
  as_numeric = NULL,
  check_arguments = NULL,
  coverage_estimator = NULL,
  distances = NULL,
  estimator = NULL,
  gamma = NULL,
  jack_alpha = NULL,
  jack_max = NULL,
  k = NULL,
  level = NULL,
  n_simulations = NULL,
  normalize = NULL,
  probability_estimator = NULL,
  q = NULL,
  rate = NULL,
  richness_estimator = NULL,
  sample_coverage = NULL,
  show_progress = NULL,
  similarities = NULL,
  species_distribution = NULL,
  tree = NULL,
  use.names = NULL,
  unveiling = NULL,
  weights = NULL
)

Arguments

abundances

An object of class abundances.

alpha

The risk level, 5% by default.

as_numeric

If TRUE, a number or a numeric vector is returned rather than a tibble.

check_arguments

If TRUE, the function arguments are verified. Should be set to FALSE to save time when the arguments have been checked elsewhere.

coverage_estimator

An estimator of sample coverage used by coverage.

distances

A distance matrix or an object of class stats::dist

estimator

An estimator of asymptotic entropy, diversity or richness.

gamma

If TRUE, \gamma diversity, i.e. diversity of the metacommunity, is computed.

jack_alpha

The risk level, 5% by default, used to optimize the jackknife order.

jack_max

The highest jackknife order allowed. Default is 10.

k

The order of Hurlbert's diversity.

level

The level of interpolation or extrapolation. It may be a sample size (an integer) or a sample coverage (a number between 0 and 1). If not NULL, the asymptotic estimator is ignored.

n_simulations

The number of simulations used to estimate the confidence envelope.

normalize

If TRUE, phylogenetic is normalized: the height of the tree is set to 1.

probability_estimator

A string containing one of the possible estimators of the probability distribution (see probabilities). Used only for extrapolation.

q

The order of diversity.

rate

The decay rate of the exponential similarity.

richness_estimator

An estimator of richness to evaluate the total number of species, see div_richness. Used for interpolation and extrapolation.

sample_coverage

The sample coverage of x calculated elsewhere. Used to calculate the gamma diversity of meta-communities, see details.

show_progress

If TRUE, a progress bar is shown during long computations.

similarities

A similarity matrix, that can be obtained by fun_similarity. Its default value is the identity matrix.

species_distribution

An object of class species_distribution.

tree

An ultrametric, phylogenetic tree. May be an object of class phylo_divent, ape::phylo, ade4::phylog or stats::hclust.

use.names

if TRUE, the names of the species_distribution are kept in the matrix or vector they are converted to.

unveiling

A string containing one of the possible unveiling methods to estimate the probabilities of the unobserved species (see probabilities). Used only for extrapolation.

weights

The weights of the sites of the species distributions.

Details

The function compares the arguments passed to its parent function to the type they should be and performs some extra tests, e.g. probabilities must be positive and sum to 1. It stops if an argument is not correct.

The function is always called without arguments. Its arguments exist only for documentation.

Value

Returns TRUE or stops if a problem is detected.


[Package divent version 0.4-4 Index]