We propose a procedure for stack filter design that takes into consideratio
n the filter's sample selection probabilities. A statistical optimization o
f stack filters can result in a class of stack filters, all of which are st
atistically equivalent. Such a situation arises in cases of nonsymmetric no
ise distributions or in the presence of constraints. Among the set of equiv
alent stack filters, our method constructs a statistically optimal stack fi
lter whose sample selection probabilities are concentrated in the center of
its window. This leads to improvement of detail preservation.