Skip to main content

Causal Inference in Python

Project description

Causal Inference in Python

Causal Inference in Python, or Causalinference in short, is a software package that implements various statistical and econometric methods used in the field variously known as Causal Inference, Program Evaluation, or Treatment Effect Analysis.

Work on Causalinference started in 2014 by Laurence Wong as a personal side project. It is distributed under the 3-Clause BSD license.

Main Features

  • Assessment of overlap in covariate distributions

  • Estimation of propensity score

  • Improvement of covariate balance through trimming

  • Subclassification on propensity score

  • Estimation of treatment effects via matching, blocking, weighting, and least squares

Dependencies

  • NumPy: 1.8.2 or higher

  • SciPy: 0.13.3 or higher

Installation

Causalinference can be installed using pip:

$ pip install causalinference

For help on setting up Pip, NumPy, and SciPy on Macs, check out this excellent guide.

Minimal Example

The following illustrates how to create an instance of CausalModel:

>>> from causalinference import CausalModel
>>> from causalinference.utils import random_data
>>> Y, D, X = random_data()
>>> causal = CausalModel(Y, D, X)

Invoking help on causal at this point should return a comprehensive listing of all the causal analysis tools available in Causalinference.

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

CausalInference-0.1.2.tar.gz (58.9 kB view details)

Uploaded Source

File details

Details for the file CausalInference-0.1.2.tar.gz.

File metadata

File hashes

Hashes for CausalInference-0.1.2.tar.gz
Algorithm Hash digest
SHA256 719a6ee78bdda302155d26de63a7098532fdca8188c16abe3cc9f38645f9f17e
MD5 a7b45f91c367c771eb9cfd34a2bc1bcc
BLAKE2b-256 b44676b177dd50c4fb9e4ba3a633d44592d9c11029f813e9f43f39c13b725d2d

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