org.omegahat.Environment.DataStructures
Class BasicFactor
java.lang.Object
|
+--org.omegahat.Environment.ObjectDataStructures.vector
|
+--org.omegahat.Environment.DataStructures.BasicFactor
- All Implemented Interfaces:
- Addable, AssignableSubset, Divisable, MathOperable, MathOperations, Multiplicable, java.io.Serializable, Subsettable, Subtractable, VariableInt
- public class BasicFactor
- extends vector
- See Also:
- Serialized Form
| Methods inherited from class org.omegahat.Environment.ObjectDataStructures.vector |
add, add, addElement, addValue, apply, apply, asArray, assignElement, assignSubset, copy, createElement, createElement, createVariable, data, data, data, data, data, divide, divide, divideValue, element, elementMathOp, elementToString, exp, findMethod, getDataFrame, getName, isNA, isNA, length, length, length, mathOperation, mathOperation, metaData, minus, minus, multiply, multiply, multiplyValue, numObservations, plus, plus, read, read, separator, setDataFrame, setName, subset, subtractValue, toString, value, values, values |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
levelSet
protected FactorLevelSet levelSet
BasicFactor
public BasicFactor()
BasicFactor
public BasicFactor(int length)
BasicFactor
public BasicFactor(long length)
BasicFactor
public BasicFactor(java.lang.Object[] values)
BasicFactor
public BasicFactor(Factor factor)
BasicFactor
public BasicFactor(Factor factor,
boolean copy)
BasicFactor
public BasicFactor(BasicFactor factor,
boolean copy)
BasicFactor
public BasicFactor(integer values,
java.util.Vector levels,
boolean copy)
BasicFactor
public BasicFactor(int[] values,
java.util.Vector levels,
boolean copy)
BasicFactor
public BasicFactor(int[] values,
FactorLevelSet levels,
boolean copy)
mathOperation
public java.lang.Object mathOperation(java.lang.Object rhs,
boolean inPlace,
int op)
- Description copied from class:
vector
- General work-horse method for doing mathematical operations.
Dispatches to the appropriate method based on the class of
rhs.
- Overrides:
mathOperation in class vector
- Following copied from class:
org.omegahat.Environment.ObjectDataStructures.vector
- Parameters:
rhs - right hand side of the binary operation that can be
a number or another vector. Other types are currently rejected.inPlace - whether to copy the vector and do the operations
on the copy or to change the values in this instance.op - value indicating which mathematical operation
to perform.
See
MathOperable
targetClass
public java.lang.Class targetClass()
- Description copied from class:
vector
- The default class of each element in the list.
Used to ensure type-integrity of the array
as well as for creating new elements.
- Overrides:
targetClass in class vector
convertElement
public java.lang.Object convertElement(java.lang.Object el)
- Overrides:
convertElement in class vector
values
public java.lang.Object[] values()
levelSet
public FactorLevelSet levelSet()
levelSet
public FactorLevelSet levelSet(FactorLevelSet set)