mapply.rv {rv} | R Documentation |
mapply.rv
is a rv-compatible version of mapply
.
It repeats the function FUN
for each joint draw of the
random (or constant) arguments.
mapply.rv(FUN, ..., MoreArgs=NULL, USE.NAMES=TRUE, SAMPLESIZE=NULL)
FUN |
the function to apply to the simulations of X . |
MoreArgs |
Other args passed to FUN `as is' |
USE.NAMES |
logical; see mapply for details |
SAMPLESIZE |
number of simulations to process. This should be not specified whenever the function is numeric. |
... |
further arguments to FUN , possibly random vectors or array. |
mapply.rv
applies a given function to each
simulation (vector or array) of the given random vectors,
returning a the results as a random vector or array.
Usually used in functions that implement an 'rv'-compatible routine.
For an example of a function that uses SAMPLESIZE
,
abline
.
Depends on FUN
; a random vector or array if FUN
is numeric.
If the function (FUN
) has an argument ``FUN
",
it must be specified within the list supplied to MoreArgs
.
Jouni Kerman kerman@stat.columbia.edu http://www.stat.columbia.edu/~kerman
Kerman, Jouni and Gelman, Andrew. Manipulating and Summarizing Posterior Simulations Using Random Variable Objects. Technical report, Columbia University, New York.
#