how to display data from a cell?

1 次查看(过去 30 天)
asim nadeem
asim nadeem 2018-8-13
I created a cell {{{1,2,3},{4}}, {{1,2},{3,4}}} it has two partitions in it or may be more. What i want in my output is that answer should be in the form {{1,2,3},{4}} i.e a partition which satisfy certain conditions. But my answer is like this ans =
[1x3 double] [4]
  5 个评论
asim nadeem
asim nadeem 2018-8-13
编辑:asim nadeem 2018-8-13
i checked all the partitions one by one and if they justify the condition i want to see literally {1,2,3},{4} so i got 4 answers out of 7. ans =
[1x3 double] [4]
ans =
[1x3 double] [3]
ans =
[1x3 double] [2]
ans =
[1] [1x3 double]
asim nadeem
asim nadeem 2018-8-13
编辑:asim nadeem 2018-8-13
for i= 1:totoal no of partitions
d = C{i};% ith partition
%conditions applied
%say C{1},C{2} are answers
C{i,:}% output

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Graphics Object Programming 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by