Duplicate the element n times for specific dimension

Dear all,
I have a matix. The size is 22x15x30x4000 (316800000 double)
I would average the elements in last dimension between 1001:3000, and duplicate this value 4000 times in the last dimension. The size is also 22x15x30x4000.
Could anyone help me?

답변 (1개)

Rik
Rik 2020년 7월 6일

0 개 추천

Use subindexing, the mean function, and repmat.

카테고리

도움말 센터File Exchange에서 Operators and Elementary Operations에 대해 자세히 알아보기

질문:

2020년 7월 6일

답변:

Rik
2020년 7월 6일

Community Treasure Hunt

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

Start Hunting!

Translated by