FAVAR add-in

For questions about EViews Add-ins available from the EViews Add-ins webpage. Note each add-in available on our webpage will have its own individual thread.

Moderators: EViews Gareth, EViews Moderator, EViews Esther

heer0
Posts: 22
Joined: Sat May 04, 2019 11:23 am

Re: FAVAR add-in

Postby heer0 » Thu Aug 15, 2019 1:11 pm

daisysunf18 wrote:Hi,I am confuse the impulse variable (optional)what should I choose , I do not see it in favar.package. thanks in advance.


The impulse command is thought to depcify the impulse in case of multiple schock variables. If you only include one shock variable in your model, this command is redundant.

Hope it helps.

daisysunf18
Posts: 3
Joined: Thu Aug 01, 2019 4:27 am

Re: FAVAR add-in

Postby daisysunf18 » Sun Aug 18, 2019 1:04 am

HI,I have another problem, I am doing an impulse response comparison chart. I use the same impulse variable ,same setting like number of lag、factor 、XDATA、XSLOW ,but different main variables(xir),At last,I have the same impluse response diagram,What is the cause of this? thanks in advance :D

MG17
Posts: 4
Joined: Tue Sep 17, 2019 3:20 am

Re: FAVAR add-in

Postby MG17 » Tue Oct 01, 2019 6:08 am

Hi everyone,

I recently started working with EViews and I really wanna express my gratitude to dakila for providing the FAVAR add-in to us and moderating this thread with helpful support.

After running the FAVAR add-in with my own dataset I came across a point that kind of surprised me. I crosschecked the FAVAR example file and found the same (potential?) issue again. Hopefully it is just me having a false understanding of the FAVAR theory, so I would really appreciate some feedback from you guys here or even from you dakila.

The point I wanna talk about relates to the irf matrix (“irfxmat”) that gets saved in the workfile when you add “save=1” to the favar command. In the standard specification of the example file the first entries in the irf matrix are always different from zero. Some are very small, yes, but they are never equal to zero. But shouldn’t the impulse responses of the slow moving variables (in the example file series16, 108, 17, 49, 50, 51, 26, 48, 118) by definition be unaffected by a shock in the federal funds rate in the first period? The irf graphs of the respective series do not start in zero but somewhere slightly above or below accordingly. I mean, the whole differentiation between slow and fast moving variables implies that the slow variables do not immediately react to shocks in the faster ones within the first period. That’s why they are slow right?

I found an EViews FAVAR tutorial by the Bank of England (https://cmi.comesa.int/wp-content/uploads/2016/03/Ole-Rummel-13-Feb-Exercise-on-factor-augmented-VARs-EMF-EAC-9-13-February-2015.pdf) and this tutorial ends up with an irf matrix in which the first entries of all slow moving variables are precisely equal to zero. To me this makes sense.

I really hope that someone out here or maybe even dakila himself could state his or her opinion on this topic. Any help would be very much appreciated.

Thanks in advance and best regards

Markus

dakila
Posts: 479
Joined: Tue Nov 24, 2015 4:57 pm

Re: FAVAR add-in

Postby dakila » Tue Oct 08, 2019 6:43 am

Hi Markus,

Here the slow and fast variables matter for recovering common components, F other than R.
In order to estimate common components F, we removes direct dependences of C(F,R) on R:
1. Estimate principal components, C(F, R) from entire dataset
2. Estimate C(F*) extracting principal components from slow moving variables
3. Run regression : C(F,R) = b1*C(F*) + b2*R
4. F = C(F,R) -b2*R

MG17
Posts: 4
Joined: Tue Sep 17, 2019 3:20 am

Re: FAVAR add-in

Postby MG17 » Thu Oct 31, 2019 3:56 am

Hi Dakila,

thank you very much for your response.

What you just described is basically the factor rotation that ensures that the factors are indipendent from R. I agree that this is the situation in the FAVAR modeling where the differentiation between slow- and fast-moving matters. However, this is not directly related to the issue I described in my original question.

Let me describe the topic a little bit more detailed (I follow the BBE2005 scenario where they use three factors next to Y_{t} / R in your description):

After the factor rotation we end up with three (rotated) factors. The rotated factors are F_{t}^{hat} in BBE2005. Next, they estimate their equation (1) (transition equation) with F_{t}^{hat} replacing F_{t}. Calculating the impulse responses of the three factors and the policy rate, we end up with IRFs starting with zeros for the three factors (as expected, as they are ordered before the policy rate in the cholesky ordering) and an IRF for the policy rate that starts above zero. In other words: We have a matrix of IRFs with four columns (shock of policy rate on factor one, two, three and on itself) and rows equal to the IRF horizon (BBE use h=48). The first entries of the first three columns are exactly zero as the factors aren't contemporenously affected by a shock in the policy rate.

Next, we use this 48x4 IRF matrix (with IRF(1,1)=0; IRF(1,2)=0; IRF(1,3)=0; IRF(1,4)<>0) to calculate the IRFs of selected variables in the large dataset (X_{t} in BBE2005). Therefore, we multiply this matrix with the (transposed) respective loadings matrix (Lambda^{f} and Lambda^{y} in BBE2005, 120x4). The loadings matrix is supposed to have zeros in the 4th column for all slow moving variables as there is no contemporaneous effect of the policy rate shock on those variables. Ultimately, we end up with a 48x120 matrix of the impulse responses of all variables in X_{t}. By definition, the first entry in each column is supposed to be zero for the slow-moving variables and different from zero for the slow moving variables. That is what I meant when I referred to the point that - at least from my point of view - irfs of slow moving variables should always start with zero.

The example file generates an irf matrix where the unemployment rate (slow-moving) starts with an initial value of -0.005 (see appended image). How is this possible? Or do you disagree with my argumentation? I would really appreciate some feedback.

Thank you very much in advance and best regards
Markus
Attachments
Unemployment.png
Unemployment.png (87.36 KiB) Viewed 223290 times

dakila
Posts: 479
Joined: Tue Nov 24, 2015 4:57 pm

Re: FAVAR add-in

Postby dakila » Sat Nov 02, 2019 10:39 am

Hi Markus,

The loadings matrix is supposed to have zeros in the 4th column for all slow moving variables as there is no contemporaneous effect of the policy rate shock on those variables.


I think that assumption is questionable. The slow and fast moving variables matter for the factor rotation not for the impulse response functions.

MG17
Posts: 4
Joined: Tue Sep 17, 2019 3:20 am

Re: FAVAR add-in

Postby MG17 » Mon Nov 04, 2019 4:29 am

Hi Dakila,

thanks again for your feedback. I really appreciate the option to get some feedback from you.

Let me shortly cite BBE2005 (p. 404):
In particular, we define two categories of information variables: "slow-moving" and "fast-moving." Slow moving variables (think of wages or spending) are assumed not to respond contemporaneously to unanticipated changes in monetary policy. In contrast, fast-moving variables (think of asset prices) are allowed to respond contemporaneously to policy shocks.


From my perspective, the underlined definition of slow-moving variables is exactly a description of the impulse response behaviour of those variables, namely that they are not supposed to react to an unanticipated shock in the policy rate within the same period. Therefore, I believe that the IRFs of those variables, should - by definition - start with zero. That is how I interpret BEE's statement.

To give an example: Blake, Mumtaz and Rummel ensure this in their FAVAR EViews Tutorial by estimation the observation equation (2) both without the policy rate (for slow-moving variables) and with the policy rate (for fast-moving variables) --> see step 9 right here:
https://cmi.comesa.int/wp-content/uploads/2016/03/Ole-Rummel-13-Feb-Exercise-on-factor-augmented-VARs-EMF-EAC-9-13-February-2015.pdf

The alternative option would be to estimate the observation equation in a single step without taking the differentiation between slow- and fast-moving variables into account. Then, we receive loadings unequal to zero for the policy rate and, consequently, IRFs of slow-moving variables that start above or below zero. Technically, those two options are quite familiar, however, I stongly believe that only the one I mentioned first leads to the shock behaviour BBE mentioned in the statement above.

Why do you think that the assumtion regarding the loading matrix is debatable?

Again, thank you very much in advance for your feedback.

Best regards
Markus

MG17
Posts: 4
Joined: Tue Sep 17, 2019 3:20 am

Re: FAVAR add-in

Postby MG17 » Tue Nov 05, 2019 2:32 am

Hi Dakila,

I just came across a handbook by Andrew Blake and Haroon Mumtaz (https://www.bankofengland.co.uk/ccbs/applied-bayesian-econometrics-for-central-bankers-updated-2017) that supports my argumentation regarding the zeros in the loadings matrix for slow-moving variables:

Observation equation.PNG
Observation equation.PNG (50.02 KiB) Viewed 223222 times


Mumtaz.PNG
Mumtaz.PNG (70.95 KiB) Viewed 223222 times


Mumtaz2.PNG
Mumtaz2.PNG (36.81 KiB) Viewed 223222 times

This procedure ensures zeros in the fourth column of the loadings matrix.

I hope this enriches our further discussion.

Best regards
Markus

dakila
Posts: 479
Joined: Tue Nov 24, 2015 4:57 pm

Re: FAVAR add-in

Postby dakila » Thu Nov 07, 2019 7:44 pm

If lambda_y equal to zero for the slow-moving variables then you will miss not just the impact period but all period effects of FFR (federal funds rate). That does not make sense.

oscargomez
Posts: 1
Joined: Thu Feb 18, 2021 2:31 pm

Re: FAVAR add-in

Postby oscargomez » Thu Feb 18, 2021 3:01 pm

Hi everyone,
First of all, I want to express my gratitude for the add-in, its very usefull.

I have a question: when I run my FAVAR I got serial correlation in the error, so to correct that I have to take just some lags (the ones statistical significative), not from 1 to 12. For example, I need to take from 1 to 6, then from 8 to 10 and so on.

In the space for lags I wroted like this: 1 6 8 10. From 1 to 6, then from 8 to 10. But I got the error: !NLAG is not defined or is an illegal command. So I wanna know if its there another way to write it, or the way the add in is programmed only allows one number in lags.

Thanks.

dakila
Posts: 479
Joined: Tue Nov 24, 2015 4:57 pm

Re: FAVAR add-in

Postby dakila » Sat Feb 20, 2021 6:31 pm

That is not possible for this version. I will try to include it to the next version.

muratakkaya
Posts: 1
Joined: Tue May 11, 2021 4:12 am

Re: FAVAR add-in

Postby muratakkaya » Fri May 14, 2021 5:01 am

Hi Eviews users

I want to use FAVAR in finance studies.

I saw your comments on forum. I downloaded FAVAR addins. But I don't know hot to fill the box. Also I need file (favar_ex.prg) and information about favar box

I will be grateful

Thanks in advance

yasu
Posts: 2
Joined: Tue Nov 22, 2022 2:59 am

Re: FAVAR add-in

Postby yasu » Thu Mar 16, 2023 8:42 pm

Hi dakila,
I use FAVAR add-in in EViews10.
Thank you so much for your great add-inn.

I want to estimate IRF of FAVAR model including two observables-mb and call.
(mb denotes monetary base. call denotes policy interest in Japan).

I write the following program.

favar( factor=6, horizon=60, rep=1000, ci=0.9 ) 3 xdata xslow northy ncode northy_name @ call mb

However, the result probably only presents the IRF for mb shock.

Please teach me how to get both IRFs to mb and call shocks.

Thank you very much.

dakila
Posts: 479
Joined: Tue Nov 24, 2015 4:57 pm

Re: FAVAR add-in

Postby dakila » Sun Mar 19, 2023 5:18 pm

Hi Yasu,

use the following code for call shock:
favar( factor=6, horizon=60, rep=1000, ci=0.9 ,impulse=call) 3 xdata xslow northy ncode northy_name @ call mb

or use the dialog interface (impulse variable (optional) box).

yasu
Posts: 2
Joined: Tue Nov 22, 2022 2:59 am

Re: FAVAR add-in

Postby yasu » Sun Mar 19, 2023 7:49 pm

Hi dakila,

Thank you for your fast replay.

I runed your code immediately. However, Eviews 10 presents the following error message.
(your code:favar( factor=6, horizon=60, rep=1000, ci=0.9 ,impulse=call) 3 xdata xslow northy ncode northy_name @ call mb)

"sss already exists and is a different type"

My code includes both of call and mb in "northy_name" in the following.

northy_name.append call
northy_name.append mb
northy_name.append y1
northy_name.append y2
northy_name.append y3
northy_name.append y4
northy_name.append y5
northy_name.append y6
northy_name.append y7

Also I written ncode as "vector ncode=@fill(1,1,1,1,1,1,1,1).
(Namely vector of ncode include nine variables)


Are these wrong codes?

Please teach me.

Thank you very much.


Return to “Add-in Support”

Who is online

Users browsing this forum: No registered users and 6 guests