Reputation: 269
I read this previous question What alternatives are there to the MATLAB Editor? and I am interesting in using another editor so I can also compile my codes with MATALB.
I did what the mentioned link suggested but I cannot see the difference. I went to Preferences Editor/Debbuger and I changed the editor to Notepad++ and nothing happened.
How can I use Notepad++ to compile and run MATALB codes?
P.S. I looked for "run matlab with notpad++" on google but did not find anything interesting. Also my previous question is related (Can I use MATLAB editor without running MATLAB?).
Upvotes: 2
Views: 8015
Reputation: 81
I answered this a bit more thoroughly here: Running a MATLAB script from Notepad++
Use NppExec add-on and press F6, copy paste the following and save the script:
NPP_SAVE
set local MATPATH=C:\Program Files\MATLAB\R2015a\bin\matlab.exe
cd "$(CURRENT_DIRECTORY)"
"$(MATPATH)" -nodisplay -nosplash -nodesktop -r "try,
run('$(CURRENT_DIRECTOR)$(FILE_NAME)'), catch me, fprintf('%s /
%s\n',me.identifier,me.message), end"
Upvotes: 1
Reputation: 5720
When you mean run
matlab code, if you just want to edit it and save and then run from MATLAB terminal, then you can use it just regularly as well. Save in notepad, run on MATLAB.
The problem arises when you want MATLAB editor features like debugger, and execute a block of code within %%
. You cannot do all of it. You can set breakpoints, How to debug matlab code without gui
I think you wont get the other features of MATLAB editor if you use an external editor.
Upvotes: 0