1

I'm working on a document with hundreds of figures, that are generated from matlab. From time to time, I have to change among the hundreds of .m files to generate the corresponding matlab figure and therefore makes quite cumbersome the whole work.

I'm interested in a solution something like below, so that when I click any figure (or link) in generated .pdf (or in .tex) file the corresponding matlab .m file will open in Matlab.

Thanks

\documentclass{article}
\usepackage{hyperref}
\begin{document}
\href{run:d:/my folder/matlab.m}{This is my link}
\end{document}
  • This would require a connection between the figure and the relevant matlab file, i.e. Figure A must 'know' that it has been generated with matlabA.m and Figure B is from matlabB.m – user31729 Feb 27 '17 at 8:14
  • how to develop that connection? – kaka Feb 27 '17 at 8:33
  • You have to store some information of course or incorporate the file name of the matlab script somehow in the figure file name and retrieve ('parse') the file name for this – user31729 Feb 27 '17 at 8:34
  • 1
    Perhaps something like attachfile2 package provides is an alternative? – user31729 Feb 27 '17 at 8:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.