Package: volleystats
Volley StatsCommand-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.InstallationRequirementPython 3.8+pipinstallvolleystatsDocumentationExtracted DataUsageMatchCompetition MatchesCompetition Matches with PIDMatches via Competition Matches fileHelpLogOutput messagesData Project Web Competition URLs structureHostnamePathnames and search parametersFederations, Confederations and Leagues AcronymEuropean VolleyballSouth American VolleyballTroubleshootingMatch files collected from batch fileExtracted DataCompetitionCompetition IDHome TeamGuest TeamHome PointsGuest PointsDateStadiumMatchMatch IDMatch dateHome TeamGuest TeamCoachStadiumTotal PointsBreak PointsWin-LostTotal ServesServe ErrosServe PointsTotal ReceptionsReception ErrosPositive Pass Percentage (Pos%)Excellent/ Perfect Pass Percentage (Exc.%)Total AttacksAttack ErrosBlocked AttackAttack Points (Exc.)Attack Points Percentage (Exc.%)Block PointsUsagevolleystats [--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--compor--batchare provided)--comp,-c: List of matches in a competition (required, unless--matchor--batchare provided)--pid,-p: PID of the competition (optional, only when--compis provided)--batch,-b: CSV file path with Match IDs (Competition Matches output) (required, unless--matchor--compare provided)--log,-l: View the logging during scraping--help,-h: Show help messageMatchvolleystats--fedFED--matchMATCHExamplesBrazilian Volleyball ConfederationData Project website:https://cbv-web.dataproject.com/MatchStatistics.aspx?mID=1623Federation Acronym: CBVMatch ID: 1623Command: $volleystats --fed cbv --match 1623Output files:data/cbv-1623-22-10-28-guest-baruerivolleyballclub.csv
data/cbv-1623-22-10-28-home-fluminense.csvLithuanian Volleyball FederationData Project website:https://lvf-web.dataproject.com/MatchStatistics.aspx?mID=2093Federation Acronym: LVFMatch ID: 2093Command: $volleystats --fed lvf --match 2093Output files:data/lvf-2093-2022-11-23-guest-jonavossc.csv
data/lvf-2093-2022-11-23-home-svaja-viktorija-lsu.csvCompetition Matchesvolleystats--fedFED--compCOMPExampleBrazilian Volleyball ConfederationData Project website:https://cbv-web.dataproject.com/CompetitionMatches.aspx?ID=18Federation Acronym: CBVCompetition ID: 18Command: $volleystats --fed cbv --comp 18Output file:data/cbv-18-2022-2023-competition-matches.csvCompetition Matches with PIDIn 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--fedFED--compCOMP--pidPIDExamplesBundesligaData Project website:https://vbl-web.dataproject.com/CompetitionMatches.aspx?ID=162&PID=173Federation Acronym: VBLCompetition ID: 162PID: 173Season: RegularCommand: $volleystats --fed vbl --comp 162 --pid 173Output file:data/vbl-162-173-2022-2023-competition-matches.csvData Project website:https://vbl-web.dataproject.com/CompetitionMatches.aspx?ID=162&PID=174Federation Acronym: VBLCompetition ID: 162PID: 174Season: PlayoffsCommand: $volleystats --fed vbl --comp 162 --pid 174Output file:data/vbl-162-174-2023-2023-competition-matches.csvMatches via Competition Matches filevolleystats--fedFED--batchCSV_FILE_PATHExampleBrazilian Volleyball ConfederationData Project website:https://cbv-web.dataproject.com/MatchStatistics.aspx?mID=IDFederation Acronym: CBVCSV file path (output of theCompetition Matches): data/cbv-18-2022-2023-competition-matches.csvCommand: $volleystats --fed cbv --batch data/cbv-18-2022-2023-competition-matches.csvOutput files: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
...Helpvolleystats--helpLogvolleystats--fedFED(--matchMATCH|--compCOMP|--batchCSV_FILE_PATH)--logOutput messages.
                    |`.
                    |  `.
                    |-_  `.
                    |  -_  `._
____________________|____-_ _|_______________,
',                         -_|                ',
  ',                         |                  ',
    ',                       |                    ',
      ',_____________________|______________________',

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: finishedData Project Web Competition URLs structureHostname:<Fed_Acronym>-web.dataproject.comPathnames 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>Federations, Confederations and Leagues AcronymsEuropean Volleyballfshv:Albanian Volleyball Federationbvl:Baltic Leaguebevl:Belgium Volleyball Federationosbih:Bosnia and Herzegovina Volleyball Federationbvf:Bulgarian Volleyball Federationvbl:Bundesligahos:Croatian Volleyball Federationcvf:Czech Volleyball Federationevf:Estonian Volleyball Federationfbf:Faroe Islands Volleyball Associationlml:Finland Volleyball Leagueeope:Hellenic Volleyball Federationhvl:Hellenic Volleyball Leaguehvf:Hungary Volleyball Federationbli:Icelandic Volleyball Associationiva:Israel Volleyball Associationfipav:Italian Volleyball Federationvfrk:Volleyball Federation of Republic of Kazakhstanlatvf:Latvian Volleyball Federationlnv:Ligue Nationale de Volleylvf:Lithuanian Volleyball Federationmva:Malta Volleyball Associationnvbf:Norwegian Volleyball Federationfpv:Portuguese Volleyball Federationfrv:Romanian Volleyball Federationossrb:Serbian Volleyball Federationsvf:Slovak Volleyball Federationozs:Slovenian Volleyball Federationrfevb:Spanish Volleyball Federationsvbf:Swedish Volleyball Federationswi:Swiss Volleytvf:Turkish Volleyball Federationuvf:Ukrainian Volleyball Federationpvlu:Professional Volleyball League of UkraineSouth American Volleyballfeva:Argentine Volleyball Federationcbv:Brazilian Volleyball Confederationfcv:Cordoba Volleyball Federationfpdv:Peruvian Volleyball FederationTroubleshootingMatch files collected from batch fileIn some cases, empty files may be returned, usually named as<fed_acronym>-<match_id>-guest_stats.csvand<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.Development$git clone git@github.com:claromes/volleystats.git$cd volleystats$pip install -r requirements.txt$pip install --editable .AuthorClaromes