MATLAB Answers


Creating a report file in txt format and merging it with created text file

Asked by sandeep singh on 9 Oct 2018
Latest activity Commented on by sandeep singh on 12 Oct 2018
Hello All, I have to create a text report file of my results, but i have made text file with instructions, this has to be merged or appended during the report generation i have to make user defined function using which i can use it for my further application and project Thanks in Advance


Sign in to comment.

1 Answer

Answer by ANKUR KUMAR on 9 Oct 2018
 Accepted Answer


fileID = fopen('qwerty.txt','w');
fmt = '%5d %5d %5d %5d\n';
fprintf(fileID,fmt, magic(4));
fileID = fopen('qwerty.txt','a');
fprintf(fileID,'%s','succesfully append in text file');
i have attached pesudo code and text to attached and required output please check and do the needful

Sign in to comment.