1. 首页
  2. 数据库
  3. 其它
  4. python封装的异常值处理函数(包括箱线图去除异常值等)

python封装的异常值处理函数(包括箱线图去除异常值等)

上传者: 2020-12-31 04:24:41上传 PDF文件 51.91KB 热度 322次
# 这里我包装了一个异常值处理的代码,可以随便调用。 def outliers_proc(data, col_name, scale=3): """ 用于清洗异常值,默认用 box_plot(scale=3)进行清洗 :param data: 接收 pandas 数据格式 :param col_name: pandas 列名 :param scale: 尺度 :return: """ def box_plot_outliers(data_ser, box_scale): """ 利用箱线图去除异常值
下载地址
用户评论