Skip to content
This repository has been archived by the owner on Dec 11, 2023. It is now read-only.
/ pyrankingfifa Public archive

A Python library for extract FIFA World Ranking.

License

Notifications You must be signed in to change notification settings

manucabral/pyrankingfifa

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pyrankingfifa

Deprecated library. Switch to pyfifa for better performance and support.

A lightweight and zero dependencies Python library that allows you to extract the Ranking FIFA since 2007.

This library wraps the FIFA Ranking through ceroaceros/soccerzz website. Note this isn't affiliated with FIFA or ceroaceros.

Installation

From PyPI

pip install pyrankingfifa

From source code clone it

git clone https://github.com/manucabral/pyrankingfifa.git

Usage

Setting up

from pyrankingfifa import Ranking

mens_ranking = Ranking('mens')

womens ranking is not available for now

Let's get current ranking.

ranking = mens_ranking.get()
for team in ranking:
    print(team.rank, team.name, team.points)

If you need more rank positions apply the param page=id

Let's get a specific ranking date.

ranking = mens.get(year=2018, month='aug')
for team in teams:
    print(team)

The library saves all requests rankings for a faster request speed, if you want to remove these files call refresh() method.

Constributions

All constributions, bug reports or fixes and ideas are welcome.