필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

I have a cell matrix with arrays. Each row has a certain size matrix. I would like to add the matrices along the rows

조회 수: 1 (최근 30일)
Given r={rand(3), rand(3);rand(2),rand(2)}, I want to get a row-wise sum of each size. cellfun and @sum lets you add arrays like that but seemingly, not matrices.
Is there a vectorized solution?
Also --- is it possible that sparse matrices make the operation slower?
  댓글 수: 1
Stephen23
Stephen23 2017년 3월 11일
What is "a row-wise sum of each size" ?
Do you wish to sum each matrix along columns or rows?

답변 (0개)

이 질문은 마감되었습니다.

제품

Community Treasure Hunt

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

Start Hunting!

Translated by