#[non_exhaustive]pub struct SpmChart {
pub fpca: FpcaResult,
pub eigenvalues: Vec<f64>,
pub t2_phase1: Vec<f64>,
pub spe_phase1: Vec<f64>,
pub t2_limit: ControlLimit,
pub spe_limit: ControlLimit,
pub config: SpmConfig,
pub sample_size_adequate: bool,
}Expand description
Univariate SPM chart from Phase I.
The chart assumes approximate multivariate normality in the score space.
For non-Gaussian functional data, the chi-squared control limits are
approximate. Use t2_limit_robust() with bootstrap method for
distribution-free limits.
For finite calibration samples, the exact Hotelling T^2 distribution is
(n_cal * ncomp / (n_cal - ncomp)) * F(ncomp, n_cal - ncomp). The
chi-squared limit chi2(ncomp) is asymptotically exact as n_cal -> inf,
but can be anti-conservative for small calibration sets (n_cal < 10 *
ncomp). When the calibration set is small, prefer bootstrap-based limits.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.fpca: FpcaResultFPCA result from the tuning set.
eigenvalues: Vec<f64>Eigenvalues lambda_l = s_l^2 / (n_tune - 1), where s_l are singular values from the SVD of the centered data matrix X = U Sigma V^T. This gives the sample covariance eigenvalues since Cov = X^T X / (n-1) has eigenvalues s_l^2 / (n-1).
The actual number of components may be fewer than config.ncomp if
limited by sample size or grid resolution.
t2_phase1: Vec<f64>T-squared values for the calibration set.
spe_phase1: Vec<f64>SPE values for the calibration set.
t2_limit: ControlLimitT-squared control limit.
spe_limit: ControlLimitSPE control limit.
config: SpmConfigConfiguration used to build the chart.
sample_size_adequate: boolWhether the sample size meets the recommended minimum (10 × ncomp). False indicates results may be unstable.
Trait Implementations§
impl StructuralPartialEq for SpmChart
Auto Trait Implementations§
impl Freeze for SpmChart
impl RefUnwindSafe for SpmChart
impl Send for SpmChart
impl Sync for SpmChart
impl Unpin for SpmChart
impl UnsafeUnpin for SpmChart
impl UnwindSafe for SpmChart
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.