Added comments.
Changed print-outs so we only print status on every 10th game.
Move position references to use rg_position.

calculate_defense_vs_position and calculate_league_avg are both now
using rg_position instead of position for calculations.

Also set up the file output to include floor and ceiling fantasy points.
Added Mean Squared Error values at bottom of regression CSV.
Removed printing of points.
Added function calculate_defense_vs_position_ranking().

This allows us to get a 1-30 ranking of each team in the league based
on the provided stat (or Fantasy Points) and position.
Removed salary files for current day.
Fix for issue 15 - Using incorrect opponent in projections

Removed “opponent” key from the player info hash.  It didn’t make any
sense in there and was incorrect (actual value was the opponent from
the previous game).  Now, we’re using a one-liner to decide whether the
game’s home or away team is the player’s team.

Also set up *get_players_in_game()* to drop any players without an
*rg_position* attribute.  This prevents errors down the line, and the
players usually have a fairly minimal role so it’s not a huge dea.
Ignoring IDEA metadata for project.
Fixes for salary importing

Made the file variable a class attribute so it could be set in a unit
test (instead of having to be a CL arg).  Moved all database logic into
a try/finally so we could add more logging during errors.  Also, added
a null check on rg_position so we don’t pick up players that won’t
match.
Added __init__ files in each directory to make imports easier.
Fix for issue 13.

Added a defense_vs_position table to cache all DvP calculations in
order to speed up regression.  Also added a model class
DefenseVsPosition and manager DefenseVsPositionManager to handle
database interactions.

Now, the Projections.calculate_defense_vs_position() call will
initially prime the cache to speed things up.  Also, the logic for
fetching the values has been moved to DefenseVsPositionManager, and if
there is no database hit, the value is calculated and then written to
the database.  This should be the last time the value needs to be
calculated for the stat/position/team/season/date combination.
Added minutes_played to baseline stats list.
Added function to calculate an average stat over the past n games.
Changed literal 2013 to the variable season when calculating projections
Fixed bug in get_players_in_game() function.

The function was assuming there was a game_totals_basic entry for each
player for a given date, regardless of whether or not they played.
This is incorrect, so some players don’t get picked up for updates.

Now, we evaluate each player based on their team membership for the
latest game they played, with players not fitting the home or visitor
team being thrown out.  This does cause a problem for players who just
got traded.  They’ll need to have played a game with their new team
once before they’ll be picked up again.
Removed regression file.

No need to save this.
Fix for issue 12 (Modify the BBR scraper to only collect info for last night's players)

Leveraged Projections to get the previous night’s games and then the
players in those games.  From there we just go through the alphabet and
skip any player not in that list.
Issue 16 (Keep track of injuries)

Added an Injury model class and InjuryManager database management class
(as well as tests).
Issue 16 (Keep track of injuries)

Added injuries table.