added wega:computeMedian() and added the appropriate handling for tables