How to read, display and process .mha files in MATLAB?
Show older comments
I am having BRATS database of brain MR images with tumor in .mha format. How to read, display and process .mha files in MATLAB?
3 Comments
Mansi Lather
on 28 Mar 2017
Tan Leng Yee
on 29 Feb 2020
Edited: Tan Leng Yee
on 29 Feb 2020
Can you provide me the Brain tumor MR images dataset. My email is lengyee068@gmail.com. Thank you.
Rushabh Kanadia
on 3 Jun 2020
Hi, I am not able to access the BraTS Dataset as well, my email address is rushabhkanadia at gmail dot com
Could you please share it with me. Please
Accepted Answer
More Answers (1)
It worked follow these steps carefully:
- click Download (rt most) in the following link
https://in.mathworks.com/matlabcentral/fileexchange/29344-read-medical-data-3d you will be able to download .rar file named as ReadData3D_version1K
2. export .rar
3. Open Matlab and add this folder to the path.
4. Write these following program in the .mfile/ command window
data = mha_read_header('complete .mha file path');
V = mha_read_volume('complete .mha file path');
imshow(squeeze(V(:,:,round(end/2))),[]);
5. run
DONE
BAAAAAAAAAAAAM!!!!!!!!!!!!!!!
Categories
Find more on Convert Image Type in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!