change only 3 of many outputs of a function through the App Designer
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Michail Kanoupakis
il 5 Nov 2020
Modificato: Mario Malic
il 7 Nov 2020
I have an Configuration.m file with many variables. I use it as a configuration settings file.
It contains many variables, which I change every time in order to get different plots. After I change them I run the file through another function which uses the variables of the Configuration.m file.
I am trying to create an App via App Designer for the program I have made.
On the app designer I would like to control and change the variables of the Configuration.m file, that's why I converted the Configuration.m file to a function file.
From all the outputs of the Configuration function(now) I would like to change specific outputs.
How am I supposed to access and modify through the app designer only the outputs that interest me ?
2 Commenti
Mario Malic
il 5 Nov 2020
What does it mean many variables? what type of variables are there? How does your program read them? Are you running the script and getting the variables from workspace?
Write a short example of your code please, and we can suggest something.
Risposta accettata
Mario Malic
il 6 Nov 2020
Modificato: Mario Malic
il 7 Nov 2020
I am not sure what would be the easiest way considering that Configuration.m generates a file. After you call Configuration, you can read file, edit and save it again, or you can do it after you call LoadFile.
You can create a helper function or write code directly after LoadFIle that will set variables values according to the value in component Edit Field Numeric.
Data.fmin = app.EditFieldComponent1.Value;
Data.fmax = app.EditFieldComponent2.Value;
Edit:
This would work if your function NeuronsAnalysis() would receive app as input argument and if you'd call the function within the app.
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Develop Apps Using App Designer in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!