statsmodels.robust.norms.TrimmedMean#
- class statsmodels.robust.norms.TrimmedMean(c=2.0)[source]#
Trimmed mean function for M-estimation
- Parameters:
- c
float,optional The tuning constant for the trimmed mean function. It has to be positive. The default value is 2.0.
- c
Methods
__call__(z)Return the value of estimator rho applied to an input
- Raises:
TypeErrorIf c is not a real number.
ValueErrorIf c is not positive, or is nan.
See also
Notes
Changed in version 0.15.1: The tuning constant is validated. Zero, negative and nan values raise a
ValueErrorinstead of creating a degenerate norm.The tuning constant is validated when the norm is created and in
_set_tuning_param. Plain attribute assignment after construction,norm.c = value, is not validated.Methods
max_rho()psi(z)The psi function for least trimmed mean
psi_deriv(z)The derivative of least trimmed mean psi function
rho(z)The robust criterion function for least trimmed mean
weights(z)Least trimmed mean weighting function for the IRLS algorithm
Properties