View source: R/acdc_simplify.R
acdc_simplify | R Documentation |
This function simplifies the output of ac
, dc
and acdc
, by processing information from the 'archive' elements of an acdc_archive-class
object that hold the results of calls to the workhorse routines. This is especially useful if the algorithm(s) have been applied chunk-wise, in which case the results for each chunk are returned in a list. The function aggregates information across chunks to generate a continuous time series of results and a map of the expected proportion of time steps spent in each grid cell.
acdc_simplify(
archive,
type = c("acs", "dc"),
mask = NULL,
normalise = TRUE,
keep_chunks = FALSE
)
archive |
An |
type |
A character that defines whether the function should be implemented for the outputs of a call to an AC* algorithm ( |
mask |
(optional) A spatial mask (e.g., the argument passed to |
normalise |
A logical input that defines whether or not to normalise the overall map so that cell scores sum to one. If |
keep_chunks |
A logical variable that defines whether or not to retain all chunk-specific information. |
If the ac
, dc
or acdc
function was implemented step-wise, this function simply extracts the necessary information and re-packages it into an acdc_record-class
object. For a chunk-wise implementation, the function (a) computes the map of where the individual could have spent more or less time by aggregating the chunk-specific maps) and (b) simplifies chunk-specific records into a single contiguous time series, with re-defined time stamps from the start to the end of the time series (for AC* algorithm(s)) to return an acdc_record-class
object.
The function returns an object of class acdc_record-class
.
Edward Lavender
The AC, DC and ACDC algorithms are implemented by ac
, dc
and acdc
. After simplification, acdc_plot_trace
, acdc_plot_record
and acdc_animate_record
can be implemented to visualise time-specific results.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.