tags:

views:

4399

answers:

5

Some things that I personally find as shortcomings in the MATLAB Editor:

  • virtually no code completion available
  • does not run OS native (on MacOS) - but in X-Environment (shortcuts, copy&paste problems, keymappings, non intuitive window-managing)
  • virtually no refactoring tools

Are there alternative editors with these features?

+1  A: 

I use emacs for MATLAB stuff, but then I use it for just about everything.

There's a MATLAB mode for emacs at http://www.andrew.cmu.edu/course/16-720/extras/matlab_in_emacs/index.html but I've never tried it. I don't think it has any refactoring support.

Anthony Williams
Has Emacs Matlab specific features? Code Completion? Refactoring, like "introduce variable"?
Mo
+6  A: 

You can use any editor you like in MATLAB by going to

File -> Preferences -> Editor/Debugger

and then change the radio button from 'MATLAB Editor' to 'Text editor' and the command for your editor of choice in there. I use this to launch gedit on my Linux box.

On the Mac-Specific side - it seems that there is a MATLAB bundle for TextMate

http://kjosmoen.org/2007/6/15/bugfixes-in-the-textmate-matlab-bundle

MikeCroucher
+4  A: 

There's also a TextMate bundle for MATLAB in the official repository. I keep a fork of it in [GitHub][1] too.

Incidentally, I recently became the maintainer, so I'm keen to get help and feedback from anyone who uses it. I've also tried to contact the author of the other bundle to get his changes pulled back into the mainline.

By far the easiest way to get working MATLAB/Octave support in TextMate is to use GetBundles. This is still in 'review', so you'll have to get this manually, but once you have, it's dead easy to search the Official SVN repo, and GitHub.

Matt
A: 

Eclipse with the Colorer plugin has decent syntax highlighting.

It doesn't solve the code completion problem, but if you're used to Eclipse, you don't waste time trying to work with the somewhat clumsy keyboard shortcuts of the native editor.

(And I'm a firm believer in the Pragmatic Programmer's recommendation to "Use a Single Editor Well")

Kena
+1  A: 

I might be biased, but I use emacs for almost everything. There is a really good emacs mode on MATLAB Central,

http://www.mathworks.com/matlabcentral/fileexchange/104

I don't know if emacs meets all of your requirements, but it's a pretty powerful and customizable editor.

I've never used this, but here's an Eclipse Plugin that seems able to some MATLAB highlighting,

http://www.eclipseplugincentral.com/Web_Links-index-req-viewlink-cid-136.html

MikeT