How to convert 1D-array of 2D-matrix (contents) to 3D-array

5 views (last 30 days)
Basically, I have a 1D-array, each has 2D-matrix content. How do I convert this into 3D-array (which is to be used by isosurface and plotting function)? Below is my code. filename is stored as 1D-array of string type imread(filename): return 2D-matrix (3D in color? -extra: do I have to convert it to gray as 2D for isosurface function?)
[filename, pathname, filterindex] = uigetfile('*.png','Select 2D slices', 'multiselect', 'on');
for i=1:numel(filename)
slice{i}=imread(filename{i});
end

Answers (0)

Products

Community Treasure Hunt

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

Start Hunting!