A Football Manager data-based scouting tool.
Project description
Football Manager Scouting
A tool for facilitating data-driven scouting in Football Manager
Explore the docs »
Report Bug
·
Request Feature
Table of Contents
About The Project
Football Manager Scouting is a python program for making data driven scouting easier in the FM games.
It currently provides two scouting tools:
· Spider
: Creates a radar chart (or, "spider") comparing the statistics of a player from your session with either the statistics of another player or with the average stats of a group of players.
· Index
: Creates a csv file displaying categorical information of the player (contract info, club, division, attributes etc.) and most importantly, a score for each statistical category as well as an overall index, showing how good the players has performed compared to the other players in dataset.
The program works by taking the raw rtf-file printed from the game, processing each value for each player, and saving them to an SQL database. When either of the two tools, Spider or Index, are used, the program retrieves the relevant data from the database and generates the desired radar chart or csv-file. The insert_data
module is therefore the entire programs entry point as it saves the player data to the database.
Football Manager Scouting also makes it possible to compare players/clubs/divisoin over several seasons by adding players to the database after every in-game season. Football Manager otherwise deletes a lot of data after a new season has started, making it difficult to, for instance, compare changes in age structure of your squad over the seasons.
Getting Started
- The first step is to download the data from Football Manager: 1a) In the scouting of the game, use the provided view from moneyball.fmf, 1b) Select all players, print, and save as text file (to rtf format).
- Create an empty PostgreSQL database,
- Install package:
pip install football-manager-scouting
.
See Usage for examples of how to insert data and use Spider and Index.
Prerequisites
- PostgreSQL,
- Python >= 3.8,
- SQLAlchemy >= 2.0
- psycopg2-binary >= 2.0
- tqdm >= 4.0
- Soccerplots = 1.0
Installation
pip install football-manager-scouting
Usage
Import the tools.
from football_manager_scouting import spider, index, insert_data
Create a dictionary with the login information to the PostgreSQL database.
db_login = {
'user': 'username',
'password': 'password',
'host': 'localhost:5432',
'database': 'database'
}
Insert the downloaded data to the database.
insert_to_database(
db_login=db_login,
path='./data.rtf', # The path to the downloaded file with the player data.
season=24, # The current in-game season.
total=50435, # The total number of players in the data file. For the progress bar. OPTIONAL.
n=50000 # After how many players should entries be commited to the database. For datafile with a large number (>100000) of players it is recommended to do several smaller commits.
)
Create a radar chart of a player comparing him to the other players of that position in the same division. The chart will be saved to ./spider.jpg
spider(
db_login=db_login,
name='John Doe', # The name of the player.
comparison='average', # If the comparison should be to another player or to the average of multiple players.
category='DC', # Filter which statistical categories that should be used in chart.
position='DC', # The position of the players.
mins=500, # The minimum number of minutes a player should have played to be included.
division='Premier League' # The division of the players.
)
Create an index csv file. The file will be saved to a csv file named after the category in the working directory.
index(
db_login=db_login,
category='STC', # Filter which statistical categories that should be used in the index.
position='STC, AMC', # The position of the players.
mins=500, # The minimum number of minutes a player should have played to be included.
division=None # The division of the included players. None means that it will not filter on division.
)
License
Distributed under the GNU License. See LICENSE
for more information.
Contact
Hannes Lindbäck - hanneskarllindback@gmail.com
Project Link: https://github.com/HannesLindback/Football-Manager-scouting
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file football_manager_scouting-0.1.1.tar.gz
.
File metadata
- Download URL: football_manager_scouting-0.1.1.tar.gz
- Upload date:
- Size: 27.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e3329a8ddb46a0764dd61b4b451b821754496ec48ab900533478d35c88185ca9 |
|
MD5 | 9264abcd1264e922f4d03413f74ffa53 |
|
BLAKE2b-256 | 37dd9ef1c1a957a5c097cac148ecea9eadfb5c3381c60005f88e524f4b95b42c |
File details
Details for the file football_manager_scouting-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: football_manager_scouting-0.1.1-py3-none-any.whl
- Upload date:
- Size: 28.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dd8498d3a5e8c343413a1a31a685c5c1251c9721e493947309434dac0bb0968b |
|
MD5 | e0226584e4274a31beecda1f50b14dca |
|
BLAKE2b-256 | 0767bf15b7fac1074108b713fb6219b3e1d91fc0d6dba5c36578c8c44e20450e |