work on automatic outlier rejection