How Stuff Works
What We Did
 
   

 

Standard Deviation (STD) Outlier Control

One problem we were asked to address was an issue of unexplained outlying data measurements disrupting the constant temperature of the ADR. The temperature reading would irregularly return an unreasonably high measurement—physically impossible for the system to achieve in such a short amount of time. This measurement would be interpreted as true in the control algorithm and cause an extreme fluctuation in temperature stability, all for an imaginary outlying point (right).

To solve the problem we coded a function that detects and disregards outliers. It computes the difference between the current point and the point before it. If that difference is more than five times the standard deviation of the last n data points (the default is 75 points--about 15 seconds of data), then it classifies the point as an outlier and replaces it with the average of the last three points (the three measured prior to the two used to calculate the difference). This new point is sent to the smoothing algorithm for PID control. Thus if an outlier appears, it is replaced with a reasonable temperature value and the system fluctuation is avoided. By request, we also included a feature in the graphical user interface to turn outlying detection on or off in real-time.