dmunorm                 package:mcsm                 R Documentation

_D_e_n_s_i_t_y _f_u_n_c_t_i_o_n _o_f _t_h_e _m_u_l_t_i_v_a_r_i_a_t_e _n_o_r_m_a_l _d_i_s_t_r_i_b_u_t_i_o_n

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

     This function computes the density of the multivariate normal
     distribution N(mu,sig) in either natural or logarithmic scales.

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

     dmunorm(x, mu, sig, log = FALSE)

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

       x: Running argument of the density

      mu: Mean mu of the normal distribution

     sig: Covariance matrix sig of the normal distribution

     log: Boolean describing whether or not the output is in
          logarithmic scales

_V_a_l_u_e:

     This function returns a real number corresponding to the density
     in x in either natural or logarithmic scales.

_W_a_r_n_i_n_g:

     This function is _fragile_ in that it does not test for

        1.  the fact that 'sig' is a square matrix,

        2.  the compatibility of the dimensions of 'x', 'mu', 'sig'

        3.  the symmetry nor the invertibility of the matrix 'sig'

     It is therefore prone to fail if those conditions are not
     satified! If the package 'mvtnorm' is installed, the function
     'dmvnorm' should be used instead.

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

     Christian P. Robert and George Casella

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

     Chapter 8 of *EnteR Monte Carlo Statistical Methods*

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

     dmunorm(c(1,2),c(1,2),diag(rep(1,2)))-1/(2*pi)
     # Should be equal to zero!

