How do I group loaded .txt files on a single array or struct?
이전 댓글 표시
I'm trying to compare some files' names to group them according to their date. it happens that I have data from 3 different equipment and I'm trying to compare the files' names to build a single array or struct without success.
I loaded the files using:
G = dir('GPS_*.txt');
for n = 1:length(G)
load(G(n).name)
end
H = dir('HOB_*.txt');
for n = 1:length(H)
load(H(n).name)
end
N = dir('NEF_*.txt');
for n = 1:length(N)
load(N(n).name)
end
I have now the files loaded as:
G 12x1 struct
GPS_01122013_1 4846x11 double
GPS_02112013_1 3819x11 double
GPS_02112013_2 3820x11 double
H 12x1 struct
HOB_01122013_1 5226x9 double
HOB_02112013_1 3580x9 double
HOB_02112013_2 3826x9 double
N 13x1 struct
NEF_01122013_1 88x9 double
NEF_02112013_1 63x9 double
NEF_02112013_2 64x9 double
I tried to use strcmp (G.name,H.name) but had no result. I wanna group by date to build a matrix for each day of data.
Thanks in advance for the help
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Characters and Strings에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!