no definition for plot3

1 visualizzazione (ultimi 30 giorni)
jilei liu
jilei liu il 7 Mag 2024
Commentato: jilei liu il 10 Mag 2024
It's ok to use plot3 in MATLAB script,problems comes when I try to packet them in my function ‘PlotDampRoots’:says plot3 not defined.what suppose I do?
  3 Commenti
jilei liu
jilei liu il 8 Mag 2024
I call it in a slider Callback function “omegan_Callback”,"omegan" = the slider value,I want the plot updated when I change “omegan”
DGM
DGM il 8 Mag 2024
For clarity:

Accedi per commentare.

Risposta accettata

Steven Lord
Steven Lord il 8 Mag 2024
Based on the translation of the Code Analyzer message DGM posted, it seems that somewhere in the PlotDampRoots function you assign to a variable named plot3. If you do that you will not be able to call the plot3 function inside that function (even if the attempted function call occurs before the assignment to the variable in the file.) Search the function for where you assign to plot3 and rename that variable.
  3 Commenti
Torsten
Torsten il 9 Mag 2024
You set plot3(x,y,z) = 5 in line 32 of PlotDampRoots. That's very bad.
jilei liu
jilei liu il 10 Mag 2024
oh my god,My head is sticky,Thanks for you guys help!Finally I got the beautiful correct figure I want.

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su Graphics Objects in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by