using"filter" - error message for inputs 'Y0'

Hello,
I am using the function filter to estimate portfolio returns. I get the following message when the code has to execute the function filter:
" 'Y0' is not a recognized parameter. For a list of valid name-value pair arguments, see the documentation for this function."
the code is the following:
portfolioReturns = filter(fit, bootstrappedResiduals,'V0', preSigma, 'Y0', preReturn, 'Z0', preResidual);
I have estimated a garch model with "estimate" at the beginning of the code.
Why do I get this type of error if in the documentation the input 'Y0' is reported. If I remove that input, all else equal, I get no error.
Any help?
Thanks

5 件のコメント

Robert Fennis
Robert Fennis 2016 年 7 月 12 日
Try changing the code like this:
[A, B, C] = filter(fit, bootstrappedResiduals,'V0', preSigma, 'Y0', preReturn, 'Z0', preResidual);
I believe matlab doesn't understand which filter function it ought to use because of the variable you are putting it it.
Sandro Bianchini
Sandro Bianchini 2016 年 7 月 13 日
Hello Robert,
thanks for your reply. I have tried what you have suggested, writing the code as the following one :
[~, ~, portfolioReturns] = filter(fit, bootstrappedResiduals,'V0', preSigma, 'Y0', preReturn, 'Z0', preResidual);
but it gives me an error of "Too many output arguments" .
If I remove one output "~,", it gives the same error "'Y0' is not a recognized parameter. For a list of valid name-value pair arguments, see the documentation for this function."
Adam
Adam 2016 年 7 月 13 日
Which 'filter' function are you trying to use here?
I don't see anywhere in
doc filter
where 'Y0' is a valid argument though maybe I am just missing it.
Sandro Bianchini
Sandro Bianchini 2016 年 7 月 13 日
If you scroll down to this page you can see that filter takes also 'Y0' as input.
The code used in the linked page is what I am trying to reply.
Adam
Adam 2016 年 7 月 13 日
編集済み: Adam 2016 年 7 月 13 日
Looking at the help page of the actual function:
'Y0' is not listed as a valid argument so I assume the example you are looking at is outdated.
I don't have the Econometrics Toolbox myself so I can't really judge any further what is going on beyond that.

サインインしてコメントする。

回答 (2 件)

Hang Qian
Hang Qian 2016 年 8 月 19 日

0 投票

The filter method of GARCH does have a name-value pair Y0. The demo runs smoothly on my computer. If it generates that error, I guess that the FILTER function might be altered, say someone wants to customize the codes and overloads the internal function.
- Hang Qian
Walter Roberson
Walter Roberson 2016 年 8 月 19 日

0 投票

The filter method of GARCH does not have a name-value pair for Y0. The filter method of arima does have a name-value pair for Y0

1 件のコメント

Hang Qian
Hang Qian 2016 年 8 月 19 日
Oh yes, you are right. The model constructed in the demo is an ARIMA model with an EGARCH variance. So it has the name-value pair Y0. It should work in all versions of MATLAB as long as ARIMA functionalities were born.

サインインしてコメントする。

質問済み:

2016 年 7 月 12 日

コメント済み:

2016 年 8 月 19 日

Community Treasure Hunt

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

Start Hunting!

Translated by