源码
https://github.com/carlosqsilva/pyspc
https://github.com/carlosqsilva/ccharts-online
使用
demo地址:
https://carlosqsilva.github.io/ccharts-online/
from pyspc import *
a = spc(pistonrings) + ewma()
print(a)
添加高亮规则
a + rules()
添加更多控制图
a + cusum() + xbar_sbar() + sbar()
包含有18个示例数据库,支持的自定义数据结构有nested lists (嵌套列表), numpy array (numpy数组 )或 pandas DataFrame(pandas 数据帧).
import numpy
from pyspc import *
fake_data = numpy.random.randn(30, 5) + 100
a = spc(fake_data) + xbar_rbar() + rbar() + rules()
print(a)
也可使用GUID,而非编码。(作为独立SPC分析工具可使用GUI,如果集成到应用程序等可使用代码)
$ python3 pyspc_gui.py
功能特点
变量
- Mean and Amplitude
- Mean and Standard Deviation
- Individual Values and Moving Range 移动均值
- Individual values with subgroups 子组
- Exponentially Weighted Moving Average (EWMA)
- Cumulative Sum (CUSUM)
特性
- P Chart
- NP Chart
- C Chart
- U Chart
多变量
- T Square Hotelling
- T Square Hotelling with SubGroup
- Multivariate Exponentially Weighted Moving Average (MEWMA)
安装
$ pip install pyspc