4.0

4.0 | 1 rating Rate this file 61 downloads (last 30 days) File Size: 1.45 KB File ID: #25625

Quick routine to plot RGB overlay of three images

by Lennaert

 

21 Oct 2009

Code covered by BSD License  

plotRGB allows quick plotting of an overlay of three grayscale images

Download Now | Watch this File

File Information
Description

plotRGB allows quick plotting of an overlay of three grayscale images with possible custom scaling of the R, G and B intensity ranges
grayscale ranges are normalized for RGB plot

MATLAB release MATLAB 7.0.4 (R14SP2)
Zip File Content  
Other Files license.txt,
plotRGB.m
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (3)
21 Oct 2009 Jan Simon

A short help text exists, but is not very descriptive. No H1-line. Year and author are mentioned. The automatic parsing of the help is impeded by using %% as comment chars. The source has no comments.
min(min(X)) would be a faster as min(X(:)), same for max. Pre-allocation of tempim is not needed.
Summary: It works, the function is useful, some improvements would be good.

21 Oct 2009 us

...min(min(X)) would be a faster as min(X(:))...

not quite

% ic2/2*2.6ghz/2gb/winxp.sp3/r2009b
x=rand(1000);
tic;for i=1:1000;min(x(:));end;toc
% Elapsed time is 1.469955 seconds.
tic;for i=1:1000;min(min(x));end;toc
% Elapsed time is 1.491293 seconds.

for smaller xes, its even faster...
just a thought
us

22 Oct 2009 Jan Simon

On a multi-core machine MIN(MIN(X)) seems to be faster than MIN(X(:)). On a single core (Matlab 2009a), MIN(X(:)) is 16% faster with the example of <us>. Follow <us> to be prepared for the future. Thanks <us>.

Please login to add a comment or rating.
Tag Activity for this File
Tag Applied By Date/Time
image overlay Lennaert 21 Oct 2009 11:18:48
rgb Lennaert 21 Oct 2009 11:18:49
rgb normalize Lennaert 21 Oct 2009 11:18:49
rgb Nick Haddad 21 Oct 2009 13:35:53
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com