How can i change the positions of numbers in a matrix
조회 수: 1 (최근 30일)
이전 댓글 표시
I have a 100x7 matrix consisting of random numbers between 0 and 0.5
How can i change the positions of the numbers so that all the zeros are together?
댓글 수: 0
답변 (1개)
KALYAN ACHARJYA
2020년 4월 3일
sort the matrix, you will get all rows at initails of rows numbers
sort(matrix)
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Shifting and Sorting Matrices에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!