필터 지우기
필터 지우기

Calculate mean from cell array from every nth value

조회 수: 2 (최근 30일)
David du Preez
David du Preez 2016년 7월 2일
답변: Image Analyst 2016년 7월 2일
I have a cell array of 8401x11 and in the first line are the column headings. I want skip the first 15 lines after the headings and then calculate the average of every 24th cell in column 6 and 9.

채택된 답변

Image Analyst
Image Analyst 2016년 7월 2일
Make it easy for us and attach some sample data, for example by attaching a .mat file with the paper clip icon.
Some untested code is:
ca = originalCellArray(16:24:end, [6,9])
columnMeans = mean(cell2mat(ca));

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Data Types에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by