{ "info": { "author": "Matthew Barlowe", "author_email": "matt@barloweanalytics.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Science/Research", "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Programming Language :: Python :: 3.6", "Topic :: Software Development :: Build Tools" ], "description": "[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)\n[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://github.com/mcbarlowe/nba_scraper/commits/master)\n[![PyPI version](https://badge.fury.io/py/nba-scraper.svg)](https://badge.fury.io/py/nba-scraper)\n[![Downloads](https://pepy.tech/badge/nba-scraper)](https://pepy.tech/project/nba-scraper)\n[![Build Status](https://travis-ci.org/mcbarlowe/nba_scraper.svg?branch=master)](https://travis-ci.org/mcbarlowe/nba_scraper)\n[![codecov](https://codecov.io/gh/mcbarlowe/nba_scraper/branch/master/graph/badge.svg)](https://codecov.io/gh/mcbarlowe/nba_scraper)\n\n# `nba_scraper`\n\nThis is a package written in Python to scrape the NBA's api and produce the\nplay by play of games either in a `csv` file or a `pandas` dataframe. This package\nhas two main functions `scrape_game` which scrapes an individual game or a list\nof specific games, and `scrape_season` which scrapes an entire season of regular\nseason games.\n\nAs of right now the package only scrapes as far back as the 2016 season. Plans\nare in place to be able to scrape older seasons, however these older seasons\nwon't have x/y locations for all events as the more recent seasons do.\n\n# Installation\n\nTo install this package just type this at the command line:\n\n pip install nba_scraper\n\n# Usage\n\n## `scrape_game`\n\nThe default data format is a pandas dataframe you can change this to csv\nwith the `data_format` parameter. The default file path is the\nusers home directory you can change this with the `data_dir` parameter\n\n import nba_scraper.nba_scraper as ns\n\n # if you want to return a dataframe\n # you can pass the function a list of strings or integers\n # all nba game ids have two leading zeros but you can omit these\n # to make it easier to create lists of game ids as I add them on\n nba_df = ns.scrape_game([21800001, 21800002])\n\n # if you want a csv if you don't pass a file path the default is home\n # directory\n ns.scrape_game([21800001, 21800002], data_format='csv', data_dir='file/path')\n\n## `scrape_season`\n\nThe `data_format` and `data_dir` key words are used the excat same way as\n`scrape_game`. Instead of game ids though, you would pass the season you want\nscraped to the function. This season is a four digit year that must be an\ninteger.\n\n import nba_scraper.nba_scraper as ns\n\n #scrape a season\n nba_df = ns.scrape_season(2019)\n\n # if you want a csv if you don't pass a file path the default is home\n # directory\n ns.scrape_season(2019, data_format='csv', data_dir='file/path')\n\n## `scrape_date_range`\n\nThis allows you to scrape all **regular season** games in the date range passed to\nthe function. As of right now it will not scrape playoff games. Date format must\nbe passed in the format `YYYY-MM-DD`.\n\n import nba_scraper.nba_scraper as ns\n\n #scrape a season\n nba_df = ns.scrape_date_range('2019-01-01', 2019-01-03')\n\n # if you want a csv if you don't pass a file path the default is home\n # directory\n ns.scrape_date_range('2019-01-01', 2019-01-03', data_format='csv', data_dir='file/path')\n\n# Contact\n\nIf you have any troubles or bugs please **open an issue/bug report**. If you have\nany improvements/suggestions please **submit a pull request**. If it falls outside\nthose two areas please feel free to email me at\n[matt@barloweanalytics.com](mailto:matt@barloweanalytics.com).", "description_content_type": "text/markdown", "docs_url": null, "download_url": "https://github.com/mcbarlowe/nba_scraper/archive/v0.2.9.8.tar.gz", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/mcbarlowe/nba_scraper", "keywords": "basketball,NBA,scraper", "license": "GNU General Public License v3.0", "maintainer": "", "maintainer_email": "", "name": "nba-scraper", "package_url": "https://pypi.org/project/nba-scraper/", "platform": "", "project_url": "https://pypi.org/project/nba-scraper/", "project_urls": { "Download": "https://github.com/mcbarlowe/nba_scraper/archive/v0.2.9.8.tar.gz", "Homepage": "https://github.com/mcbarlowe/nba_scraper" }, "release_url": "https://pypi.org/project/nba-scraper/0.2.9.8/", "requires_dist": null, "requires_python": "", "summary": "A Python package to scrape the NBA api and return a play by play file", "version": "0.2.9.8" }, "last_serial": 5829633, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "91fab18866b33847d4cd7d9e7d407cda", "sha256": "877e899508703b04774c40256d0d226b366e1dd05f8440cbe66d3aa7d8d8ec9a" }, "downloads": -1, "filename": "nba_scraper-0.1.tar.gz", "has_sig": false, "md5_digest": "91fab18866b33847d4cd7d9e7d407cda", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8268, "upload_time": "2019-05-03T05:41:03", "url": "https://files.pythonhosted.org/packages/97/80/9ea9a7fb31dd1bca7ff4150c07ef897fb45a569c10dabb36eefcc041d6c1/nba_scraper-0.1.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "96cb57db8f472206f0c6c0718cd65360", "sha256": "f3cb7c7214d95c90253544a2abb8fcbf33f114eef6440a873ee3483604de39c6" }, "downloads": -1, "filename": "nba_scraper-0.2.tar.gz", "has_sig": false, "md5_digest": "96cb57db8f472206f0c6c0718cd65360", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8258, "upload_time": "2019-05-03T06:21:04", "url": "https://files.pythonhosted.org/packages/ea/34/9dfd32144e69d9d98ed6e56fd8d5b0f540adf60443f12f05c1ef5c3b29f6/nba_scraper-0.2.tar.gz" } ], "0.2.3": [ { "comment_text": "", "digests": { "md5": "8cd460f4d54431f9569d3363c6dc2a5b", "sha256": "9d15af6b175b2c69b0c07f5ec0cbbbe457c404dfac31f9ca94a9d338cbb5f187" }, "downloads": -1, "filename": "nba_scraper-0.2.3.tar.gz", "has_sig": false, "md5_digest": "8cd460f4d54431f9569d3363c6dc2a5b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10707, "upload_time": "2019-05-03T06:52:04", "url": "https://files.pythonhosted.org/packages/74/2b/3c88c538a4f2421f22609e427b2edc85a19519be0e1996d5b7f742fd5fa9/nba_scraper-0.2.3.tar.gz" } ], "0.2.4": [ { "comment_text": "", "digests": { "md5": "78993a089301a0de6f37807a0b40ecba", "sha256": "f96187cd0ac00ec79b2a62a833693865367a0b065d64baf5b329742de63d8112" }, "downloads": -1, "filename": "nba_scraper-0.2.4.tar.gz", "has_sig": false, "md5_digest": "78993a089301a0de6f37807a0b40ecba", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11033, "upload_time": "2019-05-07T21:54:58", "url": "https://files.pythonhosted.org/packages/34/9b/5cb014dd9b125b58abb4ace9b3750679bbdbbcc9fadb7fbd63efc794c22f/nba_scraper-0.2.4.tar.gz" } ], "0.2.5": [ { "comment_text": "", "digests": { "md5": "4dfdf23f6db1f9d94058b80bbd93d780", "sha256": "75e3cf622695e5d7b052e8c84fb850fcef6d9caec69219d4f2dca4f4298a761b" }, "downloads": -1, "filename": "nba_scraper-0.2.5.tar.gz", "has_sig": false, "md5_digest": "4dfdf23f6db1f9d94058b80bbd93d780", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12231, "upload_time": "2019-05-08T03:42:33", "url": "https://files.pythonhosted.org/packages/d0/50/c3ccde5b8ffb34df6e52bfa2714aade4af11a490096a8c384153290786a3/nba_scraper-0.2.5.tar.gz" } ], "0.2.6": [ { "comment_text": "", "digests": { "md5": "943b1cfb8af4e32fa3a435b4091b2bdb", "sha256": "60e704b797c27de7f0f418b712386d8abf7add57b99d3ed9d3e13c7d6875ff73" }, "downloads": -1, "filename": "nba_scraper-0.2.6.tar.gz", "has_sig": false, "md5_digest": "943b1cfb8af4e32fa3a435b4091b2bdb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14480, "upload_time": "2019-05-15T07:19:34", "url": "https://files.pythonhosted.org/packages/b6/f3/fbc0f5bb076fd403b5717c52bb8f80c2c07e8e0368381b472c820c01008d/nba_scraper-0.2.6.tar.gz" } ], "0.2.7": [ { "comment_text": "", "digests": { "md5": "2402d89cd7e631abe72cf3610f05984b", "sha256": "346a46a86f6716ec3b057176d47eb6dac75bca82d5753be9d471589ea3c06877" }, "downloads": -1, "filename": "nba_scraper-0.2.7.tar.gz", "has_sig": false, "md5_digest": "2402d89cd7e631abe72cf3610f05984b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14428, "upload_time": "2019-05-15T14:30:03", "url": "https://files.pythonhosted.org/packages/53/b9/8868729207d1da45b96bdf1bdccdd46f031d91f2357da04adb6e0114f35b/nba_scraper-0.2.7.tar.gz" } ], "0.2.8": [ { "comment_text": "", "digests": { "md5": "13cba4fecc79cec76ab7763561cf5d5b", "sha256": "0107e26c910f6903c9a5f3b8e00e50c9a1a20d74762643d65d8cd62e764169ba" }, "downloads": -1, "filename": "nba_scraper-0.2.8.tar.gz", "has_sig": false, "md5_digest": "13cba4fecc79cec76ab7763561cf5d5b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14440, "upload_time": "2019-05-18T01:08:11", "url": "https://files.pythonhosted.org/packages/04/6d/a9063b2a267badd90343f6943f48975fab1fd9aa9c66e4a22da4661e349b/nba_scraper-0.2.8.tar.gz" } ], "0.2.9": [ { "comment_text": "", "digests": { "md5": "5d5e2235f642685e6faf396f4832dc30", "sha256": "23de93f368578a8ea4a0f7f4b7a6da73d32785c4ad4de43597a2465227645aef" }, "downloads": -1, "filename": "nba_scraper-0.2.9.tar.gz", "has_sig": false, "md5_digest": "5d5e2235f642685e6faf396f4832dc30", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14489, "upload_time": "2019-05-18T21:16:21", "url": "https://files.pythonhosted.org/packages/82/85/b75b9bdf844f408d07e6962ab842b86fe24dcc39f77a5befda79289c3a44/nba_scraper-0.2.9.tar.gz" } ], "0.2.9.1": [ { "comment_text": "", "digests": { "md5": "e1cfe34f1b8be97c37df7ae0017c4426", "sha256": "41ea1d9b3a8bd0c1b4dcb35b9155709d3ee6c7763e414586becf54b74e07956d" }, "downloads": -1, "filename": "nba_scraper-0.2.9.1.tar.gz", "has_sig": false, "md5_digest": "e1cfe34f1b8be97c37df7ae0017c4426", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14552, "upload_time": "2019-05-18T22:28:24", "url": "https://files.pythonhosted.org/packages/d6/ce/18888965a54c148939ff898689de87065ec2d9de91151d34d892c381375b/nba_scraper-0.2.9.1.tar.gz" } ], "0.2.9.2": [ { "comment_text": "", "digests": { "md5": "a36bc73e099208161fac657009c9e78a", "sha256": "d9b4fd3fcd12193d115ca2a24fa15c50f7f92a4cc16b00e538c15d6103f26317" }, "downloads": -1, "filename": "nba_scraper-0.2.9.2.tar.gz", "has_sig": false, "md5_digest": "a36bc73e099208161fac657009c9e78a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14552, "upload_time": "2019-05-19T01:25:43", "url": "https://files.pythonhosted.org/packages/7c/0d/5f107d01ae08ac249c7898343212d4d1cf0a34993bc00205e46628a04fcf/nba_scraper-0.2.9.2.tar.gz" } ], "0.2.9.3": [ { "comment_text": "", "digests": { "md5": "1e87c1204d56b7912732a19cb04f1a0d", "sha256": "7917310990309d982545c895e02d4313a4c064c5f8eb5aec5dc73618869ea0b5" }, "downloads": -1, "filename": "nba_scraper-0.2.9.3.tar.gz", "has_sig": false, "md5_digest": "1e87c1204d56b7912732a19cb04f1a0d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14520, "upload_time": "2019-05-19T01:48:48", "url": "https://files.pythonhosted.org/packages/f3/7f/d477c588fbed4f773be25f5b74b275621dd144399d060fb96441a1185a09/nba_scraper-0.2.9.3.tar.gz" } ], "0.2.9.4": [ { "comment_text": "", "digests": { "md5": "075d461c9e8d0ede490e9f1a88649209", "sha256": "a7922b3c89f2a99bfeb13ca027a6a70970ebd1d5b36cfec3dcf38bfd29c8cbfd" }, "downloads": -1, "filename": "nba_scraper-0.2.9.4.tar.gz", "has_sig": false, "md5_digest": "075d461c9e8d0ede490e9f1a88649209", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14618, "upload_time": "2019-06-10T04:19:30", "url": "https://files.pythonhosted.org/packages/fb/ec/d44583a61034d79a3dea4c61c2ba694a32ca44a798ffe35b245f5daaefad/nba_scraper-0.2.9.4.tar.gz" } ], "0.2.9.5": [ { "comment_text": "", "digests": { "md5": "d93ff9256a4e3875f2d556653366327c", "sha256": "eb1701a7ee2bedc9a78533cd302b929b4b8f555d22c9c4b6a538d208f2ac8eca" }, "downloads": -1, "filename": "nba_scraper-0.2.9.5.tar.gz", "has_sig": false, "md5_digest": "d93ff9256a4e3875f2d556653366327c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14612, "upload_time": "2019-06-18T08:07:31", "url": "https://files.pythonhosted.org/packages/b9/0f/47ad26742f11a53d964b2cedbd0afdc9664103fd19cfcec66b9b86f3682c/nba_scraper-0.2.9.5.tar.gz" } ], "0.2.9.6": [ { "comment_text": "", "digests": { "md5": "41e8772d66ab73cf95afefceae54904a", "sha256": "803003760faab0c065c6826c191079f2ecb37cee729281c418998b0b31faaf2a" }, "downloads": -1, "filename": "nba_scraper-0.2.9.6.tar.gz", "has_sig": false, "md5_digest": "41e8772d66ab73cf95afefceae54904a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14579, "upload_time": "2019-07-14T02:52:48", "url": "https://files.pythonhosted.org/packages/bd/c9/d55cd1bbcf7e3b26f43a40b693aeb667fe7790dbfae2463f21f0a3a9415f/nba_scraper-0.2.9.6.tar.gz" } ], "0.2.9.7": [ { "comment_text": "", "digests": { "md5": "2308919bc71fcaaae36ecb7899fe6b0d", "sha256": "b13a48b9a232e92a8e7d656b72ccef115e1471106733e773767eb73d4e8f1270" }, "downloads": -1, "filename": "nba_scraper-0.2.9.7.tar.gz", "has_sig": false, "md5_digest": "2308919bc71fcaaae36ecb7899fe6b0d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14550, "upload_time": "2019-07-24T02:48:35", "url": "https://files.pythonhosted.org/packages/74/45/59672f86b9f71b7841a7f8b44b334b03fd2b77a950bd0a36843250dd335b/nba_scraper-0.2.9.7.tar.gz" } ], "0.2.9.8": [ { "comment_text": "", "digests": { "md5": "5e80df8b42316e1dfd94070ab399ab90", "sha256": "0d5a0866ec6f172b763502159d32fd99b52563a135ea4ff508be0e12611f89c7" }, "downloads": -1, "filename": "nba_scraper-0.2.9.8.tar.gz", "has_sig": false, "md5_digest": "5e80df8b42316e1dfd94070ab399ab90", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14592, "upload_time": "2019-09-14T16:20:29", "url": "https://files.pythonhosted.org/packages/b4/d9/e066cd56bdd99f66738ee3086ae7570ba1a473854f01f4f8cd848949d446/nba_scraper-0.2.9.8.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "5e80df8b42316e1dfd94070ab399ab90", "sha256": "0d5a0866ec6f172b763502159d32fd99b52563a135ea4ff508be0e12611f89c7" }, "downloads": -1, "filename": "nba_scraper-0.2.9.8.tar.gz", "has_sig": false, "md5_digest": "5e80df8b42316e1dfd94070ab399ab90", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14592, "upload_time": "2019-09-14T16:20:29", "url": "https://files.pythonhosted.org/packages/b4/d9/e066cd56bdd99f66738ee3086ae7570ba1a473854f01f4f8cd848949d446/nba_scraper-0.2.9.8.tar.gz" } ] }