org.biojava.bio.dist
Interface OrderNDistribution
- All Superinterfaces:
- Changeable, Distribution
- All Known Implementing Classes:
- AbstractOrderNDistribution
- public interface OrderNDistribution
- extends Distribution
Provides an N'th order distribution. This is a distribution over one
alphabet which is conditioned on having previously observed one or
more other symbols (potentially from different alphabets).
Order-N distributions are always over a CrossProductAlphabet.
Note: Unlike normal distributions, the total weights for
all symbols in the overall alphabet do not sum to 1.0. Instead,
the weights of each sub-distribution should sum to 1.0.
This would typically be used in conjunction with an OrderNSymbolList.
- Author:
- Thomas Down, Samiul Hasan, Matthew Pocock
getConditioningAlphabet
public Alphabet getConditioningAlphabet()
- Get the conditioning alphabet of this distribution. If the `overall'
alphabet is a cross-product of two alphabets, this will be the first
of those alphabets. If it is a cross-product of more than two alphabets,
the conditioning alphabet is the cross-product of all but the last
alphabet.
getConditionedAlphabet
public Alphabet getConditionedAlphabet()
- Get the conditioned alphabet. This is the last alphabet in the
distribution's overall cross-product. It will be the alphabet of
all the sub-distributions contained within this OrderNDistribution.
conditionedDistributions
public java.util.Collection conditionedDistributions()
setDistribution
public void setDistribution(Symbol sym,
Distribution dist)
throws IllegalSymbolException,
IllegalAlphabetException
- Throws:
IllegalSymbolException
IllegalAlphabetException
getDistribution
public Distribution getDistribution(Symbol sym)
throws IllegalSymbolException
- Throws:
IllegalSymbolException