필터 지우기
필터 지우기

index in position 2 exceeds array bounds (must not exceed 1)

조회 수: 1 (최근 30일)
L Mllr
L Mllr 2021년 4월 6일
댓글: L Mllr 2021년 4월 7일
this is my code
Total_amount = 100000000;
senarios = 10000
years = 5
% Lower bin of the matrix
load("QFRM_Data (2).mat")
AEX_ = AEX(:,[6])
NASDAQ_= NASDAQ(:,[6])
Nikkei_= Nikkei(:,[6])
Treasury_= Treasury(:,[6])
EURJPY_= EURJPY(:,[6])
EURUSD_= EURUSD(:,[6])
n=1;
suma=0
for n=1:1:10000
Treasury_(1,n)
suma=Treasury_(1,n)+suma;
norminv=1-suma
n=n+1;
end
n=1;
suma=0
for n=1:1:10000
AEX_(1,n)
suma=AEX_(1,n)+suma;
norminv1=1-suma
n=n+1;
end
n=1;
suma=0
for n=1:1:10000
NASDAQ_(1,n)
suma=NASDAQ_(1,n)+suma;
norminv2=1-suma
n=n+1;
end
n=1;
suma=0
for n=1:1:1000
Nikkei_(1,n)
suma=Nikkei_(1,n)+suma;
norminv3=1-suma
n=n+1;
end
im stuck , i have no idea how to solve this, could someone enligten me ?
thanks in advance !
  댓글 수: 10
Adam Danz
Adam Danz 2021년 4월 7일
Well, n must be greater than 1.

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

답변 (1개)

Adam Danz
Adam Danz 2021년 4월 7일
Change Treasury_(1,n)
To Treasury_(n,1)

카테고리

Help CenterFile Exchange에서 Data Preprocessing에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by