Error using fopen
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Hi,
I'm using the following command in a for-loop:
imwrite(x,strcat('L_',num2str(c),'_m.bmp'),'bmp');
And, getting the following error:
Error using fopen
File name must be a vector of type char.
Error in imwrite (line 453)
fid = fopen(filename, 'a');
Error in fuzzycmeans (line 83)
imwrite(x,strcat('L_',num2str(c),'_m.bmp'),'bmp');
Why is that? How can I fix this issue?
Thanks.
0 Kommentare
Antworten (1)
Star Strider
am 25 Aug. 2014
As a troubleshooting step, run this line:
flnm = strcat('L_',num2str(c),'_m.bmp')
just before your imwrite call and see what the result is.
2 Kommentare
Star Strider
am 27 Aug. 2014
What does ‘flnm’ produce? Is it ‘a vector of type char’?
If you do:
cn = class(flnm)
what is the result?
Siehe auch
Kategorien
Mehr zu Image Processing Toolbox finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!