loading variables from command window to a workspace
8 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
busra gogen
le 24 Jan 2021
Commenté : busra gogen
le 24 Jan 2021
I have a closed region which is bounded by lattitudes and longitudes and i know that how many points inside in that region . When i run the program it gives 237(workspace windows shows 237 points) points and these points are coming from my 12094*3 matrix . However, i dont know third column values of 237 points, so i write a code to find third values like figure 1.
Figure 1.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/498597/image.png)
Now i have two problems. First problem is that when i copy third values to excel to check whethet it is 237 or not, i realized that there are 241 values. How it is possible? Although 237 variables comes from 12094*3 matrix, there are 241 variables in command window. My another problem is that when i count it gives 1. How can i load values to workspace from command window. I tried Mw(count+1) but it didnt work.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/498602/image.png)
0 commentaires
Réponse acceptée
KALYAN ACHARJYA
le 24 Jan 2021
Modifié(e) : KALYAN ACHARJYA
le 24 Jan 2021
"loading variables from command window to a workspace"
Assign any variable name during execution, it's automaticacly load the variable in the workspace (without variable name, it may saved as "ans" variable name)
or
Or
To save the multiple array or vectors, you may consider cell array.
4 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Preprocessing Data 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!