Take a vector fobs
of performances of assemblages
and return a vector of performances
predicted as the arithmetic mean
of performances of assemblages
that share a same assembly motif
and that contain the same components as the assemblage to calibrate.
The assembly motifs are labelled in the vector assMotif
.
The component composition of assemblages is specified
in the binary matrix mOccur
:
0
if the component does not occur,
1
if the component occurs.
calibrate_amean_byelt_xpr(fobs, assMotif, mOccur, xpr)
a numeric vector. The vector fobs
contains the
quantitative performances of assemblages.
a vector of labels of length(fobs)
.
The vector assMotif
contains the assembly motifs of assemblages.
a matrix of occurrence (occurrence of components).
Its first dimension equals to length(fobs)
. Its second dimension
equals to the number of components.
a vector of numerics of length(fobs)
.
The vector xpr
contains the weight of each experiment,
and the labels (in names(xpr)
) of different experiments.
The weigth of each experiment is used
in the computation of the Residual Sum of Squares
in the function rss_clustering
.
All assemblages that belong to a given experiment
should then have a same weigth.
Each experiment is identified by its names (names(xpr)
)
and the RSS of each experiment is weighted by values of xpr
.
The vector xpr
is generated
by the function stats::setNames
.
Return a vector of length(fobs)
.
Its values are computed as the average
of mean performances of assemblages
that share the same assembly motif
and that contain the same components
as the assemblage to calibrate opt.model = "byelt"
.
Modelled performances are computed
using arithmetic mean (opt.mean = "amean"
) of performances.
Assemblages share a same assembly motif.
Modelled performances are the average
of mean performances of assemblages that contain the same components
as the assemblage to calibrate (opt.model = "byelt"
).
This procedure corresponds to a linear model with each assembly motif
based on the component occurrence in each assemblage.
If no assemblage contains component belonging to assemblage to calibrate,
performance is the mean performance of all assemblages.
calibrate_amean_bymot_xpr
arithmetic mean
by assembly motif.
calibrate_amean_byelt_xpr
arithmetic mean
by elements occurring within assembly motif.
calibrate_gmean_bymot_xpr
geometric mean
by assembly motif.
calibrate_gmean_byelt_xpr
geometric mean
by elements occurring within assembly motif.