code: def percentiles(self, percentiles):
      
      try:
        scores = [0.0]*len(percentiles)
  
        if self.count > 0:
          values = self.samples()
          values.sort()
  
          for i in range(len(percentiles)):
            p = percentiles[i]
            pos = p * (len(values) + 1)
            if pos < 1:
              scores[i] = values[0]
            elif pos > len(values):
              scores[i] = values[-1]
            else:
              upper, lower = values[int(pos - 1)], values[int(pos)]
              scores[i] = lower + (pos - floor(pos)) * (upper - lower)
  
        return scores
      except IndexError:
        return [float('NaN')] * len(percentiles)
docs: Given a list of percentiles (floats between 0 and 1), return a
      list of the values at those percentiles, interpolating if
      necessary.