how to create an array of plots in App designer
17 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I am using Matlab2019b and i am trying to create a real time plots, the number of plots displayed, depends on the user input parameters, so i defined a property
H_PLOT
;
then i created a for loop when a pushbutton is pressed
for i=1:1:app.num_of_channels
figure;
app.H_PLOT(1:app.num_of_channels) = plot(nan,nan, 'b');
end
but it gives me the following error:
"Assignment between unlike types is not allowed."
i dont understand why however it works well in normal m-code script but it doesnt work in app designer
4 commentaires
Walter Roberson
le 13 Juil 2021
It is not clear that you did
properties (Access = private)
H_PLOT; % Description
end
Réponses (1)
Walter Roberson
le 23 Juil 2021
In the lines
app.H_PlOT.XData(1:app.index) = 1:app.index;
app.H_PlOT.YData(1:app.index) = 1:app.index;
You are referring to H_PlOT instead of to H_PLOT . That is, you are using lower-case L instead of upper-case L.
3 commentaires
Walter Roberson
le 23 Juil 2021
What sequence of events or commands are you using to get that? I tried it and just got a blinking light.
Voir également
Catégories
En savoir plus sur Develop uifigure-Based Apps dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!