list_array_join: Join similar lists along array-nodes.

Description Usage Arguments Value

View source: R/list_array_join.R

Description

This function simplifies the task of joining list whose nodes are arrays. This can occur when some computations must be performed in smaller chunks due to large intermediate objects, whereas the resulting lists of arrays themselves are rather small, e.g. when some statistics are to be computed during a bootstrap procedure.

Usage

1
list_array_join(..., array_nodes, .class = "array")

Arguments

...

A collection of similarly shaped lists that all have one ore more array-nodes that should be joined together. Any arguments that are NULL will be ignored. Note that the arrays (at the nodes) must have the same number of dimensions with properly named dimension names. The dimension names of these arrays must pairwise have empty intersections. In the cases where the first list have a node that only contains a single number, it will be assumed that this is a feature that is common for all the other lists, and the number from the first list will be used in the result.

array_nodes

A list containing the vector-bookmarks that specifies the array-nodes to be collected.

.class

A character-string, default "array" that specifies the class to be used for the merged arrays.

Value

A single list where the array-nodes from the lists detected in ... have been joined together. The other components of the lists are assumed to be identical, and the values from the first list will be used for these.


LAJordanger/leanRcoding documentation built on Feb. 27, 2020, 4:42 p.m.