generate native MATLAB code from finished figures, for study

There are many small irritations in MATLAB, such as the lack of native LaTeX support for tick labels on the axes in a figure and (at least on the current Mac OS X installation, v. R2011b) failure to support all the native Mac services, such as the “don’t save” key-binding when closing a window or normal filesystem windowing when print-to-file is selected. I do not see a way to save color figures to .ps files, either.

But here is one helpful thing. For study of MATLAB’s syntax on a level a little deeper than what is supplied in the various guides, after finishing a figure, use the menu item File -> Generate Code… to see how MATLAB really describes the figure you have produced. It is instructive to be able to see various efficiencies an inefficiencies introduced, as well as an explicit statement of some of the defaults you have unknowingly used.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s