How to use MATLAB editor more effectively
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Ken Bannister
le 17 Août 2022
Commenté : Ken Bannister
le 17 Août 2022
Still new to some features of MATLAB. I notice this in the MATLAB editor window. On the left edge of the window when I enter some
code, especially for-next loops and if statements, there are lines connecting boxes. There are some horizontal dashes here and there, also.
Not clear what the dashes mean.
The boxes have + signs in them. I found out that by clicking these boxes, code contained in the relevant for-next is collapsed, which
is very helpful sometimes. Is any of this documented anywhere? What else can be done with this capability? I have been converting some legacy FORTRAN 77 "spaghetti" code to MATLAB, and the process is rather painful and slow. Converting FORTRAN if statements and GO TO statements to their MATLAB equivalents can be tricky. Perhaps knowing more about this MATLAB editor capability would help me speed up my conversion work? Are there other editor tools that would help understand the program flow of a MATLAB program?
0 commentaires
Réponse acceptée
Steven Lord
le 17 Août 2022
What you're describing is the code folding functionality. See the "Fold Code" section on this documentation page for more information.
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Fortran with MATLAB dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!