simapply                 package:rv                 R Documentation

_A_p_p_l_y _a _F_u_n_c_t_i_o_n _t_o _R_o_w_s _o_f _R_a_n_d_o_m _V_e_c_t_o_r_s

_D_e_s_c_r_i_p_t_i_o_n:

     'simapply' applies a given function 'FUN' to each row of the
     simulation matrix, returning an rv object.

_U_s_a_g_e:

     simapply(x, FUN, ...)

_A_r_g_u_m_e_n_t_s:

       x: a rv object

     FUN: a function

     ...: further arguments passed to 'FUN'

_D_e_t_a_i_l_s:

     'simapply' ...

_A_u_t_h_o_r(_s):

     Jouni Kerman kerman@stat.columbia.edu <URL:
     http://www.stat.columbia.edu/~kerman>

_R_e_f_e_r_e_n_c_e_s:

     Kerman, Jouni and Gelman, Andrew. Manipulating and Summarizing
     Posterior Simulations Using Random Variable Objects. Technical
     report, Columbia University, New York.

_E_x_a_m_p_l_e_s:

       #
       x <- rvnorm(10)
       simapply(x, mean) # Same result as that of mean(x).

