Weighted Averages are a classical way of estimating the species
optima along continuous environmental variables
(a.k.a. gradients). Function wascores
is a simple function
that is mainly designed to add species scores to unimodal
ordinations (metaMDS
, sppscores
) or
ordering rows or columns to give diagonal pattern of tabulation
(vegemite
, tabasco
). It can also be used
to find species “optima” or sampling unit calibrations for
community data. For this purpose, specialized packages such
analogue are recommended (but see
calibrate.cca
).
First argument of wascores
is the variable or a matrix of
variables for which weighted averages are needed, and the second
argument is the matrix of weights. In classical approaches weights are
a community matrix, where taxon abundances define the weights. The
number of rows must match. If the first argument is for taxa
(columns), community weight matrix must be transposed.
Weighted averages “shrink”: they cannot be more extreme than
values used for calculating the averages. With expand = TRUE
,
the function “deshrinks” the weighted averages making their
weighted variance equal to the weighted variance of the
corresponding input variable. Specialized packages (such as
analogue) offer a wider range of deshrinking alternatives, but
deshrinking can also made after the analysis (see
Examples). Function eigengrad
returns the strength of
expansion as attribute shrinkage
of the wascores
result for each environmental gradient. The shrinkage equal to the
constrained eigenvalue of cca
when only this one
gradient was used as a constraint, and describes the strength of the
gradient.
With stdev = TRUE
the function estimates the unbiased
weighted standard deviation of the WA estimates using
cov.wt
. For unbiased standard deviation the virtual
number of observations is equal to inverse Simpson index of
diversity also known as Hill number N2 (see
diversity
). The numeric results can be accessed with
scores
function. Function tolerance
uses the
same algebra for weighted standard deviation, but bases the variance
on linear combination scores (constaints) variables instead of the
weighted averages of the sites like wascores
.
Weighted averages are closely linked to correspondence analysis
(ca
, cca
). Repeated use of
wascores
will converge to the first axis of unconstrained
correspondence analysis (ca
) which therefore is also
known as Reciprocal Averaging (Hill 1973). Constrained
correspondence analysis (cca
) is equivalent to
weighted averages and calibrate.cca
will return
weighted averages of the constraint with different deshrinking.