필터 지우기
필터 지우기

how to import text files in different subfolders with the same names?

조회 수: 2 (최근 30일)
Mos_bad
Mos_bad 2017년 12월 23일
댓글: Rik 2017년 12월 23일
There are main folder A First subfolders A1 to An Second subfolders A11 to A1m; A21 to A2m; .... ; An1 to Anm Third subfolders A111 to A11K; A1m1 to A1mk; ... ; Anm1 to Anmk The image of the structure is attached. There are many text files with the same names in the third subfolders, I need to import and compare the text files with the same names in each third subfolders (i.e., gm.txt in A111 to Anmk). Please note there are some other text files than gm.txt in the third subfolders as well. the text files were created by another application with the same names (gm.txt)
  댓글 수: 3
Mos_bad
Mos_bad 2017년 12월 23일
Stephan, BASED ON THE ATTACHED FIGURE, do I have to loop over n, m, and k ?
Rik
Rik 2017년 12월 23일
You could also generate indices with meshgrid, but a nested loop is by far the easiest.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 File Operations에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by