Matlab Appdesigner for interactive plots
15 views (last 30 days)
Show older comments
I am trying to create an interactive plot GUI through AppDesigner.
I need to base the plot a given function:
I then need to generate a plot based off of the equation and what the user inputs.
I am currently struggling to code the callback for the plot button. Could somebody please tell me how (and it would greatly appreciated if you could show me complete code). This is what I have so far within a callback code for the plot button:
syms n N
chrisw23 on 6 Sep 2022
I suggest to call the plot function just once (initially with default parameters at startup()). The returned object is a line.
app.sinusoidLine = plot(app.UIAxes,time,y);
Store the object as property (i.e. app.sinusoidLine).
Then change the XData and YData properties of the line in your callback function.
app.sinusoidLine.XData = time;
app.sinusoidLine.YData = y;
More Answers (0)
Find more on Programming Utilities in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!