Hi everyone, how can i convert a 2500x21 matrix into 2500x42 matrix by using cubic/spline interpolation.
조회 수: 1 (최근 30일)
이전 댓글 표시
Hi everyone, how can i convert a 2500x21 matrix into 2500x42 matrix by using cubic/spline interpolation.
댓글 수: 0
답변 (1개)
KSSV
2018년 9월 12일
A = rand(2500,21) ;
B = zeros(2500,42) ;
for i = 1:2500
B(i,:) = interp1(1:21,A(i,:),linspace(0,21,42),'spline') ;
end
This can be vectorised using bsxfun
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!