Registry / data / pyfixest

pyfixest

JSON →
library0.60.0pypypi✓ verified 86d ago

Fast high-dimensional fixed effect estimation library for Python, following the syntax of the R fixest package. Current version: 0.50.1. Released ~monthly. Supports OLS, GLM, IV, quantile regression, and robust/clustered inference with multiple demeaner backends (including Rust).

pip install pyfixest
INSTALL
IMPORT
SIG · PYFIXEST
P
pyfixest
datapythonv0.60.0
Install
23.5s avg
Import
10741ms
Disk
559MB
Pass rate
9/ 10
Env Coverage9 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.60.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
glibc
py 3.10
✓ —
✓ 24.5s
py 3.11
✓ —
✓ 23.25s
py 3.12
✓ —
✓ 22.3s
py 3.13
✓ —
✓ 22.65s
py 3.9
✕ build_error
✓ 25s
559MB installed
● package 559MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

feols
from pyfixest import feols
import pyfixest as pf; pf.feols(...)
This is actually correct - both work, but 'from pyfixest import feols' is clearer for single function use.
fepois
from pyfixest import fepois
from pyfixest.estimation import fepois
Direct import from top-level is preferred; internal module paths may change.

Estimate a fixed effects linear regression using a sample dataset. Replace 'distance' and 'property_type' with actual columns from the dataset.

import pandas as pd from pyfixest import feols # Load sample data df = pd.read_csv('https://github.com/py-econometrics/pyfixest/raw/master/data/airbnb.csv') # Estimate fixed effects model fit = feols('price ~ distance | property_type', data=df) print(fit.summary())
Debug
Known issues
breakingDefault inference changed in v0.40.0: 'iid' is now default (previously it was cluster by first fixed effect). This replicates R fixest 0.13 behavior. Existing scripts that relied on clustered standard errors without explicitly specifying vcov will silently get different results.
fix
Set vcov='cluster' explicitly: feols(..., vcov={'CRV1': 'firm'})
affects: >=0.40.0,<0.50.0
deprecatedThe 'demean_backend' argument was renamed to 'demeaner_backend' in v0.50.0. Old argument still works but will be removed.
fix
Use 'demeaner_backend' instead of 'demean_backend'.
affects: >=0.50.0
gotchaFormula handling changed in v0.50.0: the 'i()' operator for interactions now behaves differently. Old usage may break or yield unexpected results.
fix
Review the new formula syntax docs: https://pyfixest.org/formula.html
affects: >=0.50.0
gotchaWindows users with Rust backend may encounter a TypeError in v0.30.2. Fixed in v0.30.2a.
fix
Upgrade to >=0.30.2a or use 'demeaner_backend='pyhdfe''.
affects: 0.30.2
Errors
Common errors & fixes
ImportError: cannot import name 'feols' from 'pyfixest'
Old import path from internal modules; or pyfixest not installed.
fix
Use correct import: 'from pyfixest import feols' or 'import pyfixest as pf; pf.feols(...)'
ValueError: The `vcov` argument must be a dict with keys 'CRV1', 'CRV3', or 'iid'.
Passing a string like 'cluster' instead of dict.
fix
Use vcov={'CRV1': 'cluster_variable_name'}.
TypeError: 'NoneType' object is not iterable when using demeaner_backend='rust-cg'
Bug in v0.30.1 on Windows due to Rust ffi typing.
fix
Upgrade to >=0.30.2a or use different backend.
Upgrade
Version history
0.60.0latest on PyPI · released Jun 11, 2026
Audit
Dependencies
numpyrequiredCore array operations
pandasrequiredData handling
formulaicrequiredFormula parsing
scipyrequiredOptimization for GLMs
pyhdfeoptionalAlternative demeaner backend
Agent activity
7 hits · last 30 days
node
6
Resources
pyfixest — pip install pyfixest · libregistry