Identification and estimation of hidden Markov models