Date: Mar 4, 2011 10:46 AM
Author: Matt J
Subject: Re: anybody got a complex 2-D median filter script they can share?

"Matt J" wrote in message <ikr10v$2e3$>...
> > I am in a bit of a time crunch and am looking for a script to handle 2-D complex data with a median filter. long story short I've been doing the operation wrong and getting good results with bad math. any assistance is appreciated!
> ============
> median filtering relies on the ability to sort/order the input data. Since your data is complex valued, how would you define an ordering for it, on which to base calculations of the medians?


If you mean that you just want to median filter the real and imaginary part of the image separately, you could just do

X_filtered = medfilt2(real(X))+i*medfilt2(imag(X));