Class Bes

java.lang.Object
edu.cmu.tetrad.search.utils.Bes

public class Bes extends Object

Extracts the backward step of GES for use GES but also in other algorithms. The GES algorithm consists of a forward phase (FES = Forward Equivalence Search) and a backward phase (BES = Backward Equivalence Search). We find the BES step by itself is useful in a number of algorithms, so we extract this step and give as a separate algorithm.

The idea of the backward search is to start with a model that is Markov and removed edges from it and do the corresponding reorientations, improving the score each time, until the score can no longer be improved.

We use the optimized implementation used in the FGES implementation of GES.

Author:
bryanandrews, josephramsey
See Also:
  • Constructor Details

    • Bes

      public Bes(@NotNull @NotNull Score score)
  • Method Details

    • getVariables

      @NotNull public @NotNull List<Node> getVariables()
      Returns the variables being searched over.
      Returns:
      These variables as a list.
    • setVerbose

      public void setVerbose(boolean verbose)
      Sets whether verbose output should be printed.
      Parameters:
      verbose - True iff so.
    • setDepth

      public void setDepth(int depth)
      Sets the depth for the search, which is the maximum number of variables conditioned on.
      Parameters:
      depth - This maximum; for unlimited depth use -1; otherwise, give a nonzero integer.
    • bes

      public void bes(Graph graph, List<Node> variables)
      Runs BES for a graph over the given list of variables
      Parameters:
      graph - The graph.
      variables - The variables the search should be restricted to.
    • setKnowledge

      public void setKnowledge(Knowledge knowledge)
      Sets the knowledge for the search.
      Parameters:
      knowledge - This knowledge.
      See Also: