reshaping to display the same result of a function
Show older comments
I want the following function to be reshaped in a different manner:
for i=1:length(b)
mn(i)={min(reshape(b{i}(:,5),60,[])).'};
mx(i)={max(reshape(b{i}(:,6),60,[])).'};
end
This code breaks the rows into a group of 60 and then finds the max or min value. I, however, would like to reshape in such a way that the min value is found for the 60 rows and then the min value is given for each of these 60 rows rather than giving one value. For instance,
1
3
4
5
67
8
The min value of this column is 1. I want the result to be displayed in such a manner:
1 1
3 1
4 1
5 1
67 1
8 1
Accepted Answer
More Answers (0)
Categories
Find more on Operators and Elementary Operations 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!