Making amount of two matrix same by smoothing one of them
조회 수: 1 (최근 30일)
이전 댓글 표시
Hello
I have two matrix
One of those matrix consists of 3000 data points and another matrix consists of 600 da apoints. In this particular case I want to get 600 data points from 3000 by moving avarage smoothing if it is possible. Generally I want to write code which will help me to decrease data with more points by moving avarage smoothing and make it equal to the number of data points of another matrix.
댓글 수: 0
답변 (1개)
Abderrahim. B
2022년 8월 24일
Hi!
TRy this :
A = randi(10, 3000, 1) ;
n = 5; % average length - 3000/600
newA = mean(reshape(A, n, []))
Hope this helps
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!