A mature A/B testing analysis library for MoonBit, supporting sample size estimation, sequential testing, metrics comparison and guardrails.
moon add pla678889/moon-experiment@0.2.2import {
"pla678889/moon-experiment"
}let result = @metrics.proportion_test(120, 1000, 150, 1000)
let interval = @metrics.wilson_interval(120, 1000)
println(result.p_value.to_string())
println(interval.low().to_string())moon run examples/quickstart --target nativemoon run cmd/benchmark --target native| 包 | 职责 |
|---|---|
| core | 描述统计、在线统计量、分布函数、概率校验和随机数工具 |
| size | 样本量、功效、分配和敏感性分析 |
| metrics | 检验、效应量、置信区间、回归、重采样和多重校正 |
| guardrail | SRM、缺失、异常、漂移、比例和护栏策略 |
| sequential | alpha spending、mixture SPRT、e-process 和置信序列 |
| stratified | 分层均值、方差、分配和 Mantel–Haenszel 估计 |
| dataset | 观测模型、验证、清洗、确定性分配和变换 |
| experiment | 实验启动、摄入、暂停、完成、决策和流程编排 |
| monitor | 滚动统计、EWMA、CUSUM、趋势预测、告警和质量评分 |
| simulation | 二项、连续、计数数据生成与经验功效/错误率 |
| report | 结构化实验报告、Markdown/CSV 渲染和质量摘要 |
| benchmark | workload、checksum、基线比较和汇总 |
| causal | 倾向得分、IPW/AIPW、双重差分、协变量平衡和敏感性分析 |
| funnel | 事件去重、会话化、漏斗转化、留存、路径和收入分析 |
| timeseries | 滚动统计、预测、季节性分解、变点检测、控制图和回测 |
| privacy | 隐私预算、噪声机制、随机响应、贡献裁剪和小样本抑制 |
| decision | 指标/护栏门禁、风险评分、放量阶段、回滚和审计输出 |
| catalog | 指标定义、目录注册、分组/周期聚合、快照比较和健康检查 |
| pipeline | 指标清洗、去重、插补、窗口聚合、质量评分和导出 |
| attribution | 首末触点、线性、时间衰减、位置模型和增量归因 |
| quality | 完整性、有效性、唯一性、范围、漂移、异常和数据剖析 |
| orchestration | 将指标、管线、质量和放量决策编排为一次分析运行 |
| experimentops | 实验计划、确定性分流、曝光监测、注册、诊断和审计 |
moon check --deny-warn --target all
moon test --deny-warn --target all
moon coverage analyze -- -f summaryA mature A/B testing analysis library for MoonBit, supporting sample size estimation, sequential testing, metrics comparison and guardrails.