Error using zeros CLASSNAME input must be a valid numeric or logical class name.
Ältere Kommentare anzeigen
I try to draw line on image. in this code mat = zeros(250, 250, 'unit8'), they show this error Error using zeros CLASSNAME input must be a valid numeric or logical class name. I use matlab2017a.
1 Kommentar
Stephen23
am 18 Dez. 2017
Read the error message. It tells you what the problem is. Did you check the class name?
Akzeptierte Antwort
Weitere Antworten (1)
Karthik Bhogi
am 3 Mai 2020
0 Stimmen
@Joe Joe
in your code mat= zeros(250, 250, 'unit8')
please remove that unit 8 term and the code will run without any errors.
1 Kommentar
Karthik Bhogi
am 3 Mai 2020
Bearbeitet: Karthik Bhogi
am 3 Mai 2020
you can also use 'single' or 'double' in place of 'unit8' to run your code without any errors.
Kategorien
Mehr zu Logical finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!