excel-basic-statistics-and-routing
对多Sheet Excel文件进行基础统计与,支持按条件筛选计算均值,以及从指定行区间提取数据去重求和,并生成结果文件与下载链接。
npx skills add OpenSenseNova/SenseNova-Skills --skill basic-statistics --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
## Skill Steps > This sub-skill covers one capability of the Excel workflow. For reading/counting/Parquet optimization, see the parent workflow SKILL.md. Step1 筛选指定分组数据,将目标列转换为数值类型并计算平均值。 ```python group_col = '班级' # 占位示例 target_group_value = '358' # 占位示例 target_cols = ['总分', '理数'] # 占位示例 if group_col not in df_analysis.columns: raise ValueError(f"数据中缺少'{group_col}'列。") df_analysis[group_col] = df_analysis[group_col].astype(str) filtered_df = df_analysis[df_analysis[group_col] == target_group_value] avg_scores = {} for col in target_cols: if col not in filtered_df.columns: raise ValueError(f"数据中缺少'{col}'列。") try: filtered_df[col] = pd.to_numeric(filtered_df[col], errors='raise') avg_scores[f'平均{col}'] = filtered_df[col].mean() except Exception as e: raise ValueError(f"列'{col}'无法转换为数值类型: {str(e)}") output("筛选结果统计: " + str(avg_scores)) ``` Step2 对于小文件,从特定 Sheet 的指定行区间提取目标字段,去重后计算总和。 ```python unique_components = {} total_power = 0 if total_rows < 10000: target_sheet = 'Sheet2' # 占位示例 df_sheet2 = pd.read_excel(file_path, sheet_name=target_sheet) extracted_data = [] # 提取区间1 (例如 21-28行) for i in range(21, 29): if i < len(df_sheet2): row = df_sheet2.iloc[i] component = row.iloc[0] power
- Skill Steps
What does the excel-basic-statistics-and-routing skill do?
对多Sheet Excel文件进行基础统计与,支持按条件筛选计算均值,以及从指定行区间提取数据去重求和,并生成结果文件与下载链接。
How do I install it?
Run `npx skills add OpenSenseNova/SenseNova-Skills --skill basic-statistics --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From OpenSenseNova/SenseNova-Skills, a repository with 4,855 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
