code: function getNearestDataPoint2(mouseY) {
              let adjustedMouseY = mouseY - margin.bottom,
                  epsilon = yScale.bandwidth(),
                  nearest = [];
  
              layers.map(function (data) {
                  let found = data.values.find((d2) => Math.abs(adjustedMouseY >= yScale(d2[nameLabel])) && Math.abs(adjustedMouseY - yScale(d2[nameLabel]) <= epsilon * 2));
  
                  if (found) {
                      found.values = data.values;
                      found.key = found.name;
                      nearest.push(found)
                  }
              });
  
              return nearest.length ? nearest[0] : undefined;
          }
docs: Finds out the data entry that is closer to the given position on pixels
  @param  {Number} mouseX X position of the mouse
  @return {obj}        Data entry that is closer to that x axis position