MATLAB Answers

matlab help required to open a file and convert theimage to graylevel

1 view (last 30 days)
NIJU MATHEW
NIJU MATHEW on 12 Dec 2020
Answered: Image Analyst on 12 Dec 2020
i need to open a matlab file named as1.mat and convert the image from binary( masks are binary, 1-channel images). to gary level .
matlab help required to open a file and convert theimage to graylevel
i need to open and see the images of brain tumor. can some one help me with the coding on how to open and see the images and convert the images from binary to gray level.
the file is in the given below link .
image is given in attachement as jpg .i need to see the original image in gray level or any other method
  3 Comments

Sign in to comment.

Answers (1)

Image Analyst
Image Analyst on 12 Dec 2020
To read the image into an array in your program just use imread():
grayimage = imread('4.jpg');
See my Image Segmentation Tutorial in my File Exchange
for an instructive demo on how to do basic image analysis on an image.
Also see my attached program that finds a brain tumor in an mri image.

Community Treasure Hunt

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

Start Hunting!

Translated by