apply.rv: Apply Functions over Margins of Random Arrays
Description
The rv-compatible version of apply
Usage
## S3 method for class 'rv':
apply(X, MARGIN, FUN, \dots)
Arguments
X
a random array
MARGIN
subscripts.
FUN
function.
...
optional arguments to FUN.
Details
This is the rv-compatible version of the function apply.
Since apply is not a generic function,
the whole name apply.rv must be specified when calling the function.
References
Kerman, J. and Gelman, A. (2007). Manipulating and Summarizing
Posterior Simulations Using Random Variable Objects.
Statistics and Computing 17:3, 235-244.