public class DiscreteHMM extends HiddenMarkovModel
Constructor and Description |
---|
DiscreteHMM(DiscreteHMM model)
Copy constructor.
|
DiscreteHMM(Vector PI,
Matrix A,
Matrix B)
Constructs a discrete hidden Markov model.
|
Modifier and Type | Method and Description |
---|---|
ImmutableMatrix |
B()
Gets the conditional probabilities of the observation symbols: rows
correspond to state; columns corresponds symbols.
|
double |
density(int state,
double observation)
Gets the (conditional) probability mass of making an observation in a
particular state.
|
int |
nSymbols()
Gets the number of observation symbols per state.
|
logProbability, logProbability, logProbability
next, nextDouble, seed
public DiscreteHMM(Vector PI, Matrix A, Matrix B)
PI
- the initial state probabilitiesA
- the state transition probabilitiesB
- the conditional probabilities of the observation symbols: rows
correspond to state; columns corresponds symbolspublic DiscreteHMM(DiscreteHMM model)
model
- a HiddenMarkovModel
public ImmutableMatrix B()
public int nSymbols()
public double density(int state, double observation)
density
in class HiddenMarkovModel
state
- the hidden state label, counting from 1observation
- the observation valueCopyright © 2010-2020 NM FinTech Ltd.. All Rights Reserved.