Skip to main content

A lightweight (5 KB) Python client to retrieve NBA data from stats.nba.com

Project description

dlo

A lightweight (5 KB) Python client to retrieve NBA data from stats.nba.com.

Installation

pip install dlo                                     # definite stable version
git clone https://github.com/avkondepudi/dlo.git    # latest version
pip install .

Dependencies

  • requests (required)
  • pandas (recommended)

Usage

The API isn't publicly well-documented. You can find a list of endpoints here and here.

from dlo import Data                                # import module

LOCAL = {                                           # set local parameters
    "PlayerID": 1626156,
    "Season": "2018-19",
    "SeasonType": "Regular Season"
}

d = Data(**LOCAL)                                   # create instance of Data class with local parameters
d.endpoint = "playergamelog"                        # set endpoint

data = d.getData()                                  # get data (game log of D'Angelo Russell for 2018-19 Regular Season)

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

dlo-0.0.5.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

dlo-0.0.5-py3-none-any.whl (16.3 kB view details)

Uploaded Python 3

File details

Details for the file dlo-0.0.5.tar.gz.

File metadata

  • Download URL: dlo-0.0.5.tar.gz
  • Upload date:
  • Size: 6.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.33.0 CPython/3.6.3

File hashes

Hashes for dlo-0.0.5.tar.gz
Algorithm Hash digest
SHA256 07ac5bb7dd4e9dc0f6cd5817cde7ec37f6a53a027a5d0f479c4eba996f568c80
MD5 1a7a70f1f7ff02bc2a794463c0e566a9
BLAKE2b-256 099e263b7d803deeacbad8826202df15963be17de2c19cede36a0f9929833cf1

See more details on using hashes here.

File details

Details for the file dlo-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: dlo-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 16.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.33.0 CPython/3.6.3

File hashes

Hashes for dlo-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 01574ebce60737594a416b0b460cfe6709155ac513bf9947ffa92243186bdd4e
MD5 232b156c603f21c6579e776daf402de3
BLAKE2b-256 a18c71ad083a3629a9aa2175f425f1c343e74675edbb73c7bba62955096bc8f2

See more details on using hashes here.

Supported by

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