How to remove text strings from .dat file
显示 更早的评论
Hi everyone.
There is a .dat file, where the first raw of it:
#component = 1 embedding = 1
Then 20x3 matrix of numbers and again:
#component = 1 embedding = 2
So how to remove these lines from matlab when I load the file or is it better to remove from array like:
if x(1,1) == '#component';
x(1,1)=[];
4 个评论
per isakson
2012-7-31
编辑:per isakson
2012-7-31
Something like
textscan ( ..., 'Headerlines', 1 )
Artyom
2012-7-31
Artyom
2012-7-31
回答(1 个)
Jan
2012-7-31
textscan(..., 'CommentStyle', '#')
类别
在 帮助中心 和 File Exchange 中查找有关 App Building 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!