What is the easiest way to embed a text data file into a .m function so that you don't need two files.
Mostra commenti meno recenti
I have a function that uses a pre-generated lookup table that is stored as a text file. I would like to embed the text file into the .m file so that I don't have to move both files around.
Risposta accettata
Più risposte (1)
Elias Gule
il 1 Nov 2018
0 voti
I guess you can store your data as part of the code. Your may create an inner function or a subfunctions that initializes your lookup table; you can also store your data as properties of a class.
1 Commento
Zeb Barber
il 1 Nov 2018
Categorie
Scopri di più su Low-Level File I/O in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!