Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
How to find min/max in a figure/colorbar?

Subject: How to find min/max in a figure/colorbar?

From: Anke

Date: 12 Mar, 2013 14:06:06

Message: 1 of 2

I saved figures of some plots during a simulation run. They are imagesc. Is there any way to fin the min/max values just from the figure? Or actually the colorbar.
I use the image without axes in a .tex document where I use pgfplots to redo the axes and colorbar. So basically I need to know how to accurately remake the colorbar not just by guessing. The ticks on my Matlab colorbar don't go all the way up and down, so right now, guessing is my only option...

Subject: How to find min/max in a figure/colorbar?

From: Kristin

Date: 19 Mar, 2013 23:11:10

Message: 2 of 2

"Anke " <anke.wortmann@student.kit.edu> wrote in message <khncoe$lq$1@newscl01ah.mathworks.com>...
> I saved figures of some plots during a simulation run. They are imagesc. Is there any way to fin the min/max values just from the figure? Or actually the colorbar.
> I use the image without axes in a .tex document where I use pgfplots to redo the axes and colorbar. So basically I need to know how to accurately remake the colorbar not just by guessing. The ticks on my Matlab colorbar don't go all the way up and down, so right now, guessing is my only option...

CAX = caxis;

This will return a two-element vector of the min and max value, per the colorbar.

Tags for this Thread

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.

Contact us