Summarize a CSV
Profiles a CSV so you can describe it before analysing it: per column, how many rows are filled, whether the values are numeric or text, and either min/max/mean or the most frequent values.
Standard library only — nothing to install.
Steps
Confirm the file path with the user if you are not certain of it.
Run the companion script:
python /workspace/skills/csv-summary/scripts/summarize.py <path-to-csv>Useful flags:
--delimiter ';'for European exports,--jsonwhen you want to post-process the result,--max-rows Nto profile only the first N rows of a very large file.Report the findings in prose, not as a dump of the script output. Lead with what the file is (one row per what?), then call out anything that will matter for the next step: columns with missing values, a column that looks numeric but is stored as text, a categorical column with only a handful of distinct values.
If the script reports a column as
textthat the user expects to be numeric, say so explicitly — it usually means stray units, thousands separators, or a placeholder likeN/A.
Notes
- The script never modifies the input file.
- A column counts as numeric only when every non-empty value parses as a number,
so a single
N/Aflips a column to text. That is deliberate: it surfaces dirty data instead of silently ignoring it.