• Returns the numberMaxPoints points with the bigger y.

    Parameters

    • data: DataXY<NumberArray>

      Object that contains property x (an ordered increasing array) and y (an array)

    • numberMaxPoints: number

      Number of points to keep

    Returns DataXY

    • The points filtered to keep the numberMaxPoints most intense points of the input.