Rank: 165 based on 501 downloads (last 30 days) and 5 files submitted
photo

John Iversen

E-mail

Personal Profile:

 

Watch this Author's files

 

Files Posted by John Iversen View all
Updated   File Tags Downloads
(last 30 days)
Comments Rating
14 Sep 2010 Screenshot freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen annotation, customization, colormap, image, imagesc, index 445 130
  • 4.66019
4.7 | 110 ratings
20 Jul 2009 Screenshot FFTmtX Performs vectorized FFT on multiple processors. New: single and double precision. Author: John Iversen 13 2
05 Sep 2006 Screenshot Enhanced help--improve your workflow Simple enhancement to help listings: adds hyperlinks to open files for editing. Author: John Iversen development environme..., help, edit, hyperlink 10 4
  • 4.0
4.0 | 2 ratings
31 Aug 2006 Screenshot JISUBPLOT + NEXTPLOT: enhanced replacement for subplot Automatically create complex subplot layouts Author: John Iversen annotation, customization, subplot, figure, axis, layout 20 0
22 Jul 2005 Use Mac OS X XML Plists with MATLAB Utilities to convert Mac OS X native storage format (XML Property Lists) for use in MATLAB. Author: John Iversen data import, data export, xml, macintosh, parse, convert 13 1
  • 4.66667
4.7 | 3 ratings
Comments and Ratings by John Iversen View all
Updated File Comments Rating
31 Oct 2012 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen

Hello from the author.

I'm sorry people are having trouble with newer versions of Matlab. They keep changing things under the hood, in the name of progress.

I'm willing to help try to fix things, but it'll only work if you the users send more _details_. For starters:
What exactly doesn't work?
What is the error (if there is one)?
What do you expect vs. what do you see?
Important: Please send me simple demo code that demonstrates your problem. Simplify your code to the minimum that still shows the problem. This is invaluable.

It seems like a number of problems are focussed around the mapping toolbox. Please verify if you see the same problems if you instead use the standard graphics functions? That is, replace contourm and scatterm with contour and scatter, for example.

I would like to keep freezeColors working for everyone, but can only do so with your help.

You can send me these things off list at iversen AT nsi.edu.

Thanks,
John

31 Oct 2012 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen

Hello from the author.

I'm sorry people are having trouble with newer versions of Matlab. They keep changing things under the hood, in the name of progress.

I'm willing to help try to fix things, but it'll only work if you the users send more _details_. For starters:
What exactly doesn't work?
What is the error (if there is one)?
What do you expect vs. what do you see?
Important: Please send me simple demo code that demonstrates your problem. Simplify your code to the minimum that still shows the problem. This is invaluable.

It seems like a number of problems are focussed around the mapping toolbox. Please verify if you see the same problems if you instead use the standard graphics functions? That is, replace contourm and scatterm with contour and scatter, for example.

I would like to keep freezeColors working for everyone, but can only do so with your help.

You can send me these things off list at iversen AT nsi.edu.

Thanks,
John

05 Jan 2012 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen

== from the Author ==

Hi everyone. Happy New Year!

I wanted to belatedly comment on the problem people are having with eps/pdf exports ending up with pixellated text and lines. It's a bummer. Unfortunately, I believe this is an underlying feature of Matlab. Matlab has three methods for rendering plots, and this has an effect on printing to files, too. See "Impact of Rendering Method on the Output" at http://www.mathworks.com/help/techdoc/creating_plots/f3-103236.html#f3-103452

In short, even if you print to a vector format like 'eps' or 'pdf' matlab will save _bitmaps_! The only exception is when using render mode 'painters'. If you open these resulting eps/pdf in a vector program like Illustrator you'll see the file is in fact a bunch of bitmap 'strips'. It would be so much better if Matlab saved the image parts of your figure as bitmaps but kept the lines and text as crisp vectors. Please contact Mathworks to complain/suggest this.

=Workarounds=

First, try

>> set(gcf,'renderer','painters')

on your plots and see if you like the result. If so, you're golden: With the 'painters' renderer will you get what you want--a vector format output with text (and presumably lines--I haven't verified this) as vector objects. However, you will lose many effects like transparency, lighting, etc, and some more advanced plots you will see an error as they cannot be rendered in this mode.

Otherwise, the workaround is to specify a _resolution_ when you print to eps or pdf:

>> print(gcf,'-depsc','-r600','file.eps')

It'll still just output a bitmap, but at least the text and contours will be rendered smoothly (at 600 ppi in this case. Use a higher number for even smoother results). The default is in fact '-r72' which is why you have been getting pixellated text and lines.

In this case, there's really no point in printing to eps or pdf, so you might as well use 'tiff' or another true bitmap format:

>> print(gcf,'-dtiff','-r600','file.tiff')

I tested this out on Koos Spee's nice example, and using R2010a. Hopefully this generalizes and helps people out. Let me know if so/not. Thanks, John

PS. Thank you for bug fixes (Mircea & Subhaneil). I'll upload a new version eventually...

19 Nov 2010 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen

Thank you for the answer, Irene. Did it work?

Eef, this is not something I can reproduce. freezeColors doesn't touch the labels, so it is a side effect of some sort. It could be a matlab bug due to change in the figure's renderer--I see similar problems when converting (set(gcf,'renender',...) between rendering modes. If you can narrow it down to the specific line in freezeColors that causes the change, it could give you a clue on what to ask mathworks about.

Matthias: The example you give works fine here. What is the error you're seeing? If you're having a problem with cbfreeze, you'll have to ask its author for help.

Thanks.

14 Sep 2010 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen

Hello, I have uploaded a new version of freezeColors.

Changes: The main change is in documentation, finalizing the suggestion to use cbfreeze to freeze colorbars. There is also a fix to a problem in which caxis was changed in contourf plots.

I would enjoy hear about the kind of work users of this function are doing, and see examples of its use. (my email address is contained in the functions).

Thank you, John Iversen

Comments and Ratings on John Iversen's Files View all
Updated File Comment by Comments Rating
03 Dec 2014 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen Kinfoon Wong

07 Nov 2014 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen TAY

the program crash when i try to use th cbfreeze(h,'off'), anyone encounter this problem? This function is very useful, thank you author!!

13 Oct 2014 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen Matt Eicholtz

25 Sep 2014 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen David

Does not work for me when using scatter in 2014a; erases the points on the plot when I call it.

17 Sep 2014 freezeColors / unfreezeColors Use multiple colormaps per figure! Version 2, now works for many types of objects, not only images. Author: John Iversen Simon Henin

Worked like a charm. Thanks!

Contact us