Skip to main content

No project description provided

Project description

Installation

With PIP:

pip install pycobb

From source:

git clone https://github.com/ryan-byrne/pycobb
cd pycobb
python install setup.py

Usage

Python

The pycobb Python Package and it's associated functions can be easily imported into an existing Python Project.

import pycobb

df = pycobb.get(pitchers=["Trevor Bauer"], batters=["Javier Baez"], years=[2018,2019])

This pycobb.get() returns a pandas DataFrame with stats on every pitch Trevor Bauer threw to Javier Baez in the 2018 and 2019 seasons.

Command Line Interface (CLI)

pycobb can return that same DataFrame from the command line. The option --print prints the DataFrame to the console:

pycobb get -p Trevor+Bauer -b Javier+Baez -y 2019 --print

Returns:

  pitch_type   game_date  release_speed  ...  spin_axis  delta_home_win_exp delta_run_exp
0         SL  2019-08-09           78.2  ...         80               0.058        -0.514
1         SL  2019-08-09           79.3  ...         81               0.000        -0.084
2         SL  2019-08-09           79.4  ...         87               0.046        -0.382
3         SL  2019-08-09           78.7  ...         81               0.020        -0.319
4         FC  2019-08-09           81.0  ...         68               0.000        -0.091
5         FF  2019-08-09           94.7  ...        202               0.000         0.121
6         FC  2019-08-09           81.7  ...         55               0.000         0.054
7         FC  2019-08-09           82.2  ...         70               0.000        -0.050
8         SL  2019-08-09           78.4  ...         79               0.000         0.037

[9 rows x 92 columns]

Additional Search Parameters

For a full list of search parameters, review the documentation

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pycobb-0.0.2.tar.gz (12.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pycobb-0.0.2-py3-none-any.whl (11.4 kB view details)

Uploaded Python 3

File details

Details for the file pycobb-0.0.2.tar.gz.

File metadata

  • Download URL: pycobb-0.0.2.tar.gz
  • Upload date:
  • Size: 12.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.1

File hashes

Hashes for pycobb-0.0.2.tar.gz
Algorithm Hash digest
SHA256 a86bd61e6ca64fc9121faa9ed2aa993ae76f8e3fb48d5903bb2cb3370937f6e6
MD5 26532fcd96b276ea5a2a26a735a520d2
BLAKE2b-256 631d4f953f688c287542c9235daca6fde047c5566143c745704f025b7772f00f

See more details on using hashes here.

File details

Details for the file pycobb-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: pycobb-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 11.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.1

File hashes

Hashes for pycobb-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d53a651cf45d3d1c35c95d762af65edbb7e543def8b843e1447a450dcd6dc842
MD5 74d657318c530adf876d1ab2bccd031c
BLAKE2b-256 46255fab19b1aeb0c774f8904335b691175e898664c5bed6f80ca27dbb8ad2a9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page