Median

In a list of values, the median is the ”middle” value. For example, if the list is 5, 10, 15, 20, 105; the median is 15. The average of the same list would have been 31. A median filter rejects any values which are substantially different from the others, and so rejects ”impulsive” noise like hot pixels or cosmic ray hits. When filtering Gaussian noise, however, taking the median value is about 25% worse at suppressing noise than taking an average.