anchor.diff:              .style("opacity", 1);
   
           // Make rank text
  -        var dataRanks = dataRows.selectAll(".dataRank").data(dataInt, key);
  +        dataRanks = dataRows.selectAll(".dataRank").data(dataInt, key);
   
           dataRanks.transition().delay(function(d) {
                   if (oldHeight > height) {
  
positive.code:             .attr("x", 0)
              .attr("y", 0)
              .attr("width", width)
              .attr("height", height);;
  
          var darkBorder = gAll.selectAll(".darkBorder").data([dataInt]);
  
          darkBorder.transition().delay(function(d) {
                  if (oldHeight > height) {
  
negative.code:     }
  
      function draw_graph_best_bets(resetExpanded) {
          // General Variables
          var svg;            // SVG to contain graph
          var dataInt;        // Internal reference to graph dataset
          var sortStates;     // 
          var key;            // Key function to maintain object constancy
          var triangle;       //
          // Dimension Variables
          var margin;         // Blank space around edge of SVG left as margin
          var rowHeight;      // Height of each row of data
          var width;          // Drawable width of SVG (not including margins)
          var height;         // Drawable height of SVG (not including margins)
          var oldHeight;      // Previous height of SVG
          var textPadding;    // Padding around text elements
          var barHeight;      // Height of data bars
          var rankWidth;      // Width of rank column
          var categoryWidth;  // Width of category column
          var serveWidth;     // Width of serves column
          var clickWidth;     // Width of click column
          var ratioWidth;     // Width of ratio column
          var childOffset;    // Horizontal offset for child elements drawn on element expansion
          var serveBarStart;  // Beginning x for serves data bar
          var clickBarStart;  // Beginning x for click data bar
          var ratioBarStart;  // Beginning x for ratio data bar
          var triangleSpacing;// Space around triangular sort buttons
          // Scale Variables
          var serveScale;     // Scale for serve count data bar
          var clickScale;     // Scale for click count data bar
          var ratioScale;     // Scale for ratio data bar
          // Selection Variables
          var groupEnter;     // Entry selection for gAll
          var gAll;           // Group containing all elements
          var headGroupEnter; // Entry selection for headRow
          var headRow;        // Group containing all head elements
          var headEnter;      // Entry selection for all head elements
          var triangles;      // Sort triangles
          var dataGroupEnter; // Entry selection for dataRows
          var dataRows;       // Group containing all data elements
          var dataRects;      // Background rectangles
          var dataRanks;      // Rank text
          var dataLabels;     // Label text
          var dataServes;     // Serve text
          var dataClicks;     // Click text
          var dataRatios;     // Ratio text
          var serveBar;       // Serve count data bar
          var clickBar;       // Click count data bar
          var ratioBar;       // Ratio data bar
          var lightBorder;    // Light border (surrounds all elements)
          var darkBorder;     // Dark border (surrounds data elements)
  
          // Initialize General variables ///////////////////////////////////////////////////////////
          svg = d3.select("#graph_best_bets");
  
          dataInt = Globals.Data;
  
          sortStates = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
          sortStates[Globals.Sort] = 1;
          
          key = function(d) {
              return d.key;
          };
  
          triangle = d3.symbol().type(d3.symbolTriangle).size(20);
  
          // Initialize Dimension variables /////////////////////////////////////////////////////////
          margin = {
              top: 20,
              right: 20,
              bottom: 20,
              left: 20
          };
          rowHeight = 35;
          width = +svg.attr("width") - margin.left - margin.right;
          height = (dataInt.length + 1) * rowHeight;
          oldHeight = Globals.Height;
          textPadding = 5;
          barHeight = 25;
          rankWidth = 2 * width / 20;
          categoryWidth = 5 * width / 20;
          serveWidth = 4 * width / 20;
          clickWidth = 4 * width / 20;
          ratioWidth = 5 * width / 20;
          childOffset = 20;
          serveBarStart = rankWidth + categoryWidth + 4 * textPadding + 13 * d3.max(dataInt, function(d) {
              return d.serves.toString().length;
          });
          clickBarStart = rankWidth + categoryWidth + serveWidth + 4 * textPadding + 13 * d3.max(dataInt, function(d) {
              return d.clicks.toString().length;
          });
          ratioBarStart = rankWidth + categoryWidth + serveWidth + clickWidth + 4 * textPadding + 13 * d3.max(dataInt, function(d) {
              return d.ratio.toString().length;
          });
          triangleSpacing = 15;
          
          // Initialize Scale variables /////////////////////////////////////////////////////////////
          serveScale = d3.scaleLinear().rangeRound([0, rankWidth + categoryWidth + serveWidth - serveBarStart - triangleSpacing]);
          serveScale.domain([0, d3.max(dataInt, function(d) {
              return d.serves;
          })]);
  
          clickScale = d3.scaleLinear().rangeRound([0, rankWidth + categoryWidth + serveWidth + clickWidth - clickBarStart - triangleSpacing]);
          clickScale.domain([0, d3.max(dataInt, function(d) {
              return d.clicks;
          })]);
  
          ratioScale = d3.scaleLinear().rangeRound([0, rankWidth + categoryWidth + serveWidth + clickWidth + ratioWidth - ratioBarStart - triangleSpacing]);
          ratioScale.domain([0, d3.max(dataInt, function(d) {
              return d.ratio;
          })]);
  
          // Misc ///////////////////////////////////////////////////////////////////////////////////
          // Transition the svg height depending on previous height
          svg.transition().delay(function(d) {
                  if (oldHeight > height) {
                      return 500;
                  } else {
                      return 0;
                  }
              })
              .duration(750)
              .attr("height", height + margin.top + margin.bottom)
              .on("end", function(d) {
                  Globals.Height = height;
              });
  
          // Reset expanded categories when after a resort
          if (resetExpanded) {
              dataInt.forEach(function(d) {
                  d.expanded = 0;
              });
          }
  
          // Make overarching group /////////////////////////////////////////////////////////////////
          groupEnter = svg.selectAll("g").data([dataInt]).enter();
  
          groupEnter.append("g")
              .attr("class", "gAll");
  
          gAll = svg.select(".gAll")
              .attr("transform", "translate(" + margin.left + "," + margin.top + ")");        
  
          // Make header row ////////////////////////////////////////////////////////////////////////
          headGroupEnter = gAll.selectAll(".headRow").data([dataInt]).enter();
  
          headGroupEnter.append("g")
              .attr("class", "headRow");
  
          headRow = gAll.select(".headRow")
              .attr("transform", "translate(0,0)");
  
          headEnter = headRow.selectAll("rect").data([dataInt]).enter();
  
          // Make background rect
          headEnter.append("rect")
  