Using mat2cell

조회 수: 3 (최근 30일)
Sebastian Daneli
Sebastian Daneli 2022년 1월 9일
댓글: Sebastian Daneli 2022년 1월 9일
I'm sorry, but I can't seem to understand how to use this function.
I have a datamatrix of size 1000x512, and a want to store this as 10 cells, each containing a 100x512 matrix. How do I do this using mat2cell?

채택된 답변

Walter Roberson
Walter Roberson 2022년 1월 9일
datacell = mat2cell(datamatrix, size(datamatrix,1)/10*ones(1,10), size(datamatrix,2) )
This divides datamatrix into 10 cells vertically; the size of the cells is automatically calculated. (The code as written does require that the number of rows is exactly divisible by 10)
  댓글 수: 1
Sebastian Daneli
Sebastian Daneli 2022년 1월 9일
Than you.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Data Import and Management에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by