Pringleman83 / SportsBook

A sports data scraping and analysis tool
GNU General Public License v3.0
82 stars 38 forks source link

Development #65

Closed Pringleman83 closed 5 years ago

Pringleman83 commented 5 years ago

The game range option is now live in the reports menu. It can be used to select the range of fixtures and predictions to show based on games from today or days from today.

football.py:

Added a new function that takes the predictions list and date range. It then returns a new predictions list only containing games within that range and manual entries.

The predictions dictionaries in the predictions list now include the datetime object for each game. Also changed the prepare_predictions_dataframe function so that datetime objects are not added to the Pandas dataframe.

Created get_predictions_in_range which takes the predicitons list and the game range. It returns a new list of predictions from within the given range. Also strips the datetime objects from each predictions.

footballMenu.py:

Improved the way that fixtures are displayed (leagues are now separated like in predictions).

Separated manual game entries from regular entries when predictions are displayed.

Leagues are not shown for each individual game in fixtures and in predictions.

Fixed a few docstring typos.

scrapers.py:

Fixtures[0] now holds the league name, not the round number. Other variables across the code have been amended to account for this.