Skip to content

lucsapin/expense-tracker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

4 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Enhanced Expense Tracker

A comprehensive, user-friendly tool for tracking personal and shared expenses with advanced features including budget tracking, data analysis, and visualizations.

โœจ New Features

  • ๐ŸŽฏ Budget Tracking: Set monthly budgets by category and get alerts
  • ๐Ÿ“Š Data Analysis: Detailed insights and spending trends
  • ๐Ÿ“ˆ Visualizations: Charts and graphs for better understanding
  • ๐Ÿ” Smart Search: Find expenses by date, category, or amount
  • ๐Ÿ“ฑ Better UX: Emoji-enhanced interface with validation
  • ๐Ÿ’พ Data Integrity: Robust error handling and data validation
  • ๐Ÿ“ Organized Structure: Better file management and organization

๐Ÿ—๏ธ Project Structure

Expense Tracker/
โ”œโ”€โ”€ src/
โ”‚   โ””โ”€โ”€ add_new_expense.py           # Legacy simple expense adder
โ”‚   โ””โ”€โ”€ budget_tracker.py            # Budget management and alerts
โ”‚   โ””โ”€โ”€ data_analyzer.py             # Data analysis and visualizations
โ”‚   โ””โ”€โ”€ end_of_month_archive.py      # Legacy archiving
โ”‚   โ””โ”€โ”€ expense_tracker.py           # Main expense tracking application
โ”‚   โ””โ”€โ”€ monthly_expenses_monitor.py  # Legacy monthly summary
โ”‚   โ””โ”€โ”€ run.py                       # Main entry point for initializing and running the application
โ”‚   โ””โ”€โ”€ setup.py                     # setup instructions for the expense tracker project
โ”œโ”€โ”€ Expenses/
โ”‚   โ””โ”€โ”€ expenses_working.csv         # Current month's expenses
โ”‚   โ””โ”€โ”€ expenses_template.txt        # Current month's expenses
โ”œโ”€โ”€ History/                         # Archived monthly data
โ”œโ”€โ”€ Summary/                         # Monthly summaries
โ”œโ”€โ”€ Budget/                          # Monthly summaries
โ”‚   โ””โ”€โ”€ charges.json                 # Current month's expenses
โ”‚   โ””โ”€โ”€ income.csv                   # Income tracking
โ”œโ”€โ”€ requirements.txt                 # Python dependencies
โ”œโ”€โ”€ README.md                        # This file

๐Ÿš€ Quick Start

1. Setup Environment

# Create virtual environment
python3 -m venv .venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate

# Install dependencies
pip install -r requirements.txt

2. Run the Enhanced Tracker

python src/expense_tracker.py

๐Ÿ“‹ Main Features

๐Ÿ’ฐ Expense Tracking (expense_tracker.py)

  • Add Expenses: Intuitive interface with category selection
  • View Recent: See your latest transactions
  • Monthly Summary: Comprehensive spending overview
  • Archive Month: End-of-month data management

๐ŸŽฏ Budget Management (budget_tracker.py)

  • Set Budgets: Configure monthly limits by category
  • Track Progress: Monitor spending vs. budget
  • Get Alerts: Warnings when approaching limits
  • Interactive Setup: Easy budget configuration

๐Ÿ“Š Data Analysis (data_analyzer.py)

  • Spending Trends: Analyze patterns over time
  • Category Analysis: Detailed breakdown by category
  • Account Comparison: Compare spending between accounts
  • Generate Charts: Visual representations of your data
  • Smart Insights: AI-powered recommendations

๐ŸŽฎ Usage Examples

Adding an Expense

python src/expense_tracker.py
# Select option 1: Add new expense
# Follow the interactive prompts

Setting Up Budgets

python src/budget_tracker.py
# Select option 3: Setup budgets
# Configure limits for each category

Analyzing Your Data

python src/data_analyzer.py
# Select option 1: Spending trends
# View insights and recommendations

๐Ÿ“Š Sample Output

Monthly Summary

๐Ÿ“ˆ MONTHLY SUMMARY - 2025-01
============================================================

๐Ÿ‘ค Commun: โ‚ฌ1,847.35
   ๐Ÿ“‚ Maison: โ‚ฌ1,141.35 (61.8%)
   ๐Ÿ“‚ Transport: โ‚ฌ63.00 (3.4%)
   ๐Ÿ“‚ Courses: โ‚ฌ141.00 (7.6%)
   ๐Ÿ“‚ Culture: โ‚ฌ14.00 (0.8%)
   ๐Ÿ“‚ Autre: โ‚ฌ488.00 (26.4%)

๐Ÿ‘ค Luc: โ‚ฌ1,147.00
   ๐Ÿ“‚ Restaurant: โ‚ฌ66.00 (5.8%)
   ๐Ÿ“‚ Shopping: โ‚ฌ258.00 (22.5%)
   ๐Ÿ“‚ Autre: โ‚ฌ823.00 (71.7%)

๐Ÿ’ฐ TOTAL EXPENSES: โ‚ฌ2,994.35

Budget Alerts

๐Ÿ“Š Budget Status: Luc - Shopping
   ๐Ÿ’ฐ Budget: โ‚ฌ150.00
   ๐Ÿ’ธ Spent: โ‚ฌ258.00
   ๐Ÿ“ˆ Percentage: 172.0%
   โš ๏ธ  WARNING: Budget exceeded!

๐Ÿ”ง Configuration

Categories

The system includes these expense categories:

  • ๐Ÿ  Maison (Home)
  • ๐Ÿš— Transport
  • ๐Ÿฅ Santรฉ (Health)
  • ๐Ÿฝ๏ธ Restaurant
  • ๐Ÿ›’ Courses (Groceries)
  • ๐Ÿ’† Bien-รชtre (Wellness)
  • ๐ŸŽญ Culture
  • ๐Ÿƒ Sport
  • ๐Ÿ›๏ธ Shopping
  • ๐ŸŒญ Saucisse (Food)
  • ๐Ÿ’ต Liquide (Cash)
  • ๐Ÿ’ฐ Economie (Savings)
  • ๐ŸŽ Cadeau (Gifts)
  • ๐Ÿ“ฆ Autre (Other)

Accounts

  • Commun: Shared expenses
  • Luc: Personal expenses
  • Laura: Personal expenses

๐Ÿ“ˆ Data Export

The system automatically generates:

  • Monthly summaries in CSV format
  • Charts and visualizations as PNG files
  • Archived data for historical analysis

๐Ÿ› ๏ธ Customization

Adding New

Edit the categories dictionary in expense_tracker.py:

self.categories = {
    '๐Ÿ ': 'Maison',
    '๐Ÿš—': 'Transport',
    # Add your new categories here
    '๐ŸŽฎ': 'Gaming',
}

Modifying Budgets

Edit budgets.json or use the interactive setup:

{
  "Commun": {
    "Maison": 1500,
    "Transport": 200
  }
}

๐Ÿ”„ Migration from Legacy

If you're upgrading from the old system:

  1. Your existing data files are compatible
  2. Run the new tracker to get enhanced features
  3. Set up budgets for better tracking
  4. Use data analysis for insights

๐Ÿค Contributing

Feel free to customize and extend this project:

  • Add new features
  • Improve the UI
  • Add more analysis tools
  • Create custom reports

๐Ÿ“ Notes

  • All amounts are stored in euros (โ‚ฌ)
  • Dates use DD/MM/YYYY format
  • Data is automatically backed up in the History folder
  • Charts are saved in a charts/ directory

Happy tracking! ๐Ÿ’ฐ๐Ÿ“Š

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages