Extract column from table

11 Ansichten (letzte 30 Tage)
Akhil Aravind
Akhil Aravind am 23 Apr. 2019
Kommentiert: Peter Perkins am 3 Mai 2019
I have a table with 2 columns titled as Area , BoundingBox.
In Boundingbox i have four more columns. i want to take the values of 2nd column.
bndft =
9×2 table
Area BoundingBox
____ ________________________________
714 61.5 14.5 214 101
37 150.5 52.5 13 14
8 171.5 83.5 4 4
8 177.5 78.5 4 4
12 179.5 30.5 6 6
27 234.5 50.5 11 12
12 241.5 36.5 6 6
496 242.5 53.5 126 104
23 256.5 150.5 10 7
bndft.BoundingBox(:,1,1,1); for this command i am getting first cloumn but i need second column. help me....
Thnak you

Akzeptierte Antwort

KSSV
KSSV am 23 Apr. 2019
Area = rand(7,1) ;
BoundingBox = rand(7,4) ;
T = table(Area,BoundingBox) ;
iwant = T.(2)(:,2)
  2 Kommentare
Akhil Aravind
Akhil Aravind am 23 Apr. 2019
Thanks a lot sir
Peter Perkins
Peter Perkins am 3 Mai 2019
Or iwant = T.BoundingBox(:,2)

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Community Treasure Hunt

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

Start Hunting!

Translated by