A Python application for analyzing and generating statistics from transaction data for Brothers Coins players.
This project processes transaction data from JSON files and generates comprehensive statistics about player transactions, including buy and sell operations.
BrothersCoinsTransactionsStatistics/
├── src/
│ ├── controller/
│ │ ├── app_manager.py # Main application orchestration
│ │ ├── file_manager.py # File I/O operations
│ │ ├── output_manager.py # Output handling
│ │ └── statistics/ # Statistics generation modules
│ ├── model/
│ │ ├── date/ # Date handling classes
│ │ ├── transaction/ # Transaction models
│ │ │ ├── transaction.py # Base Transaction class
│ │ │ ├── bank_transactions.py # Transaction collection manager
│ │ │ └── type_transaction.py # Transaction type definitions
│ │ └── singleton.py # Singleton pattern implementation
│ └── main.py # Application entry point
├── data/ # Transaction data files
└── README.md
- Transaction Management: Handles both buy and sell transactions
- Date Handling: Custom date management for transaction timestamps
- Statistics Generation: Analyzes transaction patterns and player activity
- Sortable Transactions: Transactions can be sorted by value and date
- Player Tracking: Monitors individual player transaction history
Run the application using:
python -m src.main- Transaction: Abstract base class representing a transaction with value, player name, and date
- BankTransactions: Manages collections of transactions with sorting and filtering capabilities
- AppManager: Orchestrates the application flow and manages data processing
- FileManager: Handles reading transaction data from files
- StatisticsGenerator: Generates analytical reports from transaction data
- Python 3.x
Transactions are stored in JSON format with the following structure:
{
"id": 1,
"value": 100,
"player": "PlayerName",
"date": {...}
}Positive values indicate buy transactions, negative values indicate sell transactions.