pick up elements from a cell array and the result must be a cell array
Show older comments
I want to pick up all elements of a cell array except the last element. When I do V{1:end-1}, the result seems not to be a cell array.
Accepted Answer
More Answers (1)
madhan ravi
on 14 Aug 2019
cellfun(@(x) reshape(x(1:end-1),[],1), V,'un',0)
Categories
Find more on Software Development Tools 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!