Difference between values and indices?

Can someone give an explanation of the difference between the values of elements in a matrix vs. the indices of elements in a matrix?
Thanks.

 Respuesta aceptada

Mischa Kim
Mischa Kim el 5 de Oct. de 2017
Editada: Mischa Kim el 5 de Oct. de 2017
E.g.
A = [1 2; 3 4]
Values of/in A are 1,2,3,4. To access the 2 you would use
val = A(1,2)
(1,2) are the indices of the element of A whose value is 2.

Más respuestas (0)

Categorías

Más información sobre Creating and Concatenating Matrices en Centro de ayuda y File Exchange.

Preguntada:

el 5 de Oct. de 2017

Comentada:

el 5 de Oct. de 2017

Community Treasure Hunt

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

Start Hunting!

Translated by