Class IndTestMnlrLr
java.lang.Object
edu.cmu.tetrad.search.work_in_progress.IndTestMnlrLr
- All Implemented Interfaces:
IndependenceTest
Performs a test of conditional independence X _||_ Y | Z1...Zn where all searchVariables are either continuous or
discrete. This test is valid for both ordinal and non-ordinal discrete searchVariables.
- Version:
- $Id: $Id
- Author:
- bryanandrews
-
Constructor Summary
ConstructorsConstructorDescriptionIndTestMnlrLr
(DataSet data, double alpha) Constructs a new independence test for the given data set and significance level. -
Method Summary
Modifier and TypeMethodDescriptioncheckIndependence
(Node x, Node y, Set<Node> _z) Checks the independence between two nodes given a set of conditioning nodes.boolean
determines
(List<Node> z, Node y) Determines the independence relation between a list of conditioning nodes and a target node.double
getAlpha()
Returns the significance level of the independence test.getData()
Returns the dataset.getVariables.indTestSubset
(List<Node> vars) This method returns an independence test for a sublist of variables.boolean
Determines if the test prints verbose output.void
setAlpha
(double alpha) Sets the significance level for the independence test.void
setVerbose
(boolean verbose) Sets whether this test will print verbose output.toString()
Returns a string representation of this object.Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface edu.cmu.tetrad.search.IndependenceTest
checkIndependence, determines, getCov, getDataSets, getSampleSize, getVariable, getVariableNames
-
Constructor Details
-
IndTestMnlrLr
Constructs a new independence test for the given data set and significance level.- Parameters:
data
- the data set.alpha
- the significance level.
-
-
Method Details
-
indTestSubset
This method returns an independence test for a sublist of variables.- Specified by:
indTestSubset
in interfaceIndependenceTest
- Parameters:
vars
- The sublist of variables.- Returns:
- An object of type IndependenceTest.
- Throws:
UnsupportedOperationException
- If this feature is not implemented.
-
checkIndependence
Checks the independence between two nodes given a set of conditioning nodes.- Specified by:
checkIndependence
in interfaceIndependenceTest
- Parameters:
x
- the first nodey
- the second node_z
- the set of conditioning nodes- Returns:
- the result of the independence test
- See Also:
-
getVariables
getVariables.
- Specified by:
getVariables
in interfaceIndependenceTest
- Returns:
- the list of searchVariables over which this independence checker is capable of determinining independence relations.
-
determines
Determines the independence relation between a list of conditioning nodes and a target node.- Parameters:
z
- The list of conditioning nodes.y
- The target node.- Returns:
- true if the target node is independent of the conditioning nodes; false otherwise.
-
getAlpha
public double getAlpha()Returns the significance level of the independence test.- Specified by:
getAlpha
in interfaceIndependenceTest
- Returns:
- The significance level.
-
setAlpha
public void setAlpha(double alpha) Sets the significance level for the independence test.- Specified by:
setAlpha
in interfaceIndependenceTest
- Parameters:
alpha
- The significance level to set.
-
getData
Returns the dataset.- Specified by:
getData
in interfaceIndependenceTest
- Returns:
- The dataset.
- See Also:
-
isVerbose
public boolean isVerbose()Determines if the test prints verbose output.- Specified by:
isVerbose
in interfaceIndependenceTest
- Returns:
- True if the test prints verbose output, false otherwise.
-
setVerbose
public void setVerbose(boolean verbose) Sets whether this test will print verbose output.- Specified by:
setVerbose
in interfaceIndependenceTest
- Parameters:
verbose
- True, if so.
-
toString
Returns a string representation of this object.- Specified by:
toString
in interfaceIndependenceTest
- Overrides:
toString
in classObject
- Returns:
- the string representation of this object.
-