Writing an array to a file
1 次查看(过去 30 天)
显示 更早的评论
I have a 2d array of unknown size. I wish to write this into a file. After doing so i have similar arrays which have to be appended to the same file. This is one part. Other part is that I have to read the same file one array at a time. I don't know the size so the arrays have to separated. I wish to get the code for the same. The array contains only numeric data. I don't know what numbers are present in the file. Just there is an integer 2d array which has to be written to a file by a function separating more arrays as i store them in the file and another function which can read the same file one array at a time.
Can anyone help? Thanks
0 个评论
回答(2 个)
Image Analyst
2013-12-13
You can save the various arrays to a mat file with save(). You can recall them separately also. Pretty easy - just look up save() in the help.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Structures 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!