compdelta            package:HiddenMarkov            R Documentation

_C_o_m_p_u_t_e _M_a_r_g_i_n_a_l _D_i_s_t_r_i_b_u_t_i_o_n _o_f _S_t_a_t_i_o_n_a_r_y _M_a_r_k_o_v _C_h_a_i_n

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

     Computes the marginal distribution of a _stationary_ Markov chain
     with transition probability matrix Pi. The m discrete states of
     the Markov chain are denoted by 1, cdots, m.

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

     compdelta(Pi)

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

      Pi: is the m times m transition probability matrix of the Markov
          chain.

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

     If the Markov chain is stationary, then the marginal distribution
     delta satisfies

                         delta = delta Pi ,.

     Obviously,

                         sum_j^m delta_j = 1.

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

     A numeric vector of length m containing the marginal
     probabilities.

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

     Pi <- matrix(c(1/2, 1/2,   0,   0,   0,
                    1/3, 1/3, 1/3,   0,   0,
                      0, 1/3, 1/3, 1/3,   0,
                      0,   0, 1/3, 1/3, 1/3,
                      0,   0,   0, 1/2, 1/2),
                  byrow=TRUE, nrow=5)

     print(compdelta(Pi))

