How to change line specifications for frequency response?

1 回表示 (過去 30 日間)
Nicolas Ochmann
Nicolas Ochmann 2017 年 8 月 21 日
コメント済み: Star Strider 2017 年 8 月 21 日
Hi everybody,
I would like to plot a response to an initial condition in the frequency domain such as:
initial(G1,initial_state,'k','--')
However, even though I can change the graph color, I can not change the line type or line width and get the following error: "Invalid syntax for time or frequency response command."
Does anybody know how to adapt plot specifications?
Thank you in advance!
Nicolas

採用された回答

Star Strider
Star Strider 2017 年 8 月 21 日
The Control System Toolbox and System Identification Toolbox graphics functions do not generally allow you alter their properties.
The easiest work-around is to get the outputs of the functions and plot them yourself in ordinary plot (or subplot) calls:
[y,t,x] = initial(G1, initial_state);
figure(1)
plot(t, y, t, zeros(numel(t),1),':')
You can do everything with that plot that you can do with any other plot object.
  2 件のコメント
Nicolas Ochmann
Nicolas Ochmann 2017 年 8 月 21 日
That works! Thanks :)
Star Strider
Star Strider 2017 年 8 月 21 日
As always, my pleasure!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMathematics についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by