HOW TO CONVERT AN .OUT FILE TO .TXT FILE VIA MATLAB

21 views (last 30 days)
Hello
Does anybody knows how to convert an .out file to .txt file via Matlab?

Accepted Answer

dpb
dpb on 28 Sep 2019
Edited: dpb on 29 Sep 2019
There's nothing about the file content that is specific to the name including the extension.
fn='yourfile.out';
[~,f]=fileparts(fn);
movefile(fn,[f '.txt'])
  8 Comments
dpb
dpb on 29 Sep 2019
Edited: dpb on 29 Sep 2019
Or more simply use the OS and just
!ren A*.out *.txt
Thanks for the catch on the new extension, Walter, I totally missed that part of the cleanup where I had pasted in the first name again...did fixup the Answer for posterity.

Sign in to comment.

More Answers (0)

Categories

Find more on MATLAB in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!