WHY DO I GET THIS ERROR USING THE ERROR BAR AND PLOT?

1 visualización (últimos 30 días)
Pul
Pul el 21 de Jul. de 2021
Comentada: Star Strider el 21 de Jul. de 2021
Hello,
does anyone know why I get this error: "Input arguments must be numeric, datetime, duration or categorical"?
Thank you.
  1 comentario
Dhruv G
Dhruv G el 21 de Jul. de 2021
Jan1989 seems to have strings and Var2,Var4 and Var5 seem to be NaNs

Iniciar sesión para comentar.

Respuesta aceptada

Star Strider
Star Strider el 21 de Jul. de 2021
The errorbar call should be:
errorbar(x, MODESTAMMEQ.Var5, MODESTAMMEQ.Var4,'.r','MarkerSize',6)
since ‘MODESTAMMEQ.Jan1989’ (that likely threw the error) has to be processed in the regexp and datetime calls to be usable as ‘x’.
However the ‘MODESTA’ table does not exist, so the second plot call does nothing, and substituting:
plot(x,[y, MODESTAMMEQ.Var5]);
gives a very strange result (at least to me).
.
  8 comentarios
Pul
Pul el 21 de Jul. de 2021
Ah, okay, I got it!
It's correct they are in that way.
Thank you very much for your help!
Star Strider
Star Strider el 21 de Jul. de 2021
As always, my pleasure!
.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Errorbars 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!

Translated by