Labfans是一个针对大学生、工程师和科研工作者的技术社区。 | 论坛首页 | 联系我们(Contact Us) |
![]() |
![]() |
#1 |
高级会员
注册日期: 2019-11-21
帖子: 3,006
声望力: 66 ![]() |
![]()
我在同一张图上有两个trisurf 。我想有一个红色和一个蓝色,但是我似乎无法使用colormap来使两个图具有不同的颜色。我怎样才能做到这一点?
回答: figure [x,y]=meshgrid(1:15,1:15); tri = delaunay(x,y); z1 = peaks(15); th1 = trisurf(tri,x,y,z1); set(th1, 'FaceColor', 'b') hold all z2 = 0.4*peaks(15); th2 = trisurf(tri,x,y,z2); set(th2, 'FaceColor', 'r') hold off 更多&回答... |
![]() |
![]() |