Package edu.cmu.tetrad.search.score
Class EbicScore
java.lang.Object
edu.cmu.tetrad.search.score.EbicScore
- All Implemented Interfaces:
- Score
Implements the extended BIC (EBIC) score. The reference is here:
 
Chen, J., & Chen, Z. (2008). Extended Bayesian information criteria for model selection with large model spaces. Biometrika, 95(3), 759-771.
As for all scores in Tetrad, higher scores mean more dependence, and negative scores indicate independence.
- Version:
- $Id: $Id
- Author:
- josephramsey
- 
Constructor SummaryConstructorsConstructorDescriptionConstructs the score using a covariance matrix.EbicScore(ICovarianceMatrix covariances) Constructs the score using a covariance matrix.
- 
Method SummaryModifier and TypeMethodDescriptionbooleandetermines(List<Node> z, Node y) Returns true iff the score determines the edge between x and y.intReturns the max degree, by default 1000.intReturns the sample size.The variables of the score.booleanisEffectEdge(double bump) Returns true iff the edge between x and y is an effect edge.doublelocalScore(int i, int... parents) Returns the score of the node at index i, given its parents.doublelocalScoreDiff(int x, int y, int[] z) Returns the score difference of the graph.voidsetGamma(double gamma) Sets the gamma parameter for EBIC.voidsetUsePseudoInverse(boolean usePseudoInverse) Returns the gamma parameter for EBIC.Methods inherited from class java.lang.Objectequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface edu.cmu.tetrad.search.score.Scoreappend, getVariable, localScore, localScore, localScoreDiff, toString
- 
Constructor Details- 
EbicScoreConstructs the score using a covariance matrix.- Parameters:
- covariances- The covariance matrix.
 
- 
EbicScoreConstructs the score using a covariance matrix.- Parameters:
- dataSet- The continuous dataset to analyze.
- precomputeCovariances- Whether the covariances should be precomputed or computed on the fly. True if precomputed.
 
 
- 
- 
Method Details- 
localScoreDiffpublic double localScoreDiff(int x, int y, int[] z) Returns the score difference of the graph.Returns the score of the node at index y, given its parents. - Specified by:
- localScoreDiffin interface- Score
- Parameters:
- x- A node.
- y- TAhe node.
- z- A set of nodes.
- Returns:
- The score difference.
 
- 
localScoreReturns the score of the node at index i, given its parents.- Specified by:
- localScorein interface- Score
- Parameters:
- i- The index of the node.
- parents- The indices of the node's parents.
- Returns:
- The score, or NaN if the score cannot be calculated.
- Throws:
- RuntimeException- if any.
 
- 
getSampleSizepublic int getSampleSize()Returns the sample size.- Specified by:
- getSampleSizein interface- Score
- Returns:
- This size.
 
- 
isEffectEdgepublic boolean isEffectEdge(double bump) Returns true iff the edge between x and y is an effect edge.Returns a judgement for FGES of whether the given bump implies an effect edge. - Specified by:
- isEffectEdgein interface- Score
- Parameters:
- bump- The bump.
- Returns:
- True iff the edge between x and y is an effect edge.
- See Also:
 
- 
getVariablesThe variables of the score.Returns the variables for this score. - Specified by:
- getVariablesin interface- Score
- Returns:
- This list.
 
- 
getMaxDegreepublic int getMaxDegree()Returns the max degree, by default 1000.Returns an estimate of max degree of the graph for some algorithms. - Specified by:
- getMaxDegreein interface- Score
- Returns:
- The max degree.
- See Also:
 
- 
determinesReturns true iff the score determines the edge between x and y.Return a judgment of whether the variable in z determine y exactly. - Specified by:
- determinesin interface- Score
- Parameters:
- z- The set of nodes.
- y- The node.
- Returns:
- True iff the score determines the edge between x and y.
 
- 
setGammapublic void setGamma(double gamma) Sets the gamma parameter for EBIC.- Parameters:
- gamma- The gamma parameter.
 
- 
setUsePseudoInversepublic void setUsePseudoInverse(boolean usePseudoInverse) Returns the gamma parameter for EBIC.- Parameters:
- usePseudoInverse- True if the pseudo-inverse should be used.
 
 
-