Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: imwrite
Date: Mon, 9 Mar 2009 19:53:01 +0000 (UTC)
Organization: Atlantic Inertial Systems
Lines: 12
Message-ID: <gp3s2t$i78$1@fred.mathworks.com>
References: <gp3jdf$1sn$1@fred.mathworks.com> <muy63iili8f.fsf@G99-Boettcher.llan.ll.mit.edu> <gp3o75$rr7$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1236628381 18664 172.30.248.37 (9 Mar 2009 19:53:01 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Mon, 9 Mar 2009 19:53:01 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1405925
Xref: news.mathworks.com comp.soft-sys.matlab:523580


"Oluwa KuIse" <wespeakforex@yahoo.com> wrote in message <gp3o75$rr7$1@fred.mathworks.com>...

> Question: Image() displays the image in a MATLAB figure window. I want to be able to display this image in say, .jpeg. 
> Thank you!

You probably need to scale your data.  imwrite() clips everything outside the range [0, 1]

% compare these two 
imwrite(magic(100), 'test.jpg')
imwrite(magic(100)/100^2, 'test2.jpg')

~Adam