I assume your 'h' key is broken ;) and you mean hetero/homogeneous?
Perhaps you could show us an image; otherwise I would just recommend a median filter.
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!