How to set UIAxes min and max lim for plot in app designer ?
96 次查看(过去 30 天)
显示 更早的评论
Hi All
to set a min and max limit for my UIAxes in add designer I use :
ax=app.UIAxes;
ax.YLim([minlim,maxlim])
but I get the error :
Subscript indices must either be real positive integers or logicals.
7 个评论
采纳的回答
Adam Danz
2020-4-13
编辑:Adam Danz
2020-4-13
It looks like what you want to do is
axis(app.UIAxes, 'tight')
Your current code does not give you the minimum of all plotted signals. It just gives you the minimum (and maximum) of the last plotted signal listed in app.UIAxes.Children since you're overwriting the minlim and maxlim values upon each iteration of the for-loops.
8 个评论
另请参阅
类别
在 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!