# Missing Value Remover

> Missing Value Remover is an Agent Skill for documents published in the cas-bigdatalab/piflow repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

缺失值删除工具。读取结构化表格或 JSONL 数据，删除包含缺失值的行或删除缺失比例过高的列；不负责缺失值填充。 当用户提到删除缺失值、删除空值行、删除空值列等需求时使用此skill。 适用于科研表格和结构化数据的缺失清理，不负责插值、补值、均值填充或其他修复操作。

- Skill name: `missing_value_remover`
- Category: [Documents](https://www.openparable.com/skill/documents/1)
- Source: https://github.com/cas-bigdatalab/piflow/blob/HEAD/workspace/skills/missing_value_remover/SKILL.md
- Repository: cas-bigdatalab/piflow (541 GitHub stars when collected)

## SKILL.md

# Missing Value Remover 缺失值删除 Skill

## 功能概述

本skill用于删除数据中包含缺失值的行或列：
- **drop**：删除包含任何缺失值的行
- **drop_cols**：删除缺失比例超过阈值的列

## 输入文件格式

支持以下结构化文件格式：
- CSV
- TSV
- Excel（.xlsx / .xls）
- JSON
- JSONL

不支持的文件格式会直接报错拒绝，不会自动猜测格式；如需处理其他格式，请先转换为以上支持格式后再使用本skill。

## 使用方法

### 删除含缺失值的行
```bash
python scripts/run_missing_value_remover.py \
  --input data.csv \
  --output cleaned.csv \
  --strategy drop
```

### 删除缺失严重的列
```bash
python scripts/run_missing_value_remover.py \
  --input data.csv \
  --output cleaned.csv \
  --strategy drop_cols \
  --threshold 0.5
```

## 参数说明

| 参数 | 必填 | 说明 |
|------|------|------|
| `--input` | 是 | 输入文件路径 |
| `--output` | 是 | 输出文件路径 |
| `--columns` | 否 | 处理字段，逗号分隔 |
| `--strategy` | 否 | 删除策略，默认"drop" |
| `--threshold` | 否 | 删除阈值，默认0.5 |

## 环境要求

```bash
pip install pandas numpy openpyxl
```

---

Source: https://www.openparable.com/skill/documents/missing-value-remover (OpenParable). Cite the canonical URL above.
