Skip to main content

Causal models in Python

Project description

causalmodels in Python.

instalation

$ pip install causalmodels

usage

>>> import numpy as np
>>> import pandas as pd
>>> import causalmodels as cm
>>> a = np.random.laplace(size=500)
>>> b = np.random.laplace(size=500) + a
>>> c = np.random.laplace(size=500) + a + b
>>> data = pd.DataFrame({'a': a, 'b': b, 'c': c})
>>> model = cm.DirectLiNGAM()
>>> results = model.fit(data.values, data.columns)
>>> results.order
[2, 1, 0]
>>> result.draw()

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

causalmodels-0.3.0.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

causalmodels-0.3.0-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

Details for the file causalmodels-0.3.0.tar.gz.

File metadata

  • Download URL: causalmodels-0.3.0.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for causalmodels-0.3.0.tar.gz
Algorithm Hash digest
SHA256 9004ea37c442c335d80de820eaadb87f26399ff61bcde0da2030c9c461f063c5
MD5 873678152c163273c0d77ca76236f0b4
BLAKE2b-256 05bdb1388ac9ecb8079ea9a30bee5c40e9d975d1f10750ff721cda23c74f7129

See more details on using hashes here.

File details

Details for the file causalmodels-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for causalmodels-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9c42d37a8285bea3b7a1984b247263336cccafc880aa5836cdfd00d421730099
MD5 ea0a73252561747fe1f3a84470d5d5a1
BLAKE2b-256 862e635e82df84f33fdb99d0f2d56231c640e730f04c416892d82b93d63d01f6

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