Skip to content

Takes two current NBA players and compares them based on stats the user chooses from a list

Notifications You must be signed in to change notification settings

harshadodda/NBA-Player-Comparator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 

Repository files navigation

NBA-Player-Comparator

Summary:

This program takes two current NBA players and compares them based on stats the user chooses from a list. The program uses the requests and beautifulsoup modules from python to parse data from the Basketball Reference website. The data is then sifted and only the select statstics are taken and displayed. The program then shows the user which player is leading each stat.

Limitations:

-cannot parse data for players that are retired

-cannot parse data if user spells the name of the player wrong in any way, the name must be spelled perfectly

-cannot finish gathering statsics if the user enters which statistics they want incorrectly

Below is a sample of the running program:

Step 1 : We are prompted to list the names of two current NBA players by entering the first then the last name for each.

screen shot 2017-06-19 at 4 21 50 pm

Step 2: We are then prompted to choose the list of stats we want to compare and enter them as a space separated list spelled the way they are given in any order we want.

screen shot 2017-06-19 at 4 24 28 pm

Step 3: We will list all of the stats so we can compare the two players, Kevin Durant and LeBron James, based on all of the stats available to the program.

screen shot 2017-06-19 at 4 34 01 pm

Step 4: Now the program will compare the two players and list their stats as well as an arrow pointing to who is leading in that particular stat. The results are then shown in a table format.

screen shot 2017-06-19 at 3 40 13 pm

We can see here that Durant leads in 6 stat categories whereas James leads in 4 of the stat categories.

About

Takes two current NBA players and compares them based on stats the user chooses from a list

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages