How to fill closed curves. The code I wrote can't be implemented, I don't know how to correct it, thanks for the answer.

3 ビュー (過去 30 日間)
Wesley
Wesley 2022 年 3 月 11 日
コメント済み: KSSV 2022 年 3 月 11 日
fig = openfig('biaozhunxinyuevv.fig');
fig = gcf;
axObjs = fig.Children;
dataObjs = axObjs.Children;
xt= dataObjs(1).XData;
yt= dataObjs(1).YData;
fill(xt,yt,'r')
plot(xt,yt,'ko')
hold on

回答 (1 件)

KSSV
KSSV 2022 年 3 月 11 日
fig = gcf;
axObjs = fig.Children;
dataObjs = axObjs.Children;
xt= dataObjs(1).XData;
yt= dataObjs(1).YData;
fill(xt,yt,'r')
hold on
plot(xt,yt,'ko')
  4 件のコメント
Wesley
Wesley 2022 年 3 月 11 日
I see, the padding is well implemented, thank you very much for your answer.
KSSV
KSSV 2022 年 3 月 11 日
Thanks is accepting the answer.. :)

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

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by