A fork of Engarde, a python package for defensive data analysis.
The differences between this fork and Engarde proper are:
- renamed
verifytoverify_df. - Added two new functions in
generic:verify_columns. Verifies columns. E.g.checks.verify_columns(df, lambda x: (x > 0).all())verify_rows. Verifies rows. E.g.checks.verify_rows(df, lambda row: row.A > row.B)
- Deleted
verify_allandverify_any. Basically I consider these less useful thanverify_columnsandverify_rowsand I like that the API is small. verify_columnsandverify_rowsfunctions are added tochecksanddecorators.has_dtypescan accept functions that returnTrueif the test is passd (typically the ones inpd.api.types, e.g.is_integer_dtype) and can accept strings from the allowed string output ofpd.api.types.infer_dtypes.
pip install topper-123-engardeand then in your python code:
import engardeFor details, see doc strings for relevant functions. For a tutorial, see Engarde's tutorial, but beware the differences.