1234567891011121314151617181920212223 |
- function plotMRI(dataset,mask,cmp)
- [~,~,x3] = size(dataset);
- sz1 = 4;
- sz2 = ceil(x3/sz1);
- figure('units','normalized','outerposition',[0 0 1 1])
- for sz = 1:x3
- subplot(sz1,sz2,sz)
- imagesc(dataset(:,:,sz));
- if exist('mask','var')
- hold on
- visboundaries(mask(:,:,sz),'LineWidth',0.5)
- end
- yticklabels('');
- xticklabels('');
- end
- if exist('cmp','var')
- colormap(cmp)
- else
- colormap("gray")
- end
- end
|