Hopefully this is a simple question: is there a simple, fast, and general method of porting the the text of an m-file verbatim into LaTeX and have it appear as it does in VI, i.e. ignore all of the MATLAB nomenclature, like % and so on, to appear as standard text consistent with whatever package I am using?
Asked
Active
Viewed 305 times
2
\begin{verbatim}...\end{verbatim}or if you need fancier formatting look at the fancyvrb or listings packages/ – David Carlisle Jan 13 '13 at 21:38mcodepackage useslistingswith a pre-defined format that matched that of MATLAB. It also supports\lstinputlistingsfor inclusion of the.m-file. – Werner Feb 17 '13 at 20:57matlab-prettifierpackage; see this answer. – jub0bs Apr 28 '14 at 15:34