Logo Search packages:      
Sourcecode: python-biopython version File versions

def Bio::HMM::MarkovModel::MarkovModelBuilder::set_emission_pseudocount (   self,
  seq_state,
  emission_state,
  count 
)

Set the default pseudocount for an emission.

To avoid computational problems, it is helpful to be able to
set a 'default' pseudocount to start with for estimating
transition and emission probabilities (see p62 in Durbin et al
for more discussion on this. By default, all emissions have
a pseudocount of 1.

Raises:
KeyError if the emission from the given state is not allowed.

Definition at line 257 of file MarkovModel.py.

00257                                                                         :
        """Set the default pseudocount for an emission.

        To avoid computational problems, it is helpful to be able to
        set a 'default' pseudocount to start with for estimating
        transition and emission probabilities (see p62 in Durbin et al
        for more discussion on this. By default, all emissions have
        a pseudocount of 1.

        Raises:
        KeyError if the emission from the given state is not allowed.
        """
        if self.emission_pseudo.has_key((seq_state, emission_state)):
            self.emission_pseudo[(seq_state, emission_state)] = count
        else:
            raise KeyError("Emission of %s from %s is not allowed."
                           % (emission_state, seq_state))

class HiddenMarkovModel:


Generated by  Doxygen 1.6.0   Back to index