Labeled rows and column in a matrix

1 view (last 30 days)
Shima Asaadi
Shima Asaadi on 14 Mar 2016
Answered: MHN on 14 Mar 2016
I would like to create a matrix with labeled rows and columns. Then use the labels to fill in the Matrix. For example: the first row of matrix A is word1 and the third column of A is word3. I want to value A(word1,word3)=1.5 . sometimes I need numerical index of rows/columns (like a normal matrix) and sometimes the labels. I tried, but it does not have numerical index! Which structure would you suggest?
Thanks, Shima
Kirby Fears
Kirby Fears on 14 Mar 2016
The table structure works here.

Sign in to comment.

Accepted Answer

MHN on 14 Mar 2016
Use table instead.

More Answers (0)


Community Treasure Hunt

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

Start Hunting!