MATLAB Answers

How to convert image into matrix

1,286 views (last 30 days)
Suyash bhardwaj
Suyash bhardwaj on 27 Apr 2012
Answered: keerthana reddy on 14 Feb 2019
Dear readers, i am new to matlab and want to learn how to convert or represent a picture in bmp or jpeg format in matrix form so that manipulations can be carried out on it. your suggestions will be worth for me..
suyash bhardwaj

  0 Comments

Sign in to comment.

Answers (4)

Andreas Goser
Andreas Goser on 27 Apr 2012
If you import a picture, it is actually a matrix, so I am not sure what do are looking for. Try:
imdata = imread('ngc6543a.jpg');

  6 Comments

Show 3 older comments
Shyamala S
Shyamala S on 18 Jan 2015
Can anyone help in converting an image into matrix value in MATLAB.....Pls reply me with corresponding code
Soma Debnath
Soma Debnath on 25 Aug 2016
I am very new to MATLAB,so i have no idea that how to create and load training dataset of images in matlab?please write the corresponding code also.
snehal jaipurkar
snehal jaipurkar on 24 Oct 2016
Dis is really helpful. I thanks experts for their support to beginners like usus.

Sign in to comment.


an iy
an iy on 14 Nov 2017
imdata = imread('ngc6543a.jpg');

  0 Comments

Sign in to comment.


Omar Omari
Omar Omari on 31 Jan 2019
hi readers
How can I take a picture from a camera my labtop and draw it into matrices and vice versa
Thanks

  0 Comments

Sign in to comment.


keerthana reddy
keerthana reddy on 14 Feb 2019
x=dicomread('i2.jpg');
imshow(i2);

  0 Comments

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!