有一组一维数组想要以​2000为窗口,窗口​移动步长为100计算​方差该如何实现?。

有一组一维数组想要以2000为窗口,窗口移动步长为100计算方差该如何实现?

 채택된 답변

0 개 추천

A=rand(1,3000);
ind=[1:100:length(A)-1999]+[0:1999]';
res=var(A(ind));

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 MATLAB에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!