App Designer | hold on does not work as expected
96 次查看(过去 30 天)
显示 更早的评论
In live scripts or simple matlab code I normaly draw slice and two plot3 graphics in one axes:
but, using App Designer, it cant draw normally:
1 - only slice, 2 - slice and 2 plot3, 3 - slice and one plot3
code for App Designer: (V - 3-d matrix)
hold on;
colormap(app.fullaxes, map);
s = slice(app.fullaxes, app.y_3, app.x_3, app.z_3, app.V, 0,0,15);
set(s, 'EdgeAlpha',0.1);
plot3(app.fullaxes, y_1, x_1, z_1, 'Color', app.color_2);
plot3(app.fullaxes, y_2, x_2, z_2, 'Color', app.color_3);
hold off;
0 个评论
采纳的回答
Kevin Holly
2022-5-17
I believe you need to specify the axes of your hold on. Please let me know if this works.
hold(app.fullaxes,'on');
colormap(app.fullaxes, map);
s = slice(app.fullaxes, app.y_3, app.x_3, app.z_3, app.V, 0,0,15);
set(s, 'EdgeAlpha',0.1);
plot3(app.fullaxes, y_1, x_1, z_1, 'Color', app.color_2);
plot3(app.fullaxes, y_2, x_2, z_2, 'Color', app.color_3);
hold(app.fullaxes,'off');
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Develop Apps Using App Designer 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!