# How can I generate the Autocorrelation matrix of a vector of random variables?

조회 수: 31 (최근 30일)
Mohamad Al Hassan . 2019년 2월 26일
답변: Munish Raj . 2019년 3월 1일
Consider a vector containing random variables such as the following:
y=rand(10,1);
How can I evaluate the autocorrelation between all the components of the vector? I want to obtain the 10x10 autocorrelation matrix of the vector.

댓글을 달려면 로그인하십시오.

### 답변 (1개)

Munish Raj 2019년 3월 1일
MATLAB’s auto correlation function can be used for this purpose.
The documentation for the autocorrelation can be found here.
The following is a sample code on how you would use it
y=rand(10,1); %derfine a random vector
[acf,lags,bounds] = autocorr(y) %autocorrelate the vector
plot(acf) %plots the autocorrelated vector

댓글을 달려면 로그인하십시오.

### 카테고리

Help CenterFile Exchange에서 Student's t Distribution에 대해 자세히 알아보기

### Community Treasure Hunt

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

Start Hunting!

Translated by