math_statistics
Perform statistical calculations including descriptive statistics, correlation, linear regression, and probability distributions from data or distribution parameters.
Instructions
统计与概率计算。
data: 数据集或分布描述。 数据集格式: '[1,2,3,4,5]' 或 '1,2,3,4,5'。 配对数据(回归/相关): '[[1,2],[3,4],[5,6]]' 或 '[1,2;3,4;5,6]'。 operation: describe — 描述性统计(均值、中位数、标准差、极值等) mean / median — 均值 / 中位数 std / variance — 标准差 / 方差 min / max / range — 最小值 / 最大值 / 极差 skewness / kurtosis — 偏度 / 峰度 quantile — 分位数(需 quantile 参数,如 0.25) correlation — Pearson 相关系数(需配对数据) linear_regression — 简单线性回归 y=ax+b(需配对数据) distribution: 概率分布查询,格式 '分布名,参数1=值,参数2=值,x=点'。 支持的分布: normal, exponential, binomial, poisson, uniform, gamma, beta, chi2, t, F。 示例: 'normal,mu=0,sigma=1,x=1.96' 操作: pdf, cdf, quantile, mean, variance, sample(需 n=数量)。
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | ||
| operation | No | describe |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |