code: function flipHistogram(histo2d) {
    const newHisto2d = {
      bins: histo2d.bins.map((bin) => {
        const { x, y, count } = bin;
        return {
          x: y,
          y: x,
          count,
        };
      }),
      x: histo2d.y,
      y: histo2d.x,
      maxCount: histo2d.maxCount,
      numberOfBins: histo2d.numberOfBins,
    };
  
    return newHisto2d;
  }
docs: ---------------------------------------------------------------------------- Global ----------------------------------------------------------------------------