Metadata-Version: 2.4
Name: dml-rs
Version: 0.1.0
Classifier: Development Status :: 3 - Alpha
Classifier: Programming Language :: Rust
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Scientific/Engineering :: Mathematics
Classifier: Intended Audience :: Science/Research
Requires-Dist: numpy>=1.21
Requires-Dist: pandas>=1.3 ; extra == 'pandas'
Requires-Dist: pytest>=7 ; extra == 'test'
Requires-Dist: scikit-learn>=1.2 ; extra == 'test'
Requires-Dist: pandas>=1.3 ; extra == 'test'
Requires-Dist: doubleml>=0.11 ; extra == 'test'
Provides-Extra: pandas
Provides-Extra: test
License-File: LICENSE-MIT
License-File: LICENSE-APACHE
Summary: Fast double / debiased machine learning for causal inference, implemented in Rust
Keywords: causal-inference,double-machine-learning,econometrics,statistics
Author-email: Asad Gudzevic <asadgudzevic94@gmail.com>
License-Expression: MIT OR Apache-2.0
Requires-Python: >=3.9
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
Project-URL: Changelog, https://github.com/AsadGudzevic94/dml-rs/blob/main/CHANGELOG.md
Project-URL: Repository, https://github.com/AsadGudzevic94/dml-rs
Project-URL: Rust crate, https://crates.io/crates/dml-core

# dml-rs (Python)

Fast double / debiased machine learning for causal inference, implemented in Rust
and validated against [DoubleML](https://docs.doubleml.org).

```python
import dml_rs
from sklearn.ensemble import RandomForestRegressor, RandomForestClassifier

# Partially linear regression with any scikit-learn learners
plr = dml_rs.PLR(ml_l=RandomForestRegressor(), ml_m=RandomForestRegressor(), n_folds=5, n_rep=3)
plr.fit(X, y, d)
print(plr.summary)

# Built-in Rust learners run the whole cross-fitting in parallel without the GIL
plr = dml_rs.PLR(ml_l=dml_rs.Lasso(alpha=0.01), ml_m=dml_rs.Lasso(alpha=0.01)).fit(X, y, d)

# Average treatment effect of a binary treatment
irm = dml_rs.IRM(ml_g=RandomForestRegressor(), ml_m=RandomForestClassifier(), score="ATE").fit(X, y, d)

# Joint inference over several treatments
plr.bootstrap(method="normal", n_boot=1000)
plr.confint(joint=True)
plr.p_adjust("romano-wolf")
```

See the [repository](https://github.com/AsadGudzevic94/dml-rs) for details.

