Given a 3×3 table with values in the range from 0 to 255. First, the difference between each boundary cell and the center cell is calculated to result in a data set of 8 elements. After that, the threshold value is obtained by using the arithmetic mean to the 8 elements. This threshold is applied on the differences to produce binary stream. Is there a statistical measure that would be better than the mean to calculate the threshold and give a better description to the texture of the original data?