How to read .tif as .mat file?

2 views (last 30 days)
Azzadiva Sawungrana
Azzadiva Sawungrana on 10 Oct 2016
Edited: Marc Jakobi on 10 Oct 2016
I tried to read my .tif file as .mat and my fixed model didn't accept it. Is there something wrong in this code?
if true
load z.mat
z=double(imread(z.tif));
% code
end

Answers (1)

Marc Jakobi
Marc Jakobi on 10 Oct 2016
Edited: Marc Jakobi on 10 Oct 2016
Not sure what you are trying to do. Do you have a .tif file called z.tif? Then the solution would be to specify the .tif file as a string:
z = double(imread('z.tif'));

Tags

Community Treasure Hunt

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

Start Hunting!