MATLAB: How to append data to a CSV-file using MATLAB 7.9 (R2009b)

appendingcsvMATLAB

I have a CSV file which I created using the following command.
csvwrite('fileName.csv',rand(10));
And now I would like to append an additional data to this file.

Best Answer

Data can be appended to CSV-files using the DLMWRITE function with the ‘-append’ flag, like in the following example:
M = 1:10;
dlmwrite('fileName.csv',M,'-append');
Related Question