Opinionated data health checks for pandas DataFrames
Project description
dfhealth 🏥
Stop shipping dirty data. dfhealth is an opinionated, zero-config tool to sanity-check your pandas DataFrames before they hit your models.
Think of it like PyLint for DataFrames.
Why dfhealth?
Data scientists often spend 80% of their time cleaning data. dfhealth automates the "sanity check" phase by flagging silent killers in your dataset with actionable advice.
Key Checks
| Code | Name | What it catches |
|---|---|---|
| D001 | Duplicate Rows | Identical rows that might skew your statistics. |
| I001 | ID Integrity | Duplicate values in columns that look like IDs (e.g., user_id). |
| N001 | Negative Values | Negative numbers in fields meant to be positive (e.g., age, price). |
| O001 | Extreme Outliers | Values outside the 3x IQR range that could be data entry errors. |
| T001 | Date-like String | Object columns that look like they should be datetime objects. |
📦 Installation
pip install dfhealth
Quick Start
import pandas as pd
import dfhealth as dh
# Load your dataset
df = pd.read_csv("data.csv")
# Run the health check
report = dh.health_check(df)
# Get a beautiful, colored report in your terminal
report.print()
📖 License
MIT License - see the LICENSE file for details.
🤝 Contributing
Want to add a new check? Check out CONTRIBUTING.md.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file dfhealth-0.1.2.tar.gz.
File metadata
- Download URL: dfhealth-0.1.2.tar.gz
- Upload date:
- Size: 7.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
71ee4d53bb3149693b6949d9d6e3b69abe9b81c2b6c7269a52d1524846cb9f18
|
|
| MD5 |
8802ec4a64a3b33bcf3fa75774c6a3ea
|
|
| BLAKE2b-256 |
d48c773a73af5468cc0d2e06d821385b18b887ca0c5fbc4a757fd40cba5a70a4
|
File details
Details for the file dfhealth-0.1.2-py3-none-any.whl.
File metadata
- Download URL: dfhealth-0.1.2-py3-none-any.whl
- Upload date:
- Size: 8.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c926950f4b2704ea75171cccbb275e9eee6e1abb5ad73f1154de6fead463cc06
|
|
| MD5 |
41dcbb789e0a9f3d4621ac90e0ce665e
|
|
| BLAKE2b-256 |
7ed74cd11475dd771f6e9d318358a3a7609fb10b531dcfcda2df6667db30dc30
|