Pa

Struct Pa 

Source
pub struct Pa {
Show 30 fields pub data_whole: Vec<f64>, pub total: f64, pub center_value: f64, pub usl: f64, pub lsl: f64, pub std_dev_zt: f64, pub std_dev_zn: f64, pub std_dev_zn_data: Vec<f64>, pub average_zn: f64, pub average_zt: f64, pub pp: f64, pub ppl: f64, pub ppu: f64, pub ppk: f64, pub cpk: f64, pub cp: f64, pub cpu: f64, pub cpl: f64, pub ppm: f64, pub defects: f64, pub offset_center: f64, pub ca: f64, pub scv: f64, pub max_value: f64, pub min_value: f64, pub avg_r: Vec<f64>, pub group_count: usize, pub average_zn_data: Vec<f64>, pub range_zn_data: Vec<f64>, pub range_zn: f64, /* private fields */
}
Expand description

加工分析

Fields§

§data_whole: Vec<f64>

整体数据

§total: f64

总体数量

§center_value: f64§usl: f64

规格上限

§lsl: f64

规格下限

§std_dev_zt: f64

标准差 整体

§std_dev_zn: f64

标准差 组内

§std_dev_zn_data: Vec<f64>

样本标准差 组内 列表

§average_zn: f64

组内 均值

§average_zt: f64

整体 均值

§pp: f64

过程性能指数

§ppl: f64§ppu: f64§ppk: f64§cpk: f64

精密度 CPK

§cp: f64

精确度 cp

§cpu: f64

精确度 cpu 上限要求

§cpl: f64

精确度 cpl 下限要求

§ppm: f64

ppm

§defects: f64

缺陷数量

§offset_center: f64

中心偏移

§ca: f64

精确度 Ca

§scv: f64

规格中心值

§max_value: f64

最大值

§min_value: f64

最小值

§avg_r: Vec<f64>

样本极差值

§group_count: usize

分组数

§average_zn_data: Vec<f64>

分组后的平均值

§range_zn_data: Vec<f64>

组内极差数据

§range_zn: f64

组内极差值

Implementations§

Source§

impl Pa

Source

pub fn new( data: Vec<f64>, usl: f64, lsl: f64, group_count: usize, types: bool, ) -> Pa

初始化

  • types true 计量型 false 计数型
  • group_count 分组数量
Source

pub fn ca(&mut self)

精确度 Ca

Source

pub fn cpk(&mut self)

精密度 cpk true 第一种方法考虑了规范上限和下限与平均值之间的差异,分别计算了规范上限和下限的 CPK 值,并选择了较小的值作为最终的 CPK 值。这种方法更适用于当规范上限和下限的差异较大时,或者当你更关注上限和下限之间的不对称性时 false 第二种方法直接计算了规范上限和下限之间的距离,并以此作为 CPK 的分子。这种方法更适用于当你关注的是整个过程的总体能力时,而不考虑上限和下限之间的差异。

Source

pub fn cpk_desc(&mut self) -> (&'static str, &'static str)

cpk 的结果

Source

pub fn ppm(&mut self)

PPM (Parts Per Million,百万分之一)是一种用于表示某个物质或事件在总体中的比例或浓度的单位。在质量管理中,PPM 通常用于表示产品的缺陷率或质量水平。

Source

pub fn cp(&mut self)

Source

pub fn cp_desc( &mut self, ) -> ((f64, &str, &str), (f64, &str, &str), (f64, &str, &str))

Source

pub fn normal_distribution_plot(&mut self) -> Vec<Vec<f64>>

正态分布图

Source

pub fn xbar_r(&mut self) -> JsonValue

计算R(范围)

Source

pub fn xbar_s(&mut self) -> JsonValue

计算R(范围)

Source

pub fn xbar(&mut self) -> (f64, f64, f64)

计算R(范围)

Source

pub fn i_mr(&mut self) -> JsonValue

I-MR 控制图 I-MR 控制图是一种统计质量控制方法,用于监控过程中连续变量的稳定性和一致性。I 代表 Individual,表示个体值,MR 代表 Moving Range,表示移动范围。

Source

pub fn u(&mut self) -> (f64, Vec<f64>)

U 控制图 不合格品数量的平均值

Source

pub fn p(&mut self) -> (f64, Vec<f64>)

P 控制图 不合格品比例的平均值

Source

pub fn np(&mut self) -> (f64, f64, Vec<f64>)

NP 控制图 不合格品比例的平均值

Source

pub fn histogram(&mut self) -> JsonValue

直方图

Source

pub fn normal_distribution(&mut self) -> JsonValue

正态分布

Trait Implementations§

Source§

impl Clone for Pa

Source§

fn clone(&self) -> Pa

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Pa

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl Freeze for Pa

§

impl RefUnwindSafe for Pa

§

impl Send for Pa

§

impl Sync for Pa

§

impl Unpin for Pa

§

impl UnwindSafe for Pa

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.