Class FciMax

java.lang.Object
edu.cmu.tetrad.search.FciMax
All Implemented Interfaces:
IGraphSearch

public final class FciMax extends Object implements IGraphSearch

Modifies FCI to do orientation of unshielded colliders (X*-*Y*-*Z with X and Z not adjacent) using the max-P rule (see the PC-Max algorithm). This reference is relevant:

Raghu, V. K., Zhao, W., Pu, J., Leader, J. K., Wang, R., Herman, J., ... & Wilson, D. O. (2019). Feasibility of lung cancer prediction from low-dose CT scan and smoking factors using causal models. Thorax, 74(7), 643-649.

Max-P triple orientation is a method for orienting unshielded triples X*=-*Y*-*Z as one of the following: (a) Collider, X->Y<-Z, or (b) Noncollider, X-->Y-->Z, or X<-Y<-Z, or X<-Y->Z. One does this by conditioning on subsets of adj(X) or adj(Z). One first checks conditional independence of X and Z conditional on each of these subsets, and lists the p-values for each test. Then, one chooses the conditioning set out of all of these that maximizes the p-value. If this conditioning set contains Y, then the triple is judged to be a noncollider; otherwise, it is judged to be a collider.

All unshielded triples in the graph given by FAS are judged as colliders or non-colliders and the colliders oriented. Then the final FCI orientation rules are applied, as in FCI.

This class is configured to respect knowledge of forbidden and required edges, including knowledge of temporal tiers.

Author:
josephramsey
See Also:
  • Constructor Details

  • Method Details

    • search

      public Graph search()
      Performs the search and returns the PAG.
      Specified by:
      search in interface IGraphSearch
      Returns:
      This PAG.
    • setDepth

      public void setDepth(int depth)
      Sets the maximum nubmer of variables conditioned in any test.
      Parameters:
      depth - This maximum.
    • getElapsedTime

      public long getElapsedTime()
      Returns the elapsed time of search.
      Returns:
      This time.
    • getSepsets

      public SepsetMap getSepsets()
      Retrieves the map from variable pairs to sepsets from the FAS search.
      Returns:
      This map.
    • getKnowledge

      public Knowledge getKnowledge()
      Retrieves the background knowledge that was set.
      Returns:
      This knoweldge,
    • setKnowledge

      public void setKnowledge(Knowledge knowledge)
      Sets background knowledge for the search.
      Parameters:
      knowledge - This knowledge,
    • setCompleteRuleSetUsed

      public void setCompleteRuleSetUsed(boolean completeRuleSetUsed)
      Sets whether Zhang's complete rule set is used in the search.
      Parameters:
      completeRuleSetUsed - set to true if Zhang's complete rule set should be used, false if only R1-R4 (the rule set of the original FCI) should be used. False by default.
    • setPossibleMsepSearchDone

      public void setPossibleMsepSearchDone(boolean possibleMsepSearchDone)
      Sets whether the (time-consuming) possible msep step should be done.
      Parameters:
      possibleMsepSearchDone - True, if so.
    • setMaxPathLength

      public void setMaxPathLength(int maxPathLength)
      Sets the maximum length of any discriminating path, or -1 if unlimited.
      Parameters:
      maxPathLength - This maximum.
    • setVerbose

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

      public IndependenceTest getIndependenceTest()
      Returns the independence test used in search.
      Returns:
      This test.
    • setPcHeuristicType

      public void setPcHeuristicType(PcCommon.PcHeuristicType pcHeuristicType)
      Sets the FAS heuristic from PC used in search.
      Parameters:
      pcHeuristicType - This heuristic.
      See Also:
    • setStable

      public void setStable(boolean stable)
      Sets whether the stable option will be used for search.
      Parameters:
      stable - True, if so.
    • setDoDiscriminatingPathRule

      public void setDoDiscriminatingPathRule(boolean doDiscriminatingPathRule)
      Sets whether the discriminating path rule will be used in search.
      Parameters:
      doDiscriminatingPathRule - True, if so.