Hello,

Are you asking about how you should restrict those matrices? There is no one correct way to do so, the restrictions are part of the assumptions of your model. It's up to you to specify how you believe the variables in your model are related to one another.

## Search found 221 matches

- Mon Apr 16, 2018 9:03 am
- Forum: Estimation
- Topic: Long run restrictions for a structural VAR
- Replies:
**7** - Views:
**237**

- Thu Apr 12, 2018 3:37 pm
- Forum: Programming
- Topic: Loop for find a minimun
- Replies:
**3** - Views:
**124**

### Re: Loop for find a minimun

Sure, you can add them to your string of groups. Let the for loop do the work of adding the twenty new names... string grps = "h dev fixed flex open closed" for !x = 10 to 100 step 10 series hdebt_!x = debt > !x series ldebt_!x = debt < !x grps = grps + " hdebt_" + @str(!x) + &qu...

- Thu Apr 12, 2018 12:59 pm
- Forum: Programming
- Topic: Loop for find a minimun
- Replies:
**3** - Views:
**124**

### Re: Loop for find a minimun

Hello,

It sounds like you're trying to create a pair of dummy variables. You can do that directly without setting a sample.

It sounds like you're trying to create a pair of dummy variables. You can do that directly without setting a sample.

Code: Select all

`for !x = 10 to 100 step 10`

series hdebt_!x = debt > !x

series ldebt_!x = debt < !x

next

- Wed Apr 11, 2018 3:07 pm
- Forum: Estimation
- Topic: Generate a sum vector
- Replies:
**1** - Views:
**65**

### Re: Generate a sum vector

Hello, vector ssrt_debt = sum_ssr_ldebt + sum_ssr_hdebt That said, if your sum_ssr_{%c} vectors are only ever going to hold one element, use scalars instead of vectors. And there's no point to calculating sum_ssr_{%c} until after you've finished calculating ssr_{%c}, i.e., move that statement after ...

- Wed Apr 11, 2018 11:58 am
- Forum: Estimation
- Topic: Concept of SSR of a VAR
- Replies:
**3** - Views:
**155**

### Re: Concept of SSR of a VAR

What I'm hinting at is that there are other available metrics for selecting the "best" VAR. If you look at the bottom of a VAR's estimation output you'll find a variety of summary statistics for the VAR as a whole.

- Mon Apr 09, 2018 9:22 am
- Forum: Estimation
- Topic: Concept of SSR of a VAR
- Replies:
**3** - Views:
**155**

### Re: Concept of SSR of a VAR

Hello,

The real question is, what are you trying to quantify through a "total SSR of the VAR"?

The real question is, what are you trying to quantify through a "total SSR of the VAR"?

- Fri Apr 06, 2018 8:48 am
- Forum: Estimation
- Topic: Save Var results in a scalar, matrix,etc.
- Replies:
**8** - Views:
**227**

### Re: Save Var results in a scalar, matrix,etc.

Something like this...

The minimum SSRs are stored in vector min_ssr.

Code: Select all

`!m = 1`

for !i = 1 to <fill in n>

!k = 1

for !j = 1 to var_!i.@neqn

vector(!k) ssr(!k) = var_!i.@ssr(!j)

!k = !k + 1

next

!tmp = @mins(ssr, 1)

vector(!m) min_ssr(!m) = !tmp

!m = !m + 1

next

The minimum SSRs are stored in vector min_ssr.

- Thu Apr 05, 2018 3:59 pm
- Forum: Estimation
- Topic: Long run restrictions for a structural VAR
- Replies:
**7** - Views:
**237**

### Re: Long run restrictions for a structural VAR

Those "restriction presets" are just simple, common sets of restrictions that can be customized further. You're not limited by those presets, e.g., the F matrix doesn't need to be triangular. The new error message you're receiving could be caused by many things, such as bad initial values ...

- Thu Apr 05, 2018 3:30 pm
- Forum: Estimation
- Topic: Save Var results in a scalar, matrix,etc.
- Replies:
**8** - Views:
**227**

### Re: Save Var results in a scalar, matrix,etc.

Sure, a few loops can easily go through any number of VARs you wish with any number of equations per VAR:

Code: Select all

`!k = 1`

for %v var1 var2

for !i = 1 to {%v}.@neqn

vector(!k) ssr(!k) = {%v}.@ssr(!i)

!k = !k + 1

next

next

scalar min_ssr = @mins(ssr, 1)

- Thu Apr 05, 2018 2:56 pm
- Forum: Estimation
- Topic: Save Var results in a scalar, matrix,etc.
- Replies:
**8** - Views:
**227**

### Re: Save Var results in a scalar, matrix,etc.

You need to specify which VAR equation's SSR you want, e.g., @ssr(1), @ssr(2), etc.

- Thu Apr 05, 2018 1:59 pm
- Forum: Estimation
- Topic: Save Var results in a scalar, matrix,etc.
- Replies:
**8** - Views:
**227**

### Re: Save Var results in a scalar, matrix,etc.

Hello,

Take a look at the VAR object documentation. I believe the @ssr data member is what you're looking for.

Take a look at the VAR object documentation. I believe the @ssr data member is what you're looking for.

- Wed Apr 04, 2018 9:08 am
- Forum: Estimation
- Topic: Long run restrictions for a structural VAR
- Replies:
**7** - Views:
**237**

### Re: Long run restrictions for a structural VAR

Lets start with the initial value issue, since that's easy to fix (if it's the cause of your difficulty). When estimating an SVAR, EViews uses an initial value of .1 for all estimates by default. If you open your VAR, go to Proc -> Estimate Structural Factorization, and switch to the Optimization Co...

- Mon Apr 02, 2018 8:54 am
- Forum: Estimation
- Topic: Long run restrictions for a structural VAR
- Replies:
**7** - Views:
**237**

### Re: Long run restrictions for a structural VAR

Hello, There's no implicit restriction form on the long-run matrix, you can restrict any element(s) you wish as long as you completely identify the system. That error can occur when, for example, the choice of initial values for the estimation happens to produce a singular matrix or other numericall...

- Thu Mar 29, 2018 10:46 am
- Forum: Programming
- Topic: Changing variable names in several equations
- Replies:
**28** - Views:
**856**

### Re: Changing variable names in several equations

I believe what you're after is:

Code: Select all

`if @abs(@last(res{%eq})) > {%eq}.@se then`

%estcmd = {%eq}.@command + "@event(" + res{%eq}.@last + ")"

endif

- Wed Mar 28, 2018 3:26 pm
- Forum: Programming
- Topic: Changing variable names in several equations
- Replies:
**28** - Views:
**856**

### Re: Changing variable names in several equations

*x*.@last will return the date (as a string) of the last non-NA observation in series

*x*.