isa not recognizing Line or Figure class
4 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Mikael Agopov
el 10 de Ag. de 2018
Comentada: KSSV
el 10 de Ag. de 2018
I wanted to test whether input data of a function is a Line object using something like:
>>
x=-2*pi:.01:2*pi;HLine=plot(sin(2*x));
However, now isa(HLine,'Line') returns false! So far, isa has faithfully recognized my self-made classes. Why doesn't it recognize Line?
0 comentarios
Respuesta aceptada
Guillaume
el 10 de Ag. de 2018
>> x=-2*pi:.01:2*pi;HLine=plot(sin(2*x));
>> class(HLine)
ans =
'matlab.graphics.chart.primitive.Line'
>> isa(HLine, 'matlab.graphics.chart.primitive.Line')
ans =
logical
1
You need to use the fully qualified name of the class
Ver también
Categorías
Más información sobre Data Type Identification en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!