Class IndexedParent
java.lang.Object
edu.cmu.tetrad.study.gene.tetrad.gene.history.IndexedParent
- All Implemented Interfaces:
TetradSerializable
,Serializable
Holds an ordered pair (index, lag) to represent a causal parent of a factor, where the factor at the given index is
independently known.
- Version:
- $Id: $Id
- Author:
- josephramsey
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
int
getIndex()
Returns the index of the parent.int
getLag()
Returns the lag of the parent.static IndexedParent
Generates a simple exemplar of this class to test serialization.toString()
Prints out the factor index and lag.
-
Constructor Details
-
IndexedParent
public IndexedParent(int index, int lag) Constructs a new index parent.- Parameters:
index
- a intlag
- a int
-
-
Method Details
-
serializableInstance
Generates a simple exemplar of this class to test serialization.- Returns:
- a
IndexedParent
object
-
getIndex
public int getIndex()Returns the index of the parent.- Returns:
- a int
-
getLag
public int getLag()Returns the lag of the parent.- Returns:
- a int
-
equals
Returns true iff the lags and indices are equal.
-
toString
Prints out the factor index and lag.
-