Writing results to different files
Mostra commenti meno recenti
Hi,
I am trying to make a code so that when I run my function, the results get saved in different files each time I run it. So for example, I run my code the first time, the results get saved in file 1 then file 2, file 3... so on Is there a way I can accomplish this?
Risposte (1)
This is such a common question that we have a very detailed description in the wiki page, complete with example code. It has also be answered many times on this forum:
There are several different functions for saving data to text files. Picking the best one depends on the nature of your data, which you do not tell us anything about. You can find a list of these functions here:
3 Commenti
Tab for Lab
il 9 Nov 2015
Modificato: Tab for Lab
il 9 Nov 2015
You have not told us what x, y, and z are: are they numeric arrays, cell arrays of steings, tables, character arrays, mixed cell arrays, ...? Are they scalar, 2D, or ND arrays? Each of these requires a different approach to file writing. If you want to tell us exactly what they are, then er can help you to write them to file.
You also need to tell us the required file format, which you have not told us so far.
Tab for Lab
il 9 Nov 2015
Categorie
Scopri di più su Environment and Settings 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!