Why the line is not shown in the graph?

1 visualización (últimos 30 días)
Nurul Shahizan Rudzuanazmi
Nurul Shahizan Rudzuanazmi el 5 de Feb. de 2020
Editada: Rik el 5 de Feb. de 2020
I am about to make "for loop" and plot 2 functions against frequency. When I run the code there is no error stated however, when the graph's window pop out it gives no result (blank graph). Is there anything that I miss in my loop? Or anything that I have to improve in the code?
Screenshot 2020-02-05 at 20.42.47.png

Respuestas (1)

Rik
Rik el 5 de Feb. de 2020
Editada: Rik el 5 de Feb. de 2020
You are not indexing the trans variable inside your loop, which results in you overwriting the value every loop iteration. That means you are plotting a vector with a scalar, which you don't see, because you haven't set a marker.
Untitled.png

Categorías

Más información sobre Specifying Target for Graphics Output 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