de.jstacs.sequenceScores.statisticalModels.differentiable.homogeneous
Class HomogeneousDiffSM

java.lang.Object
  extended by de.jstacs.sequenceScores.differentiable.AbstractDifferentiableSequenceScore
      extended by de.jstacs.sequenceScores.statisticalModels.differentiable.AbstractDifferentiableStatisticalModel
          extended by de.jstacs.sequenceScores.statisticalModels.differentiable.AbstractVariableLengthDiffSM
              extended by de.jstacs.sequenceScores.statisticalModels.differentiable.homogeneous.HomogeneousDiffSM
All Implemented Interfaces:
DifferentiableSequenceScore, SequenceScore, DifferentiableStatisticalModel, SamplingDifferentiableStatisticalModel, VariableLengthDiffSM, StatisticalModel, Storable, Cloneable
Direct Known Subclasses:
HomogeneousMM0DiffSM, HomogeneousMMDiffSM, UniformHomogeneousDiffSM

public abstract class HomogeneousDiffSM
extends AbstractVariableLengthDiffSM
implements SamplingDifferentiableStatisticalModel

This is the main class for all homogeneous DifferentiableSequenceScores.

Author:
Jens Keilwagen

Field Summary
 
Fields inherited from class de.jstacs.sequenceScores.differentiable.AbstractDifferentiableSequenceScore
alphabets, length, r
 
Fields inherited from interface de.jstacs.sequenceScores.differentiable.DifferentiableSequenceScore
UNKNOWN
 
Constructor Summary
protected HomogeneousDiffSM(AlphabetContainer alphabets)
          This is the main constructor that creates an instance of a HomogeneousDiffSM that models sequences of arbitrary length.
protected HomogeneousDiffSM(AlphabetContainer alphabets, int length)
          This is the main constructor that creates an instance of a HomogeneousDiffSM that models sequences of a given length.
protected HomogeneousDiffSM(StringBuffer source)
          This is the constructor for Storable.
 
Method Summary
abstract  byte getMaximalMarkovOrder()
          Returns the maximal used markov oder.
abstract  void initializeUniformly(boolean freeParams)
          This method allows to initialize the instance with an uniform distribution.
 
Methods inherited from class de.jstacs.sequenceScores.statisticalModels.differentiable.AbstractVariableLengthDiffSM
getLogNormalizationConstant, getLogPartialNormalizationConstant, getLogScoreAndPartialDerivation, getLogScoreAndPartialDerivation, getLogScoreFor, getLogScoreFor
 
Methods inherited from class de.jstacs.sequenceScores.statisticalModels.differentiable.AbstractDifferentiableStatisticalModel
clone, emitDataSet, getInitialClassParam, getLogProbFor, getLogProbFor, getLogProbFor, getLogScoreFor, getLogScoreFor, isNormalized, isNormalized
 
Methods inherited from class de.jstacs.sequenceScores.differentiable.AbstractDifferentiableSequenceScore
fromXML, getAlphabetContainer, getCharacteristics, getLength, getLogScoreAndPartialDerivation, getLogScoreFor, getNumberOfRecommendedStarts, getNumberOfStarts, getNumericalCharacteristics
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.jstacs.sequenceScores.statisticalModels.differentiable.SamplingDifferentiableStatisticalModel
getSamplingGroups
 
Methods inherited from interface de.jstacs.sequenceScores.statisticalModels.differentiable.DifferentiableStatisticalModel
addGradientOfLogPriorTerm, getESS, getLogNormalizationConstant, getLogPartialNormalizationConstant, getLogPriorTerm, getSizeOfEventSpaceForRandomVariablesOfParameter, isNormalized
 
Methods inherited from interface de.jstacs.sequenceScores.differentiable.DifferentiableSequenceScore
clone, getCurrentParameterValues, getInitialClassParam, getLogScoreAndPartialDerivation, getLogScoreAndPartialDerivation, getLogScoreAndPartialDerivation, getNumberOfParameters, getNumberOfRecommendedStarts, initializeFunction, initializeFunctionRandomly, setParameters
 
Methods inherited from interface de.jstacs.sequenceScores.statisticalModels.StatisticalModel
emitDataSet, getLogProbFor, getLogProbFor, getLogProbFor
 
Methods inherited from interface de.jstacs.sequenceScores.SequenceScore
getAlphabetContainer, getCharacteristics, getInstanceName, getLength, getLogScoreFor, getLogScoreFor, getLogScoreFor, getLogScoreFor, getLogScoreFor, getNumericalCharacteristics, isInitialized, toString
 
Methods inherited from interface de.jstacs.Storable
toXML
 
Methods inherited from interface de.jstacs.sequenceScores.statisticalModels.differentiable.VariableLengthDiffSM
getLogNormalizationConstant, getLogPartialNormalizationConstant, setStatisticForHyperparameters
 

Constructor Detail

HomogeneousDiffSM

protected HomogeneousDiffSM(AlphabetContainer alphabets)
This is the main constructor that creates an instance of a HomogeneousDiffSM that models sequences of arbitrary length.

Parameters:
alphabets - the AlphabetContainer

HomogeneousDiffSM

protected HomogeneousDiffSM(AlphabetContainer alphabets,
                            int length)
This is the main constructor that creates an instance of a HomogeneousDiffSM that models sequences of a given length.

Parameters:
alphabets - the AlphabetContainer
length - the length of the modeled sequences

HomogeneousDiffSM

protected HomogeneousDiffSM(StringBuffer source)
                     throws NonParsableException
This is the constructor for Storable. Creates a new HomogeneousDiffSM out of its XML representation.

Parameters:
source - the XML representation as StringBuffer
Throws:
NonParsableException - if the XML representation could not be parsed
Method Detail

getMaximalMarkovOrder

public abstract byte getMaximalMarkovOrder()
Returns the maximal used markov oder.

Specified by:
getMaximalMarkovOrder in interface StatisticalModel
Overrides:
getMaximalMarkovOrder in class AbstractDifferentiableStatisticalModel
Returns:
the maximal used markov oder

initializeUniformly

public abstract void initializeUniformly(boolean freeParams)
This method allows to initialize the instance with an uniform distribution.

Parameters:
freeParams - a switch whether to take only free parameters or to take all