필터 지우기
필터 지우기

matrix manipulation,want to find mean value?

조회 수: 1 (최근 30일)
Dhines
Dhines 2013년 2월 23일
having matrix W. its size is 7x50. totally 350 elements. in this column'1' have to find mean value of 4 elements then subtracts this value with remaining mean value of 3 elements. want to get this mean value up to 50 columns.how to implement this?

채택된 답변

nanren888
nanren888 2013년 2월 23일
"subtracts this with" ? .
Try something like
.
homeworkVec = mean(W(1:4,:),1)-mean(W(5:7,1),1);
In mean(x,1), the "1" is default. I just put it in to be explicit.
homeworkVec = mean(W(1:4,:))-mean(W(5:7,1));

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB Coder에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by