A comprehensive command-line tool for analyzing Fantasy Premier League (FPL) data, providing insights into player performance, form analysis, and value for money calculations.
- Top Players by Total Points β Season-long point leaders
- Top Players by Pick Rate β Most popular players among managers
- Top Players by Value for Money β Best points per million ratio
- Players by Position β Filter and analyze by specific positions
- Alphabetical & Team Sorting β Organized player listings
- Recent Form Analysis β Track player performance over recent gameweeks
- Historical Performance β Points up to specific gameweeks
- Detailed Form Analysis β In-depth performance breakdowns
- Multi-Player Form Comparison β Visual comparison of multiple players
- Full Gameweek History β Complete season performance record
- Specific Gameweek Stats β Detailed stats for any gameweek
- Points Visualization β Interactive charts showing point trends
- Price Tracking β Monitor player price changes over time
- Head-to-Head Comparisons β Compare two players side by side
- Custom Date Range Analysis β Analyze performance over specific periods
- Custom Period Comparisons β Compare players over defined timeframes
- Multi-Player Form Charts β Visual comparison of up to 6 players
- Python 3.7 or higher
- pip package manager
pip install requests pandas tabulate matplotlib numpy
# Clone the repository
git clone https://github.com/yourusername/fpl-analysis-tool.git
cd fpl-analysis-tool
# Install dependencies
pip install -r requirements.txt
# Run the application
python fpl_analysis.py
- Run the application:
python fpl_analysis.py
- The tool automatically fetches the latest FPL data from the official API.
- Navigate through the menu options using numbers (0-18).
- Top players by total points
- Top players by pick rate
- Top players by value for money
- Players by position
- All players (sorted alphabetically)
- All players (sorted by team)
- Top players by recent form
- Top players up to specific gameweek
- Player form analysis (detailed)
- Compare multiple players' form
- Player's full gameweek history
- Player's specific gameweek stats
- Player points chart
- Player price chart
- Compare two players' points
- Custom form analysis (date range)
- Custom period comparison
- Multi-player form comparison
- Exit application
Select option: 3
How many top players to show: 10
Enter position (goalkeeper/defender/midfielder/forward) or press Enter for all: midfielder
Minimum points threshold (default 50): 75
Select option: 9
Enter player ID: 123
Number of recent gameweeks (default 5): 8
Select option: 15
Enter first player ID: 123
Enter second player ID: 456
- API: Official Fantasy Premier League API
- Data Updates: Real-time data from the official FPL servers
- Coverage: All current season data including player stats, prices, and gameweek history
- Calculation: Total Points Γ· Cost (in millions)
- Purpose: Identify players providing the best return on investment
- Recent form, custom periods, and trend indicators for performance analysis.
- Percentage of FPL managers who own the player β useful for identifying differential picks.
- Language: Python 3.7+
- API Integration: RESTful API calls to FPL endpoints
- Data Processing: Pandas
- Visualization: Matplotlib
- Interface: Command-line with tabulated output
- Graceful handling of network/API failures
- Input validation
- Clean exit on keyboard interrupts
- Efficient data loading (single API call for season data)
- Caching to minimize redundant requests
- Optimized memory management
We welcome contributions!
# Fork the repository
git checkout -b feature/amazing-feature
# Make your changes
git commit -m 'Add amazing feature'
git push origin feature/amazing-feature
Open a Pull Request and describe your changes.
- Additional analysis features
- Performance optimizations
- UI/UX improvements
- Documentation enhancements
- Bug fixes and testing
- Web interface version
- Export functionality (CSV, PDF)
- Historical season data
- Team analysis features
- Transfer suggestions
- Fixture difficulty integration
- v1.0: Initial release with core analysis features
- v1.1: Added form comparison charts
- v1.2: Enhanced error handling and user experience
Issue | Solution |
---|---|
Error loading data | Check internet connection & FPL API |
Player ID not found | Ensure valid and active player ID |
Chart display issues | Ensure matplotlib is installed |
This project is licensed under the MIT License β see the LICENSE file.
- Fantasy Premier League for providing the official API
- Python Community for excellent data analysis libraries
- Contributors who help improve this tool
This tool is for educational and analytical purposes only. It is not affiliated with the official Fantasy Premier League game or the Premier League.
Author: Imran Ahmed Kamal
Data Source: Fantasy Premier League API
Last Updated: July 2025