Saving a logical mask
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I have a code for creating a logical mask and calculating values inside the ROI of the mask. My query is: is it possible to save the logical mask to the desktop so that it can be applied to other data in the future?
4 commentaires
Stephen23
le 4 Août 2017
"As a file essentially so that in future I can just apply it to matrices. If this is possible"
It is possible and my answer shows you the simplest and most efficient way of doing this. Did you try it?
Jan
le 5 Août 2017
Modifié(e) : Jan
le 5 Août 2017
@Aaron: I repeat my question: Does "save to the desktop" mean the path:
C:\Users\<USERNAME>\Desktop
? Or do you mean the desktop window of Matlab? Storing it on the desktop of the OS might be less convenient than storing it in the user path of Matlab.
Réponse acceptée
Stephen23
le 3 Août 2017
Modifié(e) : Stephen23
le 5 Août 2017
save('nameOfFile.mat','nameOfVariable')
S = load('nameOfFile.mat');
mask = S.nameOfVariable;
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Get Started with MATLAB dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!