MATLAB App - UIAxes Array Incorrect
1 次查看(过去 30 天)
显示 更早的评论
I'm trying to create a MATLAB app for a code I have written. I have a tspan that is
tspan = [0 0.25 0.5 0.75 1 2 3 4 5 6 7 8 9 10 11 12];
I have set the xticks to these values manually in the app designer. However, when the app solves it starts the corresponding results x-array at a value of 1 - not at the correct starting value of 0. It is essentially plotting it as if my tspan were [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16]. Can anyone help me resolve this?
0 个评论
采纳的回答
Mario Malic
2021-2-25
Hi,
XLim is the property that you need to adjust in the code, or in the component editor.
app.UIAxes.XLim = [0 12];
3 个评论
Mario Malic
2021-2-26
Is app.UIAxes actually the axes you're plotting on?
Can you show your code with plot command?
更多回答(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!