<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">Since imshow is a pyplot function, the
first time it is called, it creates a figure object for you. Then
subsequent calls only draw to that already existing figure. So
you can create multiple figures by hand:<br>
<br>
for i in range(0,3):<br>
fig, ax = subplots(1,1)<br>
img = plt.imread('image-'+i+'.png')<br>
imshow(img)<br>
<br>
But since you're really just displaying images and not creating
plots, the ipython display(Image(...)) technique others have
suggested is probably better.<br>
Regards,<br>
Jon<br>
<br>
On 11/15/2012 07:20 AM, Darren Govoni wrote:<br>
</div>
<blockquote cite="mid:20121115132054.39566.qmail@ontrenet.com"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<p>Hi,</p>
<p> I am wanting to display multiple images in a loop and have
each one displyed in my notebook. For example:</p>
<p>for i in range(0,3):</p>
<p> img = plt.imread('image-'+i+'.png')</p>
<p> imshow(img)</p>
<p>But it only shows one image instead of 4.</p>
<p>How can I display multiple images from a cell?</p>
<p>thanks! </p>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
IPython-User mailing list
<a class="moz-txt-link-abbreviated" href="mailto:IPython-User@scipy.org">IPython-User@scipy.org</a>
<a class="moz-txt-link-freetext" href="http://mail.scipy.org/mailman/listinfo/ipython-user">http://mail.scipy.org/mailman/listinfo/ipython-user</a>
</pre>
</blockquote>
<br>
</body>
</html>