Posts by Shu Wan

Nonlinear dependence

A constraint-based method learns a graph from independence tests. Its result depends on the test. The default test, partial correlation, detects only linear dependence. When an effect is nonlinear, it can miss an edge or add a false one. In 0.8.0, you can use PC, FCI, GFCI, and CD-NOD with four supported tests that detect nonlinear dependence: KCI, RCoT, CMIknn, and GPDC. Each runs faster than the package we measured it against at every size we timed, at the same level of accuracy: PC with RCoT runs more than 5x faster than causal-learn and more than 9x faster than pcalg.

Read more ...


Acceleration

Andrey was already the fastest causal discovery package. 0.9.0 is our biggest speed breakthrough yet, the fastest causal discovery we have ever shipped: BOSS runs up to 8.1x faster than before, exact search 5.2x, and FCI and GFCI 3.1x, and every graph is exactly the same. Every release so far added methods or data; this one is all speed. This post is the first of two. Here the rocket lifts off. The next release, 0.10.0, follows it up to the boundary: how far each method now goes before it stops finishing, or stops being accurate.

Read more ...


Permutation invariance

Give two people the same table with its columns in different orders. Ask each to learn a causal graph. They should get the same graph. Column order carries no information: it comes from a database export, a DataFrame, or whoever wrote the CSV. A method whose graph does not depend on that order is permutation invariant.

Read more ...


Mixed and categorical data

Your tables may contain more than numbers. A customer record holds a plan and a region alongside hours used and the amount billed. A patient record holds a diagnosis alongside blood pressure. With Andrey 0.6.0, you can learn causal graphs from categorical data and from tables that mix categorical and continuous columns.

Read more ...


Temporal causal discovery

Causes take time. Rain today slows today’s traffic, and today’s traffic shapes tomorrow’s sales. When you measure the same variables day after day, the order of the days tells you which way a link can run: the future cannot cause the past. As of 0.5.0, we support six methods that use this order: PCMCI, PCMCI+, LPCMCI, lasso Granger causality, VARMA-LiNGAM, and LongitudinalLiNGAM.

Read more ...


Pairwise direction

Does x cause y, or does y cause x? With only two variables, independence tests cannot tell: both directions fit the data equally well. ANM and PNL instead use the shape of the relationship to infer direction. This release adds ANM. As of 0.4.0, we support both methods.

Read more ...


Score-based search

A score-based method searches for the graph that best explains the data according to a score. This release adds Tabu search and XGES. From 0.3.0, both are supported, as is hill climbing. Hill climbing also returns the same graphs in less time.

Read more ...


Hidden common causes

A hidden common cause, or latent confounder, is an unmeasured variable that affects two measured variables. This release adds RCD and BottomUpParceLiNGAM as supported methods. With FCI, they cover data with hidden common causes. Below, we run all three on one small dataset and report benchmark results. Other updates make small fits several times faster.

Read more ...


Why Andrey is fast

Most of the time in causal discovery goes to two jobs: testing whether variables are independent (PC and FCI) and scoring candidate graphs (GES and BOSS). We speed up both with four ideas, easiest first. Each animation runs the same work in two lanes: Andrey’s, and one labeled Others that does it one step at a time. They are illustrations of the ideas, not measurements; the benchmarks have the measurements.

Read more ...


Introducing Andrey

We’re happy to introduce Andrey, a very fast causal discovery package for Python.

Read more ...