How to print the element of a cell into a text file?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Mnr
am 28 Mär. 2014
Kommentiert: Mnr
am 28 Mär. 2014
Hello all,
I have a 1X8 cell array with all its elements are 1X300 cells and each of those 300 cells are 4X1 doubles. I would like to print the cell array into a .txt file. I would appreciate if somebody can help me please. Thanks.
0 Kommentare
Akzeptierte Antwort
Azzi Abdelmalek
am 28 Mär. 2014
If A is your cell array
M=cell2mat(cellfun(@(x) cell2mat(x),A','un',0))
dlmwrite('file.txt',M)
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Multidimensional Arrays finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!