Skip to main content

Information Measures on Causal Graphs.

Project description

https://badge.fury.io/py/causalinfo.png

causalinfo is a Python library to aid in experimenting with different information measures on causal graphs—a combination of information theory with recent work on causal graphs [Pearl2000]. These information measures can used to ascertain the degree to which one variable controls or explains other variables in the graph. The use of these measures has important connections to work on causal explanation in philosophy of science, and to understanding information processing in biological networks.

The library is a work in progress, and will be extended as research continues.

What does it do?

causalinfo has been written primarily for interactive use within IPython Notebook. You can create variables and assign probability distributions to them, or relate them to other variables using conditional probabilities. Several related variables can be combined into a directed acyclic graph, which can generate a joint distribution for all variables under observation, or under controlled interventions on certain variables. You can also calculate various information measures between variables in the graph whilst controlling other variables. These include correlative measures, such as Mutual Information, but also causal measures, such as Information Flow [AyPolani2008], and Causal Specificity [GriffithsEtAl2015].

For some brief examples of how to use the library, please see the IPython Notebooks that are included:

  • Introduction. A short introduction to some of the things you can do with the library.

  • Rain. Performing some interventions on a causal graph; an example from Judea Pearl’s book.

  • Signaling. Measuring Causation in Signaling Networks. Some examples from [CalcottEtAl2016].

  • Information Flow. Measuring the flow of information in Causal networks from [AyPolani2008].

Some Caveats

The library is not meant for large scale analysis. The code has been written to offload as much as possible on to other libraries (such as Pandas and Networkx), and to allow easy inspection of what is going on within IPython Notebook, thus it is not optimized for speed. Calculating the joint distribution for a causal graph with many variables can become very slow (especially if the variables have many states).

Authorship

All code was written by Brett Calcott.

Acknowledgments

This work is part of the research project on the Causal Foundations of Biological Information at the University of Sydney, Australia. The work was made possible through the support of a grant from the Templeton World Charity Foundation. The opinions expressed are those of the author and do not necessarily reflect the views of the Templeton World Charity Foundation.

License

MIT licensed. See the bundled LICENSE file for more details.

References

[AyPolani2008] (1,2)

Ay, N., & Polani, D. (2008). Information flows in causal networks. Advances in Complex Systems, 11(01), 17–41.

[GriffithsEtAl2015]

Griffiths, P. E., Pocheville, A., Calcott, B., Stotz, K., Kim, H., & Knight, R. (2015). Measuring Causal Specificity. Philosophy of Science, 82(October), 529–555.

[CalcottEtAl2016]

Calcott, B., Griffiths, P. E., Pocheville, A. (Forthcoming). Signals that Make a Difference. British Journal for Philosophy of Science.

[Pearl2000]

Pearl, J. (2000). Causality. Cambridge University Press.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

causalinfo-1.2.0.tar.gz (18.8 kB view details)

Uploaded Source

File details

Details for the file causalinfo-1.2.0.tar.gz.

File metadata

  • Download URL: causalinfo-1.2.0.tar.gz
  • Upload date:
  • Size: 18.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for causalinfo-1.2.0.tar.gz
Algorithm Hash digest
SHA256 279ad19e0fac74e52ae3471407eb3b28814f6b182c2fc78703571471c15fcbf2
MD5 73c8d43dd8a3397cf03986cd1c6d27e5
BLAKE2b-256 139b64e3e61fa2132e13d7a513dff272eeaae7ff72aeaba24c870787590696dc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page