wsba-hockey


Namewsba-hockey JSON
Version 1.2.4 PyPI version JSON
download
home_pageNone
SummaryWeakSide Breakout's complete Python package of access to hockey data, primairly including the scraping of National Hockey League schedule, play-by-play, and shifts information.
upload_time2025-07-30 01:35:23
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseNone
keywords wsba hockey scraping nhl analytics
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # WSBA HOCKEY
![WSBA128](https://github.com/user-attachments/assets/4f349728-b99d-4e03-9d77-95cd177fefe2)

### A Python package for scraping and analyzing hockey data under the motto: ***Evaluating, analyzing, and understanding the game of hockey through the lens of different analytical methods, including incorporation of analytics.***

## INSTALLATION AND USAGE
```bash
pip install wsba_hockey
```

```python
import wsba_hockey as wsba
```

## ALL FEATURES

## SCRAPING
### NHL Play-by-Play (of any game frame up to a full season)
#### Functions:

```python
wsba.nhl_scrape_game(2024020918,split_shifts=False,remove=['game-end'])
wsba.nhl_scrape_season(20242025,split_shifts=False,remove=['game-end'],local=True)
```

### NHL Season Information

```python
wsba.nhl_scrape_schedule(20242025)
wsba.nhl_scrape_seasons_info(seasons=[20212022,20222023,20232024,20242025])
wsba.nhl_scrape_standings(arg = '2024-03-20')
```

### NHL Rosters and Player Information

```python
wsba.nhl_scrape_roster(20242025)
wsba.nhl_scrape_team_info()
```

### NHL Draft Rankings and Prospects

```python
wsba.nhl_scrape_draft_rankings()
wsba.nhl_scrape_prospects('BOS')
```


## DATA ANALYTICS
### Expected Goals
```python
pbp = wsba.nhl_scrape_game(2024020918,split_shifts=False,remove=['game-end'])
pbp = wsba.nhl_apply_xG(pbp)
```

### Goal Impacts and Shot Analysis

### Stat Aggregation
```python
pbp = wsba.nhl_scrape_season(20232024,remove=[], local = True)
wsba.nhl_calculate_stats(pbp,'skater',[2],['5v5','4v4','3v3'],shot_impact = True)
```
### Shot Plotting (Plots, Heatmaps, etc.)
```python
skater_dict = {
    'Patrice Bergeron':[20212022,'BOS']
}
pbp = wsba.nhl_scrape_season(20212022,remove=[], local = True)

wsba.nhl_plot_skaters_shots(pbp,skater_dict,['5v5'],onice='for',legend=True)
wsba.nhl_plot_games(pbp,legend=True)
```

## REPOSITORY 
### Past Season Play-by-Play
```python
wsba.repo_load_pbp(seasons=[20212022,20222023,20232024,20242025])
```
### Team Information
```python
wsba.repo_load_teaminfo()
wsba.repo_load_rosters(seasons=[20212022,20222023,20232024,20242025])
```
### Schedule
```python
wsba.repo_load_schedule(seasons=[20212022,20222023,20232024,20242025])
```

## DOCUMENTATION
View full documentation here: [WSBA Hockey Package Documentation](https://owensingh38.github.io/wsba_hockey/)

## ACKNOWLEDGEMENTS AND CREDITS 
### Huge thanks to the following:
Harry Shomer - Creator of the hockey_scraper package, which contains select utils functions within this package and otherwise inspires the creation of this package.

Dan Morse - Creator of the hockeyR package; another important inspiration and model for developing an NHL scraper.

Patrick Bacon - Creator of TopDownHockey package

Anyone in the NHL Public Analytics community who has stuck around and supported WeakSide Breakout Analysis hockey.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "wsba-hockey",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "wsba, hockey, scraping, NHL, analytics",
    "author": null,
    "author_email": "Owen Singh <owenbksingh@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/e2/ba/6046b16fdfaaa7b6a353b519d390f28a4c6380114369994f1080fdd3f950/wsba_hockey-1.2.4.tar.gz",
    "platform": null,
    "description": "# WSBA HOCKEY\r\n![WSBA128](https://github.com/user-attachments/assets/4f349728-b99d-4e03-9d77-95cd177fefe2)\r\n\r\n### A Python package for scraping and analyzing hockey data under the motto: ***Evaluating, analyzing, and understanding the game of hockey through the lens of different analytical methods, including incorporation of analytics.***\r\n\r\n## INSTALLATION AND USAGE\r\n```bash\r\npip install wsba_hockey\r\n```\r\n\r\n```python\r\nimport wsba_hockey as wsba\r\n```\r\n\r\n## ALL FEATURES\r\n\r\n## SCRAPING\r\n### NHL Play-by-Play (of any game frame up to a full season)\r\n#### Functions:\r\n\r\n```python\r\nwsba.nhl_scrape_game(2024020918,split_shifts=False,remove=['game-end'])\r\nwsba.nhl_scrape_season(20242025,split_shifts=False,remove=['game-end'],local=True)\r\n```\r\n\r\n### NHL Season Information\r\n\r\n```python\r\nwsba.nhl_scrape_schedule(20242025)\r\nwsba.nhl_scrape_seasons_info(seasons=[20212022,20222023,20232024,20242025])\r\nwsba.nhl_scrape_standings(arg = '2024-03-20')\r\n```\r\n\r\n### NHL Rosters and Player Information\r\n\r\n```python\r\nwsba.nhl_scrape_roster(20242025)\r\nwsba.nhl_scrape_team_info()\r\n```\r\n\r\n### NHL Draft Rankings and Prospects\r\n\r\n```python\r\nwsba.nhl_scrape_draft_rankings()\r\nwsba.nhl_scrape_prospects('BOS')\r\n```\r\n\r\n\r\n## DATA ANALYTICS\r\n### Expected Goals\r\n```python\r\npbp = wsba.nhl_scrape_game(2024020918,split_shifts=False,remove=['game-end'])\r\npbp = wsba.nhl_apply_xG(pbp)\r\n```\r\n\r\n### Goal Impacts and Shot Analysis\r\n\r\n### Stat Aggregation\r\n```python\r\npbp = wsba.nhl_scrape_season(20232024,remove=[], local = True)\r\nwsba.nhl_calculate_stats(pbp,'skater',[2],['5v5','4v4','3v3'],shot_impact = True)\r\n```\r\n### Shot Plotting (Plots, Heatmaps, etc.)\r\n```python\r\nskater_dict = {\r\n    'Patrice Bergeron':[20212022,'BOS']\r\n}\r\npbp = wsba.nhl_scrape_season(20212022,remove=[], local = True)\r\n\r\nwsba.nhl_plot_skaters_shots(pbp,skater_dict,['5v5'],onice='for',legend=True)\r\nwsba.nhl_plot_games(pbp,legend=True)\r\n```\r\n\r\n## REPOSITORY \r\n### Past Season Play-by-Play\r\n```python\r\nwsba.repo_load_pbp(seasons=[20212022,20222023,20232024,20242025])\r\n```\r\n### Team Information\r\n```python\r\nwsba.repo_load_teaminfo()\r\nwsba.repo_load_rosters(seasons=[20212022,20222023,20232024,20242025])\r\n```\r\n### Schedule\r\n```python\r\nwsba.repo_load_schedule(seasons=[20212022,20222023,20232024,20242025])\r\n```\r\n\r\n## DOCUMENTATION\r\nView full documentation here: [WSBA Hockey Package Documentation](https://owensingh38.github.io/wsba_hockey/)\r\n\r\n## ACKNOWLEDGEMENTS AND CREDITS \r\n### Huge thanks to the following:\r\nHarry Shomer - Creator of the hockey_scraper package, which contains select utils functions within this package and otherwise inspires the creation of this package.\r\n\r\nDan Morse - Creator of the hockeyR package; another important inspiration and model for developing an NHL scraper.\r\n\r\nPatrick Bacon - Creator of TopDownHockey package\r\n\r\nAnyone in the NHL Public Analytics community who has stuck around and supported WeakSide Breakout Analysis hockey.\r\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "WeakSide Breakout's complete Python package of access to hockey data, primairly including the scraping of National Hockey League schedule, play-by-play, and shifts information.",
    "version": "1.2.4",
    "project_urls": {
        "Homepage": "https://github.com/owensingh38/wsba_hockey/"
    },
    "split_keywords": [
        "wsba",
        " hockey",
        " scraping",
        " nhl",
        " analytics"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "54c008facf28b9ed08239bd36ce51fe07032dc20992982299df6c8c0d6c068c7",
                "md5": "0eaa01eebe3b93fd088b07b2ce386ea9",
                "sha256": "d779ec8d655b4a35f5b344f6d8a4db3299b891fc260783b166a541cd6a25c06c"
            },
            "downloads": -1,
            "filename": "wsba_hockey-1.2.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "0eaa01eebe3b93fd088b07b2ce386ea9",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 61444,
            "upload_time": "2025-07-30T01:35:22",
            "upload_time_iso_8601": "2025-07-30T01:35:22.478642Z",
            "url": "https://files.pythonhosted.org/packages/54/c0/08facf28b9ed08239bd36ce51fe07032dc20992982299df6c8c0d6c068c7/wsba_hockey-1.2.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e2ba6046b16fdfaaa7b6a353b519d390f28a4c6380114369994f1080fdd3f950",
                "md5": "f27cb95e3cc41b70c27148f572f111fd",
                "sha256": "d5bc133bac8ab8647b4851e79bc104ed9693eedb79d13e12520872ad04680833"
            },
            "downloads": -1,
            "filename": "wsba_hockey-1.2.4.tar.gz",
            "has_sig": false,
            "md5_digest": "f27cb95e3cc41b70c27148f572f111fd",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 59265,
            "upload_time": "2025-07-30T01:35:23",
            "upload_time_iso_8601": "2025-07-30T01:35:23.747073Z",
            "url": "https://files.pythonhosted.org/packages/e2/ba/6046b16fdfaaa7b6a353b519d390f28a4c6380114369994f1080fdd3f950/wsba_hockey-1.2.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-30 01:35:23",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "owensingh38",
    "github_project": "wsba_hockey",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "wsba-hockey"
}
        
Elapsed time: 4.10186s