Class ConditionalGaussianLikelihood

java.lang.Object
edu.cmu.tetrad.search.score.ConditionalGaussianLikelihood

public class ConditionalGaussianLikelihood extends Object

Implements a conditional Gaussian likelihood. Please note that this likelihood will be maximal only if the continuous variables are jointly Gaussian conditional on the discrete variables; in all other cases, it will be less than maximal. The reference is here:

Andrews, B., Ramsey, J., & Cooper, G. F. (2018). Scoring Bayesian networks of mixed variables. International journal of data science and analytics, 6, 3-18.

As for all scores in Tetrad, higher scores mean more dependence, and negative scores indicate independence.

Author:
bryanandrews, josephramsey
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    Gives return value for a conditional Gaussain likelihood, returning a likelihood value and the degrees of freedom for it.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs the score using a covariance matrix.
  • Method Summary

    Modifier and Type
    Method
    Description
    getLikelihood(int i, int[] parents)
    Returns the likelihood of variable i conditional on the given parents, assuming the continuous mixedVariables index by i or by the parents are jointly Gaussian conditional on the discrete comparison.
    void
    setDiscretize(boolean discretize)
    Sets whether to discretize child variables to avoid integration.
    void
    setNumCategoriesToDiscretize(int numCategoriesToDiscretize)
    Sets the number of categories to use to discretize child variables to avoid integrationl
    void
    setPenaltyDiscount(double penaltyDiscount)
    Sets the penalty discount for this score, which is a multiplier on the panalty term of BIC.
    void
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ConditionalGaussianLikelihood

      public ConditionalGaussianLikelihood(DataSet dataSet)
      Constructs the score using a covariance matrix.
  • Method Details

    • setRows

      public void setRows(List<Integer> rows)
    • getLikelihood

      public ConditionalGaussianLikelihood.Ret getLikelihood(int i, int[] parents)
      Returns the likelihood of variable i conditional on the given parents, assuming the continuous mixedVariables index by i or by the parents are jointly Gaussian conditional on the discrete comparison.
      Parameters:
      i - The index of the conditioned variable.
      parents - The indices of the conditioning mixedVariables.
      Returns:
      The likelihood.
    • setPenaltyDiscount

      public void setPenaltyDiscount(double penaltyDiscount)
      Sets the penalty discount for this score, which is a multiplier on the panalty term of BIC.
      Parameters:
      penaltyDiscount - The penalty discount.
    • setDiscretize

      public void setDiscretize(boolean discretize)
      Sets whether to discretize child variables to avoid integration. An optimization.
      Parameters:
      discretize - True, if so.
      See Also:
    • setNumCategoriesToDiscretize

      public void setNumCategoriesToDiscretize(int numCategoriesToDiscretize)
      Sets the number of categories to use to discretize child variables to avoid integrationl
      Parameters:
      numCategoriesToDiscretize - This number.
      See Also: