idlastro / Robust Statistics procedures: ROB_CHECKFIT

[Source code]

NAME
ROB_CHECKFIT
PURPOSE
Used by ROBUST_... routines to determine the quality of a fit and to
return biweights.
CALLING SEQUENCE
status = ROB_CHECKFIT( Y, YFIT, EPS, DEL, SIG, FRACDEV, NGOOD, W, B
                        BISQUARE_LIMIT = )
INPUT
Y     = the data
YFIT  = the fit to the data
EPS   = the "too small" limit
DEL   = the "close enough" for the fractional median abs. deviations
RETURNS
Integer status. if =1, the fit is considered to have converged
OUTPUTS
SIG   = robust standard deviation analog
FRACDEV = the fractional median absolute deviation of the residuals
NGOOD   = the number of input point given non-zero weight in the 
        calculation
W     = the bisquare weights of Y
B     = residuals scaled by sigma
OPTIONAL INPUT KEYWORD
BISQUARE_LIMIT = allows changing the bisquare weight limit from 
                default 6.0
PROCEDURES USED
ROBUST_SIGMA()
REVISION HISTORY
Written, H.T. Freudenreich, HSTX, 1/94