{
"info": {
"author": "William Stevenson",
"author_email": "stevenson.w@husky.neu.edu",
"bugtrack_url": null,
"classifiers": [
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3"
],
"description": "# SaberSQL\n\nSaberSQL is a software tool to help scrape data on MLB games from [Retrosheet](https://www.retrosheet.org) (dating back\nto 1903) and [BaseballSavant](https://baseballsavant.mlb.com), as well as information on players, umpires, and managers\n(via the [Chadwick Baseball Bureau Register](https://github.com/chadwickbureau/register)). This data can then be\nimported to a MySQL database, allowing you to do customized queries on over a century of data.\n\n## Installation\n### Requirements\nFor SaberSQL to work, you must have already installed [MySQL Community Server](https://dev.mysql.com/downloads/mysql/)\nand [Chadwick](http://chadwick.sourceforge.net/doc/index.html). MySQL is straightforward to install, and there is an\nexcellent guide to install Chadwick\n[here](https://www.pitchbypitch.com/2013/11/29/installing-chadwick-software-on-mac/).\n### Install SaberSQL\nTo install:\n```bash\npip3 install sabersql\n```\n\n## Usage\nTo download and import all data to your database, simply use the command:\n```bash\nsabersql [path] -u [username] -p [password] -a [address] -s [schema]\n```\nwhere:\n- path is the directory on your computer where downloaded data should be stored (as of May 2019, all of the data is\nabout 18GB total)\n- username is the user of the MySQL database\n- password is the user's password to the MySQL database\n- address is the network address of the MySQL database\n- schema is the name of the schema to be used (the schema should already exist, without any tables in it)\n\n##### Optional Arguments\n- `--download` - only download the data from the web without importing it (the MySQL database information can\nthen be omitted)\n\n- `--import` - only import the data (assumes data has already been downloaded)\n\n- `-y [year]` - only download and/or import a specific year's data\n\n- `--retrosheet` - only download and/or import Retrosheet data\n\n- `--statcast` - only download and/or import BaseballSavant data\n\n- `--people` - only download and/or import player, umpire, and manager data\n\n- `--undo` - undoes the command instead\n\n#### Notes\n- Data will not be re-downloaded or re-imported if a command is run multiple times. Additionally, a process will resume\nfrom where it left off if restarted.\n- These processes are not fast. It will take many hours to download and import all data.\n\n## Schema\nThe structure of the database is five tables: [person](#person), [pitch](#pitch), [event](#event), [game](#game), and\n[sub](#sub).\n\n#### person\nEach entry in this table represents someone who was a player, umpire, and/or manager.\n#### pitch\nEach entry in this table represents a pitch recorded by BaseballSavant. Descriptions of each field can be found\n[here](https://baseballsavant.mlb.com/csv-docs).\n#### event\nEach entry in this table represents an event that Chadwick processed from Retrosheet data. Descriptions of each field\ncan be found [here](http://chadwick.sourceforge.net/doc/cwevent.html).\n#### game\nEach entry in this table represents a game that Chadwick processed from Retrosheet data. Descriptions of each field\ncan be found [here](http://chadwick.sourceforge.net/doc/cwgame.html).\n#### sub\nEach entry in this table represents a substitution in a game that Chadwick processed from Retrosheet data. Descriptions\nof each field can be found [here](http://chadwick.sourceforge.net/doc/cwsub.html).\n\n## License\nCopyright 2019 William Stevenson\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\ndocumentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the\nrights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit\npersons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the\nSoftware.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE\nWARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR\nCOPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\nOTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.",
"description_content_type": "text/markdown",
"docs_url": null,
"download_url": "https://github.com/liam923/sabersql/archive/v1.2.0.tar.gz",
"downloads": {
"last_day": -1,
"last_month": -1,
"last_week": -1
},
"home_page": "https://github.com/liam923/sabersql",
"keywords": "",
"license": "",
"maintainer": "",
"maintainer_email": "",
"name": "sabersql",
"package_url": "https://pypi.org/project/sabersql/",
"platform": "",
"project_url": "https://pypi.org/project/sabersql/",
"project_urls": {
"Download": "https://github.com/liam923/sabersql/archive/v1.2.0.tar.gz",
"Homepage": "https://github.com/liam923/sabersql"
},
"release_url": "https://pypi.org/project/sabersql/1.2.0/",
"requires_dist": null,
"requires_python": "",
"summary": "SaberSQL is a tool to scrape baseball data from various sources and import it into a MySQL database.",
"version": "1.2.0"
},
"last_serial": 5915247,
"releases": {
"1.0.0": [
{
"comment_text": "",
"digests": {
"md5": "f5709ecdd79fd422c8c573e969e07bc3",
"sha256": "7f714d4abc2b24394072d05d03e99e9c151e24cc714d712995f6e4a95ffffd7f"
},
"downloads": -1,
"filename": "sabersql-1.0.0.tar.gz",
"has_sig": false,
"md5_digest": "f5709ecdd79fd422c8c573e969e07bc3",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 18743,
"upload_time": "2019-05-15T02:43:58",
"url": "https://files.pythonhosted.org/packages/86/a7/a94c056ab13e82ca2ba920d0d6a60703a675f094c7cd30f839d250d2698e/sabersql-1.0.0.tar.gz"
}
],
"1.0.1": [
{
"comment_text": "",
"digests": {
"md5": "49fa053b7b7e390f85daac703e66e239",
"sha256": "fa7ef10c0aec23797018cf193fee93f8091151c3e21a3dba1f6ec8f7d5890d68"
},
"downloads": -1,
"filename": "sabersql-1.0.1.tar.gz",
"has_sig": false,
"md5_digest": "49fa053b7b7e390f85daac703e66e239",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 18777,
"upload_time": "2019-05-15T02:54:27",
"url": "https://files.pythonhosted.org/packages/a5/49/ac665104074987aba81a7ba8c1e642f66918f00d21c0d6ec9974ab475907/sabersql-1.0.1.tar.gz"
}
],
"1.1.0": [
{
"comment_text": "",
"digests": {
"md5": "fb0c55d018037b8ced7257b21a1b8000",
"sha256": "d373c44df4f1d60dc122f09b661106d913594d0d125a4380cfedd2a48e68b09b"
},
"downloads": -1,
"filename": "sabersql-1.1.0.tar.gz",
"has_sig": false,
"md5_digest": "fb0c55d018037b8ced7257b21a1b8000",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 19266,
"upload_time": "2019-05-25T06:55:13",
"url": "https://files.pythonhosted.org/packages/14/b9/d96ea4ff4a6bcaa00618d55e79a6a1b124449ca60d6f861f3aed1c225606/sabersql-1.1.0.tar.gz"
}
],
"1.1.1": [
{
"comment_text": "",
"digests": {
"md5": "b1a7408df5e1549bcaa3f808c647c14d",
"sha256": "0a957b1aa2057b1f8802e548f6f7a6846f7c8473d7491e0ffbd427a5738137e8"
},
"downloads": -1,
"filename": "sabersql-1.1.1.tar.gz",
"has_sig": false,
"md5_digest": "b1a7408df5e1549bcaa3f808c647c14d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 19278,
"upload_time": "2019-09-02T22:51:18",
"url": "https://files.pythonhosted.org/packages/f1/9e/75442a64b23d5af1bc7b848633e2ba7a4754aae792c44dd26caec2d2ea6f/sabersql-1.1.1.tar.gz"
}
],
"1.2.0": [
{
"comment_text": "",
"digests": {
"md5": "0d4d048b6af4b4808e99708b675bc832",
"sha256": "4f24aa872d73f3f445b28fa2ff25c2ad9f0286f69b87dd30fcecfbb0f99db21e"
},
"downloads": -1,
"filename": "sabersql-1.2.0.tar.gz",
"has_sig": false,
"md5_digest": "0d4d048b6af4b4808e99708b675bc832",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 19338,
"upload_time": "2019-10-01T22:48:16",
"url": "https://files.pythonhosted.org/packages/ab/03/13171114a3bd2ece38536c7a35b51ea3325b9fc01a24ae8878cfda7bc9c7/sabersql-1.2.0.tar.gz"
}
]
},
"urls": [
{
"comment_text": "",
"digests": {
"md5": "0d4d048b6af4b4808e99708b675bc832",
"sha256": "4f24aa872d73f3f445b28fa2ff25c2ad9f0286f69b87dd30fcecfbb0f99db21e"
},
"downloads": -1,
"filename": "sabersql-1.2.0.tar.gz",
"has_sig": false,
"md5_digest": "0d4d048b6af4b4808e99708b675bc832",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 19338,
"upload_time": "2019-10-01T22:48:16",
"url": "https://files.pythonhosted.org/packages/ab/03/13171114a3bd2ece38536c7a35b51ea3325b9fc01a24ae8878cfda7bc9c7/sabersql-1.2.0.tar.gz"
}
]
}