Examples#
Each notebook runs one method or task, on your own machine or in Colab; each has Open in Colab
and Download this notebook links. The demos run in your browser instead. From
a source checkout, start Jupyter with uv run --with jupyter jupyter lab. A notebook that needs another
package installs it in a cell with uv pip install.
To run one in Colab, choose Open in Colab, select a CPU runtime, and run the setup cell before the example. The setup cell installs Andrey in the Colab runtime only; the speed notebook labels that runtime in its output.
Time PC in Andrey and causal-learn on your own hardware.
Notebook · Colab
Recover a three-variable chain with GES.
Notebook · Colab
PC’s CPDAG and FCI’s and GFCI’s PAGs from conditional-independence tests, and CD-NOD on data from several domains.
Notebook · Colab
BOSS and GRaSP search over orderings of the variables for the best-scoring graph.
Notebook · Colab
XGES, hill climbing, Tabu search, and exact search look for the graph with the best BIC score; GIES also learns from interventions.
Notebook · Colab
CALM learns a weighted DAG by gradient descent on a penalized likelihood; it runs on torch.
Notebook · Colab
DirectLiNGAM and ICA-LiNGAM orient every edge when the noise is non-Gaussian; MultiGroupDirectLiNGAM fits several datasets, and GIN finds latent variables.
Notebook · Colab
RCD finds the direct causes and marks the pairs that share a hidden cause.
Notebook · Colab
BottomUpParceLiNGAM orders the variables and leaves those a hidden cause confounds unordered.
Notebook · Colab
ANM and PNL test which of two variables causes the other.
Notebook · Colab
PCMCI, PCMCI+, LPCMCI, Granger, VARMA-LiNGAM, and longitudinal LiNGAM on data over time.
Notebook · Colab
Draw a recovered graph as a self-contained SVG.
Notebook · Colab