🏐 Command-line tool to scrape volleyball statistics from Data Project Web Competition websites
GPL-3.0 License
Command-line tool to scrape volleyball statistics from Data Project Web Competition websites.
Volley Stats facilitates the export of data in CSV format of volleyball matches and competitions organized by entities that use Data Project WCM. The tool streamlines the collection of individual matches, match lists, and automates the retrieval of individual match data from the competition matches list.
Additionally, it documents the structure of URLs for Web Competition websites, simplifying the search for identifiers (mID, ID, PID), and also supplies acronyms for the main entities utilizing Data Project Management.
This tool is not affiliated with Genius Sports Italy.
pip install volleystats
Competition
Match
volleystats [--help] --fed FED (--match MATCH | --comp COMP | --batch CSV_FILE_PATH) [--pid PID] [--log]
--fed
, -f
: Federation Acronym (required)--match
, -m
: Statistics of a single match (required, unless --comp
or --batch
are provided)--comp
, -c
: List of matches in a competition (required, unless --match
or --batch
are provided)--pid
, -p
: PID of the competition (optional, only when --comp
is provided)--batch
, -b
: CSV file path with Match IDs (Competition Matches output) (required, unless --match
or --comp
are provided)--log
, -l
: View the logging during scraping--help
, -h
: Show help messagevolleystats --fed FED --match MATCH
Brazilian Volleyball Confederation
volleystats --fed cbv --match 1623
data/cbv-1623-22-10-28-guest-baruerivolleyballclub.csv
data/cbv-1623-22-10-28-home-fluminense.csv
Lithuanian Volleyball Federation
volleystats --fed lvf --match 2093
data/lvf-2093-2022-11-23-guest-jonavossc.csv
data/lvf-2093-2022-11-23-home-svaja-viktorija-lsu.csv
volleystats --fed FED --comp COMP
volleystats --fed cbv --comp 18
data/cbv-18-2022-2023-competition-matches.csv
In some competitions, PID can be used to distinguish between seasons, such as regular season and playoffs. Therefore, it is necessary to submit this value to obtain statistics separately.
volleystats --fed FED --comp COMP --pid PID
volleystats --fed vbl --comp 162 --pid 173
data/vbl-162-173-2022-2023-competition-matches.csv
volleystats --fed vbl --comp 162 --pid 174
data/vbl-162-174-2023-2023-competition-matches.csv
volleystats --fed FED --batch CSV_FILE_PATH
volleystats --fed cbv --batch data/cbv-18-2022-2023-competition-matches.csv
data/cbv-1623-22-10-28-guest-baruerivolleyballclub.csv
data/cbv-1623-22-10-28-home-fluminense.csv
data/cbv-1618-2022-11-01-guest-energis8sãocaetano.csv
data/cbv-1618-2022-11-01-home-esporteclubepinheiros.csv
data/cbv-1619-2022-11-01-guest-abelmodavolei.csv
data/cbv-1619-2022-11-01-home-gerdauminas.csv
...
volleystats --help
volleystats --fed FED (--match MATCH | --comp COMP | --batch CSV_FILE_PATH) --log
.
|`.
| `.
|-_ `.
| -_ `._
____________________|____-_ _|_______________,
', -_| ',
', | ',
', | ',
',_____________________|______________________',
volleystats: started
volleystats: data/cbv-1623-22-10-28-home-fluminense.csv file was created
volleystats: data/cbv-1623-22-10-28-guest-baruerivolleyballclub.csv file was created
volleystats: finished
Hostname: <Fed_Acronym>
-web.dataproject.com
Pathnames and search parameters:
/MainHome
/History?ID=<Fed_ID>
/CompetitionHome?ID=<Category_ID>
(could be Women, Men, Pro or Youth, e.g.)
/CompetitionMatches?ID=<Competition_ID>
&PID=<PID>
(PID could be regular season or playoffs, e.g.)
/MatchStatistics?mID=<Match_ID>
&ID=<Competition_ID>
European Volleyball
fshv
: Albanian Volleyball Federation
bvl
: Baltic League
bevl
: Belgium Volleyball Federation
osbih
: Bosnia and Herzegovina Volleyball Federation
bvf
: Bulgarian Volleyball Federation
vbl
: Bundesliga
hos
: Croatian Volleyball Federation
cvf
: Czech Volleyball Federation
evf
: Estonian Volleyball Federation
fbf
: Faroe Islands Volleyball Association
lml
: Finland Volleyball League
eope
: Hellenic Volleyball Federation
hvl
: Hellenic Volleyball League
hvf
: Hungary Volleyball Federation
bli
: Icelandic Volleyball Association
iva
: Israel Volleyball Association
fipav
: Italian Volleyball Federation
vfrk
: Volleyball Federation of Republic of Kazakhstan
latvf
: Latvian Volleyball Federation
lnv
: Ligue Nationale de Volley
lvf
: Lithuanian Volleyball Federation
mva
: Malta Volleyball Association
nvbf
: Norwegian Volleyball Federation
fpv
: Portuguese Volleyball Federation
frv
: Romanian Volleyball Federation
ossrb
: Serbian Volleyball Federation
svf
: Slovak Volleyball Federation
ozs
: Slovenian Volleyball Federation
rfevb
: Spanish Volleyball Federation
svbf
: Swedish Volleyball Federation
swi
: Swiss Volley
tvf
: Turkish Volleyball Federation
uvf
: Ukrainian Volleyball Federation
pvlu
: Professional Volleyball League of Ukraine
South American Volleyball
feva
: Argentine Volleyball Federation
cbv
: Brazilian Volleyball Confederation
fcv
: Cordoba Volleyball Federation
fpdv
: Peruvian Volleyball Federation
In some cases, empty files may be returned, usually named as <fed_acronym>-<match_id>-guest_stats.csv
and <fed_acronym>-<match_id>-home_stats.csv
. This can happen due to the hiding of a match in the competition listing, either because it was canceled or incorrectly entered. The match is hidden from view, but it remains accessible in the HTML, causing the tool to return an empty file. In such cases, simply ignore and delete this file.
It can also happen that the data is only available in PDF, which makes scraping impossible.
$ git clone [email protected]:claromes/volleystats.git
$ cd volleystats
$ pip install -r requirements.txt
$ pip install --editable .