View source: R/graphab_capacity.R
graphab_capacity | R Documentation |
The function computes custom capacities of patches in the Graphab project
graphab_capacity( proj_name, mode = "area", patch_codes = NULL, exp = NULL, ext_file = NULL, thr = NULL, linkset = NULL, codes = NULL, cost_conv = FALSE, weight = FALSE, proj_path = NULL, alloc_ram = NULL )
proj_name |
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. It can be created with |
mode |
A character string indicating the way capacities are computed. It must be either:
|
patch_codes |
(optional, default=NULL) An integer value or vector
specifying the codes corresponding to the habitat pixel whose corresponding
patches are included to compute the capacity as the area of the habitat
when |
exp |
An integer value specifying the power to which patch area are
raised when |
ext_file |
A character string specifying the name of the .csv file in
which patch capacities are stored. It must be located either in the working
directory or in the directory defined by |
thr |
(optional, default=NULL) An integer or numeric value indicating
the maximum distance in cost distance units (except when
|
linkset |
(optional, default=NULL) A character string indicating the
name of the link set used to take distance into account when computing
the capacity. Only used when |
codes |
An integer value or a vector of integer values specifying the
codes of the raster cells taken into account when computing the capacity in
the neighbourhood of the patches, when |
cost_conv |
FALSE (default) or TRUE. Logical indicating whether numeric
|
weight |
A logical indicating whether the cells are weighted by a weight decreasing with the distance from the patches (TRUE) or not (FALSE). The weights follow a negative exponential decline such that wi = exp(-alpha*di), where wi is the weight of cell i, di its distance from the patch and alpha a parameter determined such that wi = 0.05 when di = thr. |
proj_path |
(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 |
alloc_ram |
(optional, default = NULL) Integer or numeric value indicating RAM gigabytes allocated to the java process. Increasing this value can speed up the computations. Too large values may not be compatible with your machine settings. |
See more information in Graphab 2.8 manual: https://sourcesup.renater.fr/www/graphab/download/manual-2.8-en.pdf Be careful, when capacity has been changed. The last changes are taken into account for subsequent calculations in a project.
P. Savary
## Not run: graphab_capacity(proj_name = "grphb_ex", mode = "area") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.