Working Time Analysis
This project analyzes working time data from a CSV file by:
- Importing the data into a DuckDB database
- Transforming the data for analysis
- Generating reports based on the data
Setup
Dependencies
Install the required dependencies:
pip install -r requirements.txt
Usage
1. Import Data
Run the import script to load the CSV data into DuckDB:
python3 import_data.py
This will:
- Create a DuckDB database file
working_times.db - Import the CSV data into a table
- Add an import timestamp to each record
2. Transform Data
Run the transformation script to create analytical views:
python3 transform_data.py
This will:
- Create summary tables with aggregated data
- Convert hours to days (using 8 hours = 1 day conversion)
- Add transformation timestamps
3. Analyze Data
Run the analysis script to generate reports:
python3 analyze_data.py
This will produce:
- Overall time summary
- Top projects by hours
- Busiest days
- Day distribution analysis
- Project-activity combinations
Data Structure
The analysis uses the following tables:
working_times: Raw imported dataworking_times_summary: Per-day, per-project aggregationproject_summary: Total time per projectdaily_summary: Total time per day
Each derived table includes timestamps for data lineage tracking.
Description
Languages
Python
100%