Description Usage Arguments Details Value Examples
View source: R/partitionFunctionsPARALLEL.R
partition_parallel
is A BETA TEST ONLY. partition
is used to calculate alpha, beta, and gamma diversity of both balanced
and unbalanced designs. It can be used to carry out diversity
partitioning at both single and multiple scales, as well as nested
designs. partition
can run hypothesis testing based
on distributions generated from two randomizations methods (see below).
THIS VERSION OF THE CODE IS A TEST. STILL CHECKING TO SEE IF IT GIVES
SIMILAR OUTPUT OF THE partition
FUNCTION. PARALLEL PROCESSING
ALLOWS FOR MUCH FASTER ANALYSES AND RUNTIME.
1 2 | partition_parallel(sp, h.level, low.level = 1, q = 0,
hyp.test = "INDIVIDUAL", sim.rand = 1000)
|
sp |
Data frame containing a species matrix that includes variables
coding for the different scales by which diversity is to be partitioned.
The columns containing levels by which diversity is to be partitioned
must be of class |
h.level |
Vector or list containing column names coding for the different scales by which diversity is to be partitioned. These must be in increasing scale. |
low.level |
Integer representing the lowest level of diversity to be
partitioned. This is the lowest ecologically relevant level. Defaults to
|
q |
Integer representing Hill Number q-diversity metrics. |
hyp.test |
Method of hypothesis testing to be used; for hypothesis
testing: |
sim.rand |
Integer representing the number of randomizations to be run
for hypothesis testing; defaults to |
... |
further arguments passed to or from other methods |
Diversity partitioning is a method of decomposing a total amount of
diversity (gamma - γ) into the components of mean
diversity within samples (alpha - α) and diversity
among samples (beta - β). It can be used with a wide
variety of diversity metrics, specifically the Hill Number
q-diversity metrics (Jost 2007). γ and α are
calculated using equations 3 - 6 of Chao et al. (2012), with equations 5
and 6 used when q = 1
and equations 3 and 4 used in all other
cases.
The partition
function can be applied to a variety of data
sets, including those with an unbalanced sampling design, substantial
variation in the number of individuals within those samples, and
hierarchical sampling designs (multiple nested levels).
partition
calculates alpha and beta diversity and uses
randomization to derive expected values of alpha and beta diversity that
would be obtained if individuals (INDIVIDUAL
) or samples
(SAMPLE
) were randomly distributed. This randomization allows for
significance testing of the observed diversity estimates. The statistical
rationale and operational description of INDIVIDUAL
- and
SAMPLE
-based randomization can be found in Crist et al. (2003).
The partition
function is the R equivalent of the PARTITION
software developed by Crist et al. (2003).
At the highest sampling level (h), the diversity components are calculated as follows:
Additive: β (h) = γ - α (h)
Multiplicative: β (h) = γ / α (h)
For the lower sampling levels calculated as follows:
Additive: β (i) = α (i+1) - α (i)
Multiplicative: β (i) = α (i+1) / α (i)
An object of class "partition"
. This object is a list of data
frames. Calling an object of class "partition"
will print the
$Div
and $Hyp
data frames; these data frames contain the
partitioned data and p-values from significance tests, respectively. For
more information from the object and interpretations of significance
tests, please use the summary.partition
function.
|
observed partitioned diversity |
|
p-values from significance testing |
|
expected additive Beta diversity |
|
expected multipicative Beta diversity |
|
expected alpha diversity at the lowest
ecologically important level (set by |
|
|
|
integer set by |
|
integer set by |
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
part.obj <- partition_parallel(sp = spiders.spp,
h.level = c("SAMPLE", "TREESP"),
low.level = 1,
q = 0,
hyp.test = "INDIVIDUAL",
sim.rand = 1000)
print(part.obj)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.