Thread Subject: colormap

Subject: colormap

From: Judy

Date: 22 Oct, 2009 00:27:01

Message: 1 of 4

Does anyone know why this command pops up an empty new figure?

C=colormap(jet(128));

I want to turn this useless pop up off but I don't know how!
I'm working with MATLAB R14 SP1 btw.

Any ideas are much appreciated. Thanks!

Subject: colormap

From: Steven Lord

Date: 22 Oct, 2009 02:54:10

Message: 2 of 4


"Judy " <sauwen.jl@gmail.com> wrote in message
news:hbo8sk$3ok$1@fred.mathworks.com...
> Does anyone know why this command pops up an empty new figure?
>
> C=colormap(jet(128));

Because that's what it's _supposed_ to do!

http://www.mathworks.com/access/helpdesk/help/techdoc/ref/colormap.html

In order to set the current colormap, there has to be a current figure with
a colormap to set; if there isn't one, one will be created for you.

> I want to turn this useless pop up off but I don't know how!

Simple -- don't call COLORMAP.

Perhaps if you explain what you expected or wanted this command to do,
someone can explain how to do what you want.

--
Steve Lord
slord@mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ

Subject: colormap

From: ImageAnalyst

Date: 22 Oct, 2009 02:54:21

Message: 3 of 4

On Oct 21, 8:27 pm, "Judy " <sauwen...@gmail.com> wrote:
> Does anyone know why this command pops up an empty new figure?  
>
> C=colormap(jet(128));
>
> I want to turn this useless pop up off but I don't know how!
> I'm working with MATLAB R14 SP1 btw.
>
> Any ideas are much appreciated.  Thanks!

----------------------------------------------------------------------
Because you have no active figure showing yet. Consider the
following:
monochromeImage = imread('cell.tif');
imshow(monochromeImage);
C=colormap(jet(128));
No empty figure shows up. But if I didn't have the first two lines in
there, then there would be an empty figure created. If you don't want
that, then don't call colormap.

Let me ask you: why are you calling colormap if you have no figure
showing that you can apply it to?

Subject: colormap

From: Carlos Adrian Vargas Aguilera

Date: 22 Oct, 2009 14:40:24

Message: 4 of 4

try
C = jet(128);

Carlos

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
colormap Judy 21 Oct, 2009 20:29:04
rssFeed for this Thread

Contact us at files@mathworks.com