clear all
close all
n_filt = 5;
n_lim = 500;
a = peaks(n_lim);
a = a(1:n_lim, 1:floor(0.8*n_lim));

a_median = find_median_neighbours(a, n_filt);

figure;
flat_pcolor(a)
colorbar
title('a')

figure;
flat_pcolor(a_median)
colorbar
title('a_median')

figure;
flat_pcolor(a - a_median)
colorbar
title('a - a_median')
