| Modifier and Type | Field and Description |
|---|---|
protected MEMConstraint[] |
constraints
The specific constraints of this MEM.
|
| Constructor and Description |
|---|
MEM(AbstractList<int[]> constr,
int[] allAlphLen,
int[] indices)
The main constructor of a MEM.
|
MEM(int[] constraint,
int[] allAlphLen,
int[][] cond)
The main constructor of a MEM.
|
MEM(StringBuffer representation)
The constructor for the
Storable interface. |
| Modifier and Type | Method and Description |
|---|---|
MEM |
clone() |
double |
getLogPriorPart(double ess)
This method compute the prior for the current parameter ignoring some constants.
|
double |
getLogScoreFor(Sequence seq,
int start)
Returns the logarithmic score for the
sequence |
double |
getScoreFor(Sequence seq,
int start)
Returns the score for the
sequence |
String |
toString(NumberFormat nf)
This method returns some
String using a given NumberFormat. |
StringBuffer |
toXML()
This method returns an XML representation as
StringBuffer of an
instance of the implementing class. |
void |
train(SequenceIterator s,
byte algo,
TerminationCondition condition,
SafeOutputStream sostream)
This method approximates the distribution either analytically or numerically.
|
protected MEMConstraint[] constraints
public MEM(AbstractList<int[]> constr, int[] allAlphLen, int[] indices)
constr - the constraintsallAlphLen - the alphabet length of all alphabetsindices - the indices of the positions to be usedpublic MEM(int[] constraint, int[] allAlphLen, int[][] cond)
constraint - the constraintallAlphLen - the alphabet length of all alphabetscond - the conditional fixed positionspublic MEM(StringBuffer representation) throws NonParsableException
Storable interface.representation - the representationNonParsableException - if the the StringBuffer could not be parsed.public MEM clone() throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedExceptionpublic double getScoreFor(Sequence seq, int start)
sequence beginning at start.seq - the sequencestart - the start positionsequence beginning at startpublic double getLogScoreFor(Sequence seq, int start)
sequence beginning at start.seq - the sequencestart - the start positionsequence beginning at startpublic double getLogPriorPart(double ess)
ess - the ESS to be usedStatisticalModel.getLogPriorTerm()public String toString(NumberFormat nf)
String using a given NumberFormat.nf - the NumberFormat.public StringBuffer toXML()
StorableStringBuffer of an
instance of the implementing class.public void train(SequenceIterator s, byte algo, TerminationCondition condition, SafeOutputStream sostream) throws Exception
s - the SequenceIterator used in normalization and numerical approximationalgo - the choice of numerical approximationcondition - the TerminationCondition for stopping the iterative algorithmsostream - a possibility for writing some informationException - if something went wrong inside the algorithmsMEMTools