This is a part of program code for reading csv file and creating 3D array.
But when runnig the code , the error "Index is out of range" occurs.
How is this code modified?
Providing supplementary information about this code, NUM_data = 40
list = natsortfiles(list);
for n = 1:length(NUM_data)
X(:,:,n) = dlmread(list(n));
X_three_way = permute(X,[3 2 1]);