Skip to main content

FramePeek

Lightweight exploratory data analysis for pandas DataFrames.

Documentation

Usage

import framepeek as fp

report = fp.profile(
    df,
    target_column="churn",
    correlation_method="spearman",
    outlier_multiplier=1.5,
    top_n_categories=5,
)

fp.print_report(report)

The report contains overview, columns, missing, duplicates, numeric, categorical, outliers, correlations, target, and warnings. print_report() gives each section a title and prints tables without formatter-generated ellipses.

Each analysis is also available directly:

fp.overview(df)
fp.columns(df)
fp.missing(df)
fp.duplicates(df)
fp.numeric(df)
fp.categorical(df)
fp.outliers(df)
fp.correlations(df)
fp.target(df, target_column="churn")
fp.quality_warnings(df, target_column="churn")

All functions validate their inputs and leave the original DataFrame unchanged. Object columns containing lists, tuples, dictionaries, sets, frozensets, or NumPy arrays use recursive structural identity for duplicate and categorical analysis. Arrays match when their concrete type, shape, dtype, and nested values match. Other unhashable custom objects use scalar boolean equality; objects whose equality raises or returns a non-scalar result are treated as distinct unless they are the same instance. Cyclic references likewise use instance identity at the cycle boundary.

Outputs

Function Return value
overview DataFrame of dataset-level metrics
columns DataFrame with one profile row per column
missing Dictionary containing explicit columns, rows, and co-missingness patterns
duplicates Dictionary containing totals, groups, and examples
numeric DataFrame of descriptive numeric statistics
categorical DataFrame of frequency and cardinality statistics
outliers DataFrame of IQR bounds and potential outlier counts
correlations Dictionary containing matrix and tidy pairs tables
target Dictionary containing categorical or numeric target analysis
quality_warnings DataFrame of actionable quality warnings
profile Dictionary containing metadata and all analyses above
format_report Bounded text representation of a profile
print_report None; prints the bounded text representation
to_serializable Versioned JSON-compatible envelope preserving table labels and conversion fidelity

Thresholds for missingness, cardinality, outliers, correlations, and class imbalance can be configured through the corresponding function parameters. Warning text parsing is sampled reproducibly for large columns. Correlation analysis supports column subsets, limits, pair-only output, top pairs, and reproducible row sampling. Serialization schema 1.0 stores DataFrames as explicit index, column, and data arrays. Mappings with non-string keys use entry records so distinct labels cannot overwrite each other; the envelope's exact field identifies lossy fallback display values. warnings() remains available as a compatibility alias. Pass deep_memory=False to overview() or profile() when a shallow memory estimate is sufficient.

Run the bounded runtime and peak-memory smoke benchmarks with:

python benchmarks/benchmark_profile.py

Development

python -m pip install -e ".[dev]"
python -m ruff check .
python -m mypy src/framepeek
python -m pytest --cov=framepeek --cov-fail-under=100

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

framepeek-0.2.2.tar.gz (31.5 kB view details)

Uploaded Source

Built Distribution

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

framepeek-0.2.2-py3-none-any.whl (25.1 kB view details)

Uploaded Python 3

File details

Details for the file framepeek-0.2.2.tar.gz.

File metadata

  • Download URL: framepeek-0.2.2.tar.gz
  • Upload date:
  • Size: 31.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for framepeek-0.2.2.tar.gz
Algorithm Hash digest
SHA256 dd0d3bcd4ad42d6855608ccf2698ebb74465e2c7c1355921ffb31c119a98acc4
MD5 b91b52c545628864af82f13a330ebbfd
BLAKE2b-256 b3027b9785175965189f257343a349baa35c146dcbd731c54c329ba6fa35d8d4

See more details on using hashes here.

File details

Details for the file framepeek-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: framepeek-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 25.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for framepeek-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a5e1c2c29d2c7b18745ae40f2031cff877163011c41124e62fc5dea04d910aeb
MD5 71c97a683dd41f1f5e7081fdadd052ff
BLAKE2b-256 2ac9017836076ee9b965b6ee72d713f737831faf88cf5852cceadf6906173365

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.2.2 This release

2 files

0.2.1

2 files

0.2.0

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page