Hi, I'm currently trying to figure out how to display an image after changing it's class type in Matlab. My code is:
im = imread('Pic.png');
imshow('Pic.png');
title ('pic')
im2 = im2double(im);
imshow ('im2')
title ('DoublePic')
but running it just gives an error message for imshow('im2'), can someone explain why this is happening? Thanks

 Akzeptierte Antwort

KSSV
KSSV am 16 Okt. 2022

1 Stimme

imshow ('im2')
In the above line im2 is considered as a string, this is not correct. It should be:
imshow (im2)

Weitere Antworten (0)

Kategorien

Mehr zu Environment and Settings finden Sie in Hilfe-Center und File Exchange

Produkte

Version

R2021a

Gefragt:

am 16 Okt. 2022

Beantwortet:

am 16 Okt. 2022

Community Treasure Hunt

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

Start Hunting!

Translated by