How can I store polygons into a list?
10 次查看(过去 30 天)
显示 更早的评论
Say I have two polygons Pol1 and Pol2. How can I store them into a list that is used as an input for a function. My function, at some point, is supposed to be able to pick out polygons from this list and then graph them using polyshape.
Thank you!
Pol1 = [3 4; 1 1; 5 1];
Pol2 = [0 5; 5 5; 0 6; 6 3];
0 个评论
采纳的回答
David Hill
2020-1-31
Why not load them into a cell array?
Pol1 = polyshape([3 4; 1 1; 5 1]);
Pol2 = polyshape([0 5; 5 5; 0 6; 6 3]);
polyList={Pol1,Pol2};
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Elementary Polygons 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!