private MaxMinAssocResult maxMinAssoc(Node t, List<Node> pc, List<Node> indepOfT) { Node f = null; List<Node> maxAssocSet = null; double maxAssoc = 0.0; for (Node v : variables) { if (t == v) continue; if (pc.contains(v)) continue; if (indepOfT.contains(v)) { continue; } List<Node> minAssoc = minAssoc(v, t, pc); double assoc = association(v, t, minAssoc); // If v is conditionally independent of t, don't consider it // again. Note if this code is right, then we have to use the // association test as an independence test... ugh. if (assoc < 1.0 - independenceTest.getAlpha()) { indepOfT.add(v); } if (assoc > maxAssoc) { maxAssocSet = minAssoc; maxAssoc = assoc; f = v; } } return new MaxMinAssocResult(f, maxAssocSet); }