empirical cumulative distribution function(ECDF) 经验累积分布函数

def ecdf(data):
    """Compute ECDF for a one-dimensional array of measurements."""

    # Number of data points: n   
    n = len(data)

    # x-data for the ECDF: x
    x = np.sort(data)

    # y-data for the ECDF: y
    y = np.arange(1, n+1) / n

    #return x, y
    return x, y    

 







相关文章:

  • 2022-12-23
  • 2021-08-01
  • 2022-12-23
  • 2021-07-23
  • 2021-05-28
  • 2021-11-17
  • 2022-12-23
  • 2021-07-25
猜你喜欢
  • 2021-05-10
  • 2021-12-31
  • 2022-12-23
  • 2021-10-19
  • 2022-01-23
  • 2021-06-09
相关资源
相似解决方案