Effacer les filtres
Effacer les filtres

Get the value of one .m file and use those values to plot in GUI

2 vues (au cours des 30 derniers jours)
ARN
ARN le 12 Déc 2018
Commenté : madhan ravi le 12 Déc 2018
Hi!
lets suppose i have a .m file which contains the following code
a=[1:0.01:10]
x=sin(2.*pi.*a)
plot(a,x)
check
where check.m is GUI file which takes the value a and x plot it in axes1.
Question is : Even the values of a and x are in workspace check still does not get those values. How can i give the values of a and x in OpeningFcn?
Thanks

Réponses (1)

madhan ravi
madhan ravi le 12 Déc 2018
Modifié(e) : madhan ravi le 12 Déc 2018
Make the check as a function file and create two input arguments(parameterising function) thereby passing the values as input arguments.
check(a,x)
  4 commentaires
ARN
ARN le 12 Déc 2018
Ok thanks! but i want to avoid making a function as it will have more than 21 parameters to start with; which will be more complicated than needed.
I think there is a solution where you can just access it through object.xxx or handles.xxx ?

Connectez-vous pour commenter.

Catégories

En savoir plus sur Migrate GUIDE Apps dans Help Center et File Exchange

Produits


Version

R2016a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by