Skip to main content

IV Models

Project description

Instrumental Variables Regression in Python

ivmodels implements

  • K-Class estimators, including the Limited Information Maximum Likelihood (LIML) and the Two-Stage Least Squares (TSLS) estimator.
  • Tests and confidence sets for the parameters of the model, including the Anderson-Rubin test, the Lagrange multiplier test, the (conditional) likelihood-ratio test, and the Wald test.
  • Auxiliary tests such as Anderson's (1951) test of reduced rank (a multivariate extension to the first-stage F-test), the J-test (including its LIML variant), and Scheidegger et al.'s residual prediction test of well-specification.

See the docs and the examples therein for more details. See this document for an introduction to the estimators, tests, and their properties.

If you use this code, consider citing

@article{londschien2025statistician,
  title={A statistician's guide to weak-instrument-robust inference in instrumental variables regression with illustrations in {Python}},
  author={Londschien, Malte},
  journal={arXiv preprint arXiv:2508.12474},
  year={2025}
}

and

@article{londschien2024weak,
  title={Weak-instrument-robust subvector inference in instrumental variables regression: A subvector Lagrange multiplier test and properties of subvector Anderson-Rubin confidence sets},
  author={Londschien, Malte and B{\"u}hlmann, Peter},
  journal={arXiv preprint arXiv:2407.15256},
  year={2024}
}

Installation

You can install ivmodels from conda (recommended):

conda install -c conda-forge ivmodels

or pip:

pip install ivmodels

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

ivmodels-0.10.0.tar.gz (85.7 kB view details)

Uploaded Source

Built Distribution

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

ivmodels-0.10.0-py3-none-any.whl (57.3 kB view details)

Uploaded Python 3

File details

Details for the file ivmodels-0.10.0.tar.gz.

File metadata

  • Download URL: ivmodels-0.10.0.tar.gz
  • Upload date:
  • Size: 85.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for ivmodels-0.10.0.tar.gz
Algorithm Hash digest
SHA256 fb9ce7c6b52b396308bf75b9963132e7bd1531b249e7ad9bd92584898e733d2a
MD5 4c1fd32b5ca90f4fa458cfdf79d93b44
BLAKE2b-256 ca4cdfd032c74dc46b2ee577dd12edd556b0bfc37044eb5fce9b79507c221020

See more details on using hashes here.

Provenance

The following attestation bundles were made for ivmodels-0.10.0.tar.gz:

Publisher: build.yaml on mlondschien/ivmodels

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ivmodels-0.10.0-py3-none-any.whl.

File metadata

  • Download URL: ivmodels-0.10.0-py3-none-any.whl
  • Upload date:
  • Size: 57.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for ivmodels-0.10.0-py3-none-any.whl
Algorithm Hash digest
SHA256 372e8178fdb79c50ffcc43a0183183ccae217f3d3841fe5c866f4cdb7543cd1d
MD5 a219e3056664eeea949a5257f1397bea
BLAKE2b-256 9e757d79b7fcb70000a35d225f9aa60e16a02a030fd0d6820299ffb97998c0e3

See more details on using hashes here.

Provenance

The following attestation bundles were made for ivmodels-0.10.0-py3-none-any.whl:

Publisher: build.yaml on mlondschien/ivmodels

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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