How to pick a value inside of a .mat file?
Afficher commentaires plus anciens
Hey all,
I have .mat file that contains 14k double variables and their values. Also, I have a workspace that contains some of those signals and more. I want to change values of the workspace variables with the ones in the .mat file. So, how can I check if my workspace has a copy of the singal in the .mat file and change its value? And, apply it for all 14k variables respectively?
Thanks.
5 commentaires
Stephen23
le 21 Juil 2023
"...apply it for all 14k variables..."
Are those 14k variables unfortunately stored separately in the workspace, or sensibly in an array?
Hasan Kaan Tuna
le 23 Juil 2023
Dyuman Joshi
le 23 Juil 2023
Modifié(e) : Dyuman Joshi
le 23 Juil 2023
If you want a specific solution, attach your data or a sample of data if the original data is big enough to attach. Use the paperclip button to attach the data file(s).
Hasan Kaan Tuna
le 23 Juil 2023
Stephen23
le 23 Juil 2023
"Can I use ismember like: ismember(MatFileWith14kVariables, ws) ? In this example ws stands for workspace."
I see nothing in the ISMEMBER documentation to suggest that it supports a "workspace" as an input argument (whatever that means). The ISMEMBER documentation states what input arguments it supports:
But given that the word "workspace" has a very specific meaning in MATLAB:
which contradicts your explanation given here, we can only conclude that either your explanations are inaccurate or you are using standard terms to mean other things. That makes it very hard for us to help you.
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Whos dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!