The function gets the values of metrics computed at the patch/node level in the Graphab project.
get_graphab_metric(
proj_name,
habitat = NULL,
graph = NULL,
metric = NULL,
proj_path = NULL
)A data.frame or list of data.frames with the values of metrics computed at the patch/node level for a given habitat type or a given graph. The data.frame indicate the type of habitat to which each node/patch corresponds, and the name of the metric includes that of the graph on which it was computed.
A character string indicating the Graphab project name. The project name is also the name of the project directory in which the file proj_name.xml is.
(default=NULL) A character string indicating the name of the habitat type for which the metric values should be returned. If NULL, there is no selection on the habitat type.
(default=NULL) A character string indicating the name of the graph for which the metric values should be returned. If NULL, there is no selection on the graph name.
(default=NULL) A character string indicating the name of the metric for which the values should be returned. If NULL, there is no selection on the metric name.
(optional) A character string indicating the path to the
directory that contains the project directory. It should be used when the
project directory is not in the current working directory. Default is NULL.
When proj_path = NULL, the project directory is equal
to getwd().
P. Savary
Only local metrics computed for patches/nodes, for a given habitat
type and from one or several graphs can be returned. Global metrics are not
allowed. When the name of a metric is given, only the values of this metric
are returned. At least one of the parameters habitat, habitat,
or metric must not be NULL.
See more information in Graphab 3.0 manual:
https://thema.umlp.fr/productions/software/graphab/download/manual-3.0-en.pdf
if (FALSE) {
get_graphab_metric(proj_name = "graphab_example",
habitat = "forest")
}
Run the code above in your browser using DataLab