#[non_exhaustive]pub struct Fosr2dResult {
pub intercept: Vec<f64>,
pub beta: FdMatrix,
pub fitted: FdMatrix,
pub residuals: FdMatrix,
pub r_squared_pointwise: Vec<f64>,
pub r_squared: f64,
pub beta_se: Option<FdMatrix>,
pub lambda_s: f64,
pub lambda_t: f64,
pub gcv: f64,
pub grid: Grid2d,
}Expand description
Result of 2D function-on-scalar regression.
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.intercept: Vec<f64>Intercept surface beta_0(s,t), flattened column-major (length m1*m2).
beta: FdMatrixCoefficient surfaces beta_j(s,t), p x (m1*m2) matrix (row j = flattened beta_j).
fitted: FdMatrixFitted surface values, n x (m1*m2) matrix.
residuals: FdMatrixResidual surfaces, n x (m1*m2) matrix.
r_squared_pointwise: Vec<f64>Pointwise R^2(s,t), flattened (length m1*m2).
r_squared: f64Global R^2 (average of pointwise).
beta_se: Option<FdMatrix>Standard error surfaces for each beta_j (p x (m1*m2)), or None if the system is underdetermined.
lambda_s: f64Smoothing parameter in the s-direction.
lambda_t: f64Smoothing parameter in the t-direction.
gcv: f64Generalised cross-validation score.
grid: Grid2dGrid specification.
Implementations§
Source§impl Fosr2dResult
impl Fosr2dResult
Sourcepub fn beta_surface(&self, j: usize) -> FdMatrix
pub fn beta_surface(&self, j: usize) -> FdMatrix
Reshape the j-th coefficient surface into an m1 x m2 matrix.
§Panics
Panics if j >= p (number of predictors).
Sourcepub fn r_squared_surface(&self) -> FdMatrix
pub fn r_squared_surface(&self) -> FdMatrix
Reshape pointwise R^2(s,t) into an m1 x m2 matrix.
Sourcepub fn residual_surface(&self, i: usize) -> FdMatrix
pub fn residual_surface(&self, i: usize) -> FdMatrix
Reshape the residual for observation i into an m1 x m2 matrix.
§Panics
Panics if i >= n (number of observations).
Trait Implementations§
Source§impl Clone for Fosr2dResult
impl Clone for Fosr2dResult
Source§fn clone(&self) -> Fosr2dResult
fn clone(&self) -> Fosr2dResult
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Fosr2dResult
impl Debug for Fosr2dResult
Source§impl PartialEq for Fosr2dResult
impl PartialEq for Fosr2dResult
impl StructuralPartialEq for Fosr2dResult
Auto Trait Implementations§
impl Freeze for Fosr2dResult
impl RefUnwindSafe for Fosr2dResult
impl Send for Fosr2dResult
impl Sync for Fosr2dResult
impl Unpin for Fosr2dResult
impl UnsafeUnpin for Fosr2dResult
impl UnwindSafe for Fosr2dResult
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
impl<T> Scalar 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.