|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbe.ac.ulg.montefiore.run.jahmm.Observation
be.ac.ulg.montefiore.run.jahmm.ObservationVector
public class ObservationVector
This class holds an Observation described by a vector of reals.
Constructor Summary | |
---|---|
ObservationVector(double[] value)
An observation that can be described by a vector of reals. |
|
ObservationVector(int dimension)
An observation whose components are 0. |
Method Summary | |
---|---|
ObservationVector |
clone()
|
int |
dimension()
Returns the dimension of this vector. |
Centroid<ObservationVector> |
factor()
Returns the centroid matching this observation. |
ObservationVector |
minus(ObservationVector o)
Returns a new observation that is the difference between this observation and another one. |
ObservationVector |
plus(ObservationVector o)
Returns a new observation that is the sum of this observation and another one. |
ObservationVector |
times(double c)
Returns a new observation that is the product of this observation by a scalar. |
java.lang.String |
toString(java.text.NumberFormat numberFormat)
Formats this observation using a number formatter. |
double |
value(int i)
Returns one of the values composing the observation. |
double[] |
values()
Returns the values composing this observation. |
Methods inherited from class be.ac.ulg.montefiore.run.jahmm.Observation |
---|
toString |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ObservationVector(int dimension)
dimension
- The dimension of the resulting vector.public ObservationVector(double[] value)
value
- The value of this observation. This array is copied.Method Detail |
---|
public int dimension()
public double[] values()
public double value(int i)
i
- The dimension of interest (0 ≤ i < dimension).
public Centroid<ObservationVector> factor()
factor
in interface CentroidFactory<ObservationVector>
public ObservationVector plus(ObservationVector o)
o
- The observation to sum with this one.
ObservationVector
which is the
sum of this observation and o
.public ObservationVector times(double c)
c
- A scalar value.
ObservationVector
which is the
product of this observation and c
.public ObservationVector minus(ObservationVector o)
o
- The observation to subtract from this one.
ObservationVector
which is the
difference between this observation and o
.public java.lang.String toString(java.text.NumberFormat numberFormat)
Observation
toString
in class Observation
numberFormat
- A number formatter.
public ObservationVector clone()
clone
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |