vech                package:MCMCpack                R Documentation

_E_x_t_r_a_c_t _L_o_w_e_r _T_r_i_a_n_g_u_l_a_r _E_l_e_m_e_n_t_s _f_r_o_m _a _S_y_m_m_e_t_r_i_c _M_a_t_r_i_x

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

     This function takes a symmetric matrix and extracts a list of all
     lower triangular elements.

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

       vech(x)

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

       x: A symmetric matrix.

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

     This function checks to make sure the matrix is square, but it
     does not check for symmetry (it just pulls the lower triangular
     elements).  The elements are stored in column major order.  The
     original matrix can be restored using the 'xpnd'  command.

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

     A list of the lower triangular elements.

_S_e_e _A_l_s_o:

     'xpnd'

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

        symmat <- matrix(c(1,2,3,4,2,4,5,6,3,5,7,8,4,6,8,9),4,4) 
        vech(symmat)

