Baltor Get started

Library / Code module

Column profile of a CSV table

column_profile

Summarize each column of a CSV without declared rules: missing values, distinct values, inferred type, frequent values, value shapes, lengths, quartiles, mean, standard deviation, outliers, date ranges, duplicate rows and constant or mostly empty columns.

Files, names only

  • ATTRIBUTION.md 4.8 KB
  • LICENSE 1.0 KB
  • ONET-ATTRIBUTION.md 7.7 KB
  • PROCEDURE.md 2.3 KB
  • README.md 4.1 KB
  • TOOLS.md 1.9 KB
  • column_profile.py 7.8 KB
  • component.json 9.9 KB
  • examples/known_good.json 4.2 KB
  • examples/known_wrong.json 247 bytes
  • kit_schema.py 11.4 KB
  • test_package.py 6.8 KB

Full files in your harness.

What it takes and gives

Runs with
Python 3.10 or later
Command
python3 column_profile.py < input.json
Function
column_profile.run
Required input
csv_text

Cases it covers

  • Known wrong example: Row 3 of the CSV has six cells under a five-column header, so cells would shift into the wrong columns. Refused as ragged rows.
  • input invalid: refused with exit code 2
  • input not json: refused with exit code 2
  • header missing: refused with exit code 2
  • duplicate column name: refused with exit code 2
  • ragged rows: refused with exit code 2

Limits and scope

Limits
Type inference is strict: one stray text value makes a number column a string column, which is itself a finding. Dates are recognized only in YYYY-MM-DD form. Outlier fences assume a single group; mixed populations need splitting first. Values are trimmed before counting.
Work activities
Evaluate data quality; Record research or operational data; Compile data or documentation.

Details

Kind
Code module
Licence
MIT
Declared effects
runs commands
Source
github.com/alisonjieli-png/loop-engine/tools/creative_originals/occupation_task_kits/items/column_profile
Size
12 files, 62.3 KB
Identity
library.supply.creative_originals.4b34f569a96c4fe3210b361e.a07efb6d4361cb46
Version
a07efb6d4361cb4689f551a12ea05f1d5d8edb41d37737a451a464af47bfc72d

The version is the SHA-256 of the item your harness downloads; every file in it names its own checksum.

Where it is shown

Related components

Something wrong with this item, its rights or its safety? Report it on the support page, or from your harness after a download.