Skip to content
Snippets Groups Projects
Commit 0419ea9f authored by Taddeüs Kroes's avatar Taddeüs Kroes
Browse files

ImProc ass1: Replaced separate figures with subplots.

parent dc7c99bb
No related branches found
No related tags found
No related merge requests found
from pylab import clf, histogram, imshow, imread, bar, diff, xlim, show, \
figure, amin, amax
subplot, amin, amax
i = 1
def show_hist(a):
global i
figure(i)
subplot(2, 2, i)
imshow(a, vmin=0, vmax=1)
h, be = histogram(a.flatten(), bins=40)
figure(i + 1)
subplot(2, 2, i + 1)
bar(be[:-1], h, width=diff(be)[0])
xlim((0, 1))
i += 2
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment