Git Product home page Git Product logo

si507final's People

Contributors

linlihe avatar

Watchers

 avatar

si507final's Issues

Part 0: Cache main pages from hoop NBA

Part 0 : Cache main pages.

  • Import all modules needed
  • The main page of hoop NBA
  • The page for 2016-2017 season all teams
  • The page for 2016-2017 season all players
    • Note : no tests for this part
      Use try_except , request, and beautiful soup.

Submission

  • All html files cached
  • ReadME.md
  • SI507F17_finalproject.py
  • SI507F17_finalproject_tests.py
  • requirement.txt
  • Htmls used to show results in local link (Using "Flask")

Part 1: Set up classes for dealing with players and teams data.

Player Class should at least include 3 methods : init, repr, contains, tuple_method

  • init
    • The input should be a beautiful soup object
    • Includes player's name, player's team, attendance, and the average number of minutes, points, rebounds, assists, steals, blocks in each game. (May include more)
  • repr
    • Use format function to return a str including all items in init
  • contains
    • Make sure that the the player is who we expect
  • tuple_method
    • Return a tuple that includes each player's data we grab before to input into a database table later on.

Team Class should at least include 2 methods: init, tuple_method

  • init
    • The input should be a beautiful soup object
  • tuple_method
    • Return a tuple that includes each team's data we grab before to input into another database table later on.

Part 3: Build a database

Use PostgreSQL here

  • Create a database with 2 tables for player and team respectively.
  • Set column names, types, primary keys, and foreign keys if needed.
  • Two tables should be connected by the team name, since each player only have one team in the database.
    • Note: If a player was traded during the season, we say he belongs to new team here. Also, we only calculate the games data he played for new teams as his seasonal data.

Part 6: Check and ReadME

  • Add some "print" functions in order to make user understand what is going on in any situation when running this code.

  • Add some "if ... True" functions in order to run parts of the program every time we need rather than the whole program.

  • ReadME : Add the explaination to the printed words if it is needed.

Part 5: Test

  • Test player and team class method
  • Test the function in processing database
  • Total number of test method should be at least 15

Part 4: Result

  • Use "Flask" to show results

  • NBA players average

  • Calculate average value for each type of data for all players. Players' data would be equally weighted.

  • Calculate average value for each type of data for teams. Teams' data would be equally weighted.

  • The Most value player in each team.

  • Definition of MVP: The player has the largest number which equals to the sum of point, rebound, assistance.

  • "MVP" players average

  • Calculate the average value for each type of data for "MVP" players in order to see the level of being a team leader.

  • NBA Team data average

  • Calculate the average data incluing all attributes in the "Teams" class for 30 NBA team.

  • How important the best player in a team to the team

  • Use the best player's points, rebound, assist to divide by the team's point, rebound, assist data, and see the percentage.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.