Brace indexing is not supported for variables of this type.
2 views (last 30 days)
Show older comments
I am attempting to extract the contents out of my double array so I would be able to see whether my input variable equals a value in column 1 of mergetables, then use that row to obtain the value in the second column of that row:
mergetables=[SERIAL_NUMBER,BIA_COF_0,BIA_COF_1,BIA_COF_2,BIA_COF_3...
,BIA_COF_4,SF_COF_0,SF_COF_1,SF_COF_2,SF_COF_3,SF_COF_4];
BIA0=mergetables{app.AccelSNEditField == mergetables{:,1},2}
Unfortunately, I obtain this error:
Brace indexing is not supported for variables of this type.
Any suggestions or resolutions to apply?
0 Comments
Answers (1)
Dinesh Yadav
on 23 Jul 2020
Split up your last line of code into two line.
indexes = app.AccelSNEditField == mergetables{:,1}
to get logical values for the indexes that you will be using to get the second column.
BIA0=mergetables{indexes,2};
0 Comments
See Also
Categories
Find more on Matrix Indexing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!