Give name from string array
이전 댓글 표시
I would like to give the name in the 'tiles' array to every loop of the AHN2 matrix. So the first loop should result in a matrix in which AHN2 = r02cn1, then the second would be called r02gz2 and so on. I don't know how to do this, any help would be
close all
clear all
tiles = {'r02cn1', 'r02gz2', 'r02hz1', 'r07dn1', 'r07dz1'};
for v = 1:length(tiles)
fileAHN2_05m = ['Geconverteerde data/ahn2/ahn2_05_ruw/' ...
char(tiles(v)), '/' char(tiles(v)), '.tif'];
[AHN2, R_AHN2] = geotiffread(fileAHN2_05m);
tiles{v} = AHN2;
end
채택된 답변
추가 답변 (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!