Skip to content

ohusq/CSV-PDF-Report

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CSV to PDF Report Generator

This script compares two CSV files (supermarket_sales_dirty.csv and supermarket_sales_cleaned.csv) and creates a PDF report showing the top 5 biggest changes.

View the report PDF

Requirements

  • Python 3.14 or higher
  • uv package manager (fast alternative to pip)

How to use with uv

  1. Install uv (if not already installed):

    curl -LsSf https://astral.sh/uv/install.sh | sh

    Or see uv installation guide.

  2. Clone or download this project folder.

  3. Open a terminal in the project folder.

  4. Run the script using uv:

    uv run main.py

    uv will automatically install required dependencies (pandas, matplotlib) and then execute the script.

Input files

Place these two CSV files inside a datasets/ folder (relative to the script):

  • datasets/supermarket_sales_dirty.csv
  • datasets/supermarket_sales_cleaned.csv

Output

The script generates a file named report.pdf in the same folder. It contains:

  • A table with the top 5 changed values (old value → new value, plus the difference).
  • A horizontal bar chart of the absolute changes.

Troubleshooting

  • Ensure both CSV files have the same number of rows (the script will trim to the shortest file).

About

Portfolio showcase demo, writes a PDF report from csv file and compares them.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages