Worki ng with cells
Mostrar comentarios más antiguos
hey all,
i have a cell of <1x20> dimensions and each cell contains two x-values in a coordinate.
I want to work with these two coordinates separately, but I dont know how to access them?
Xidx1 =
Columns 1 through 5
[1x2 double] [1x2 double] [1x2 double] [1x2 double] [1x2 double]
Columns 6 through 10
[1x2 double] [1x2 double] [1x2 double] [1x2 double] [1x2 double]
Columns 11 through 15
[1x2 double] [1x2 double] [1x2 double] [1x2 double] [1x2 double]
Columns 16 through 20
[1x2 double] [1x2 double] [1x2 double] [1x2 double] [0]
1 comentario
Walter Roberson
el 26 de Jun. de 2015
Xidx1{20} is only [0] not a pair of values.
Respuesta aceptada
Más respuestas (1)
Walter Roberson
el 26 de Jun. de 2015
cellfun(@(v) v(1), Xidx1)
2 comentarios
soloby
el 26 de Jun. de 2015
Walter Roberson
el 26 de Jun. de 2015
Obviously
cellfun(@(v) v(2), Xidx1)
Categorías
Más información sobre Startup and Shutdown en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!