My March Madness Bracket 2015

I’m just okay at picking basketball brackets. I usually finish somewhere in the upper third of the pack, IIRC.

However, it’s interesting to enter a bracket and watch the results come in (I almost never watch the games), so I usually make a bracket.

This year, I decided to use Coder’s Bracket to create my bracket.

If you haven’t already seen Coder’s Bracket, you should take a look. Basically, you algorithmically generate your bracket using JavaScript. However, setting that up manually is a lot of work. Fortunately, Coder’s Bracket has already done that for you. You provide a function taking three object parameters (game, team1, team2) that will call team1.winsGame() or team2.winsGame() depending on what you determine. You start with a simple seed-rules algorithm and work from there.

My algorithm runs basically like this:

  1. If it’s round 1 and the seed is greater than 5, it wins.
  2. If it’s round 2 and the seed is greater than 2, it wins.
  3. Otherwise, compute my extremely not scientific score for each team and the higher score wins.

My scoring algorithm takes into account strength of schedule (RPI), Field Goal %, Free Throw %, 3’s %, and Missed 3’s. I weight the values to make my bracket interesting (probably at the cost of correctness…).

There are probably a million and a half (exactly) problems with this algorithm, but it was fun to create.

You can see my bracket on Coder’s Bracket’s website.

I’ve included my algorithm below.

function(game, team1, team2){
  // Seeds 5 and better don't lose in the first round
  if (game.round == 5) {
    if (team1.seed >= 5 || team2.seed >= 5) {
      if (team1.seed > team2.seed) {
        team2.winsGame();
      } else {
        team1.winsGame();
      }
    }
  }
  // Seeds 2 and better don't lose in the second round
  if (game.round == 4) {
    if (team1.seed >= 3 || team2.seed >= 3) {
      if (team1.seed > team2.seed) {
        team2.winsGame();
      } else {
        team1.winsGame();
      }
    }
  }
  // Everyone else goes through my TOTALLY SCIENTIFIC scoring algorithm
  if (calcScore(team1) > calcScore(team2)) {
    team1.winsGame();
  } else {
    team2.winsGame();
  }

  // Scoring algorithm
  // Mostly objective, but I tweaked the weights to make my bracket interesting
  // I'm using the RPI, apparently a ranking of schedule difficulty to make win percentage be somewhat fair.
  // It's divided by two to lessen it's impact
  //
  // The numbers on the far side are the weights for each item
  function calcScore(team) {
    var myScore = 0;
    myScore += team.rpi/2 * team.win_pct * 10; // Winning percentage
    myScore += team.rpi/2 * team.field_goal_pct * 7; // Field Goal percentage
    myScore += team.rpi/2 * team.free_throw_pct * 4; // Free Throw percentage
    myScore += team.rpi/2 * team.three_point_pct * 5; // 3's percentage
    // Penalty for missing 3's. About 10 per game on average, so I divided by 20 to lessen the impact.
    myScore -= team.rpi/2 * (team.threes_attempted - team.threes_made)/20 * 3;
    return myScore;
  }
}

Leave a Reply

Your email address will not be published. Required fields are marked *