필터 지우기
필터 지우기

problem with Boolinger Band

조회 수: 5 (최근 30일)
Luca Re
Luca Re 2023년 9월 25일
편집: Voss 2023년 9월 25일
>> Data=1:500;
>> bollinger(Data)
Error using bollinger
Expected Window size to be a scalar with value <= 1.

채택된 답변

Voss
Voss 2023년 9월 25일
편집: Voss 2023년 9월 25일
Note the documentation of bollinger input argument Data:
Data for market prices, specified as a matrix, table, or timetable. For matrix input, Data must be column-oriented.
This means that bollinger is expecting one or more columns of data. You've given a row vector, so transpose (.') it:
Data=1:500;
[middle,upper,lower] = bollinger(Data.');
plot(Data)
hold on
plot(middle,'--')
plot(upper,'--')
plot(lower,'--')

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Stochastic Differential Equation (SDE) Models에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by