write cell array of strings in text file

109 views (last 30 days)
I would like to save my cell array of strings in a *.txt file. A simple way is like the following:
filePh = fopen('features_.txt','w');
for r=1:rows
So, each cell that is a string (like a sentence...) in one row. But some strings are not very well defined. for example in one string there might be two whitespace between words, or even a tab. Then this code separates the strings in to different rows.
Does anyone know the solution?
Thank you very much in advance

Accepted Answer

Kirby Fears
Kirby Fears on 15 Apr 2016
filePh = fopen('features.txt','w');
sh as
sh as on 15 Apr 2016
Well, for me ';' separated the columns

Sign in to comment.

More Answers (0)


Find more on Characters and Strings 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!