Info

Cette question est clôturée. Rouvrir pour modifier ou répondre.

how to acquire a value from workspace

3 vues (au cours des 30 derniers jours)
danny agus
danny agus le 8 Juin 2011
Clôturé : MATLAB Answer Bot le 20 Août 2021
i have a question about matrix value, if there is a point of an image and consist of x and y coordinates.
centroids = [x value, y value]
for example i got centroids = [300,400] %in workspace
nah, could i put the value into 2 different variables ? like x and y ? so x will contain 300 and y will contain 400 ?
i can do that manually,with click on the workspace and rename it, but could i do it with code ?

Réponses (1)

David Young
David Young le 8 Juin 2011
x = centroids(1);
y = centroids(2);
  1 commentaire
danny agus
danny agus le 8 Juin 2011
thx :)

Cette question est clôturée.

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by