| external_volume_method_registry | R Documentation |
Return the registry of external volume methods used by
externalMetrics2Vol() and related external-inventory workflows.
The function starts from the package defaults, optionally uses a
user-supplied registry, then applies named overrides stored in
option "basifoR.external_volume_methods".
external_volume_method_registry(methods = get0("external_volume_methods",
inherits = TRUE,
ifnotfound = NULL))
methods |
Optional named When |
The function only assembles and validates the registry. It does not
evaluate volume equations by itself.
A named list of external volume-method definitions. The list
always includes the package defaults, updated by any entries supplied
in methods and then by any entries found in option
"basifoR.external_volume_methods". Each element is expected
to be compatible with new_volume_method().
Wilson Lara [aut, cre] (ORCID: <https://orcid.org/0000-0003-3527-1380>), Cristobal Ordonez [aut] (ORCID: <https://orcid.org/0000-0001-5354-3760>), Aitor Vázquez-Veloso [aut] (ORCID: <https://orcid.org/0000-0003-0227-506X>), Felipe Bravo [aut] (ORCID: <https://orcid.org/0000-0001-7348-6695>)
reg <- external_volume_method_registry()
names(reg)
custom <- list(
V = new_volume_method(
output = "v",
unit = "m3",
raw_unit = "m3",
scale_to_m3 = 1,
build_args = function(ctx, pars, resolved) list(),
fallback = function(ctx, pars, resolved) 0,
match_by = character(0),
required_inputs = "v"
)
)
reg2 <- external_volume_method_registry(custom)
reg2$V$output
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.