aima.probability
Class RandomVariable

java.lang.Object
  extended by aima.probability.RandomVariable

public class RandomVariable
extends java.lang.Object


Constructor Summary
RandomVariable(java.util.List<java.lang.String> states)
           
RandomVariable(java.lang.String name, java.util.List<java.lang.String> states)
           
 
Method Summary
 Matrix asMatrix()
           
 RandomVariable createUnitBelief()
           
 RandomVariable duplicate()
           
 double getProbabilityOf(java.lang.String state)
           
 void normalize()
           
 void setProbabilityOf(java.lang.String state, java.lang.Double probability)
           
 java.util.List<java.lang.String> states()
           
 ParticleSet toParticleSet(HiddenMarkovModel hmm, Randomizer randomizer, int numberOfParticles)
           
 java.lang.String toString()
           
 void updateFrom(Matrix aMatrix)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RandomVariable

public RandomVariable(java.util.List<java.lang.String> states)

RandomVariable

public RandomVariable(java.lang.String name,
                      java.util.List<java.lang.String> states)
Method Detail

setProbabilityOf

public void setProbabilityOf(java.lang.String state,
                             java.lang.Double probability)

getProbabilityOf

public double getProbabilityOf(java.lang.String state)

states

public java.util.List<java.lang.String> states()

duplicate

public RandomVariable duplicate()

normalize

public void normalize()

asMatrix

public Matrix asMatrix()

updateFrom

public void updateFrom(Matrix aMatrix)

createUnitBelief

public RandomVariable createUnitBelief()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

toParticleSet

public ParticleSet toParticleSet(HiddenMarkovModel hmm,
                                 Randomizer randomizer,
                                 int numberOfParticles)