Description Usage Arguments Details Value
View source: R/calculate_change.R
Change in response variables between a climate reference condition (or scenario family) and each climate condition is calculated as
x[condition k] - x[reference]
if method
is "absolute"
(x[condition k] - x[reference]) / x[reference]
if method
is "relative"
the result of compare_direction_2deltas
if method
is "direction"
the result of (x[condition k] > tol, x[condition k] < tol)
if method
is relative direction, i.e., "rdirection"
1 2 3 4 5 6 7 | calc_change_from_reference(
data,
ref_condition,
sc_hist = NULL,
method = c("absolute", "relative", "direction", "rdirection"),
...
)
|
data |
A four-dimensional numerical |
ref_condition |
A vector of character strings. Each element is used as reference to calculate a separate set of change values. |
sc_hist |
A character string. The name of the historical scenario that
is the same for each other (future) projection; or |
method |
A character string. See description. |
... |
Additional arguments, e.g.,
|
If reference
is the same for
each scenario, e.g., "current", then the same value is used for each
condition k
; if reference
is a scenario family, e.g., "RCP45",
then the appropriate x
values per GCM are used.
A list of four-dimensional numerical array
with dimensions
runsN_sites
, variables
, scenarios
,
and experiments
; each element is named as delta_ref_met
where ref is one of ref_condition
and met is the
first three letters of method
and the value of tol
if
provided.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.