Search found 563 matches

by EViews Matt
Wed Apr 11, 2018 3:07 pm
Forum: Estimation
Topic: Generate a sum vector
Replies: 1
Views: 2322

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 ...
by EViews Matt
Wed Apr 11, 2018 11:58 am
Forum: Estimation
Topic: Concept of SSR of a VAR
Replies: 3
Views: 3304

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.
by EViews Matt
Mon Apr 09, 2018 9:22 am
Forum: Estimation
Topic: Concept of SSR of a VAR
Replies: 3
Views: 3304

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"?
by EViews Matt
Fri Apr 06, 2018 8:48 am
Forum: Estimation
Topic: Save Var results in a scalar, matrix,etc.
Replies: 8
Views: 5346

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

Something like this...

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.
by EViews Matt
Thu Apr 05, 2018 3:59 pm
Forum: Estimation
Topic: Long run restrictions for a structural VAR
Replies: 13
Views: 14842

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 ...
by EViews Matt
Thu Apr 05, 2018 3:30 pm
Forum: Estimation
Topic: Save Var results in a scalar, matrix,etc.
Replies: 8
Views: 5346

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)
by EViews Matt
Thu Apr 05, 2018 2:56 pm
Forum: Estimation
Topic: Save Var results in a scalar, matrix,etc.
Replies: 8
Views: 5346

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.
by EViews Matt
Thu Apr 05, 2018 1:59 pm
Forum: Estimation
Topic: Save Var results in a scalar, matrix,etc.
Replies: 8
Views: 5346

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.
by EViews Matt
Wed Apr 04, 2018 9:08 am
Forum: Estimation
Topic: Long run restrictions for a structural VAR
Replies: 13
Views: 14842

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...
by EViews Matt
Mon Apr 02, 2018 8:54 am
Forum: Estimation
Topic: Long run restrictions for a structural VAR
Replies: 13
Views: 14842

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...
by EViews Matt
Thu Mar 29, 2018 10:46 am
Forum: Programming
Topic: Changing variable names in several equations
Replies: 34
Views: 24236

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
by EViews Matt
Wed Mar 28, 2018 3:26 pm
Forum: Programming
Topic: Changing variable names in several equations
Replies: 34
Views: 24236

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.
by EViews Matt
Wed Mar 28, 2018 2:40 pm
Forum: Programming
Topic: Changing variable names in several equations
Replies: 34
Views: 24236

Re: Changing variable names in several equations

Just use "@date" instead of "@date(res{%eq})". You generate dates based on the workfile sample and frequency, not on a specific series. The "(res{%eq})" term shifts the dates by the amount of the first residual, which you observed.
by EViews Matt
Tue Mar 27, 2018 9:22 am
Forum: Programming
Topic: Find rows of matrix containing na values
Replies: 10
Views: 7351

Re: Find rows of matrix containing na values

Here's a more general, EViews 9.5-friendly solution that (1) doesn't require all the NAs to be in the same column, and (2) preserves the order of the non-NA-containing rows. This solution constructs a new matrix as the result rather than modifying the original matrix. matrix(1,m.@cols) m2 for !i = 1...
by EViews Matt
Mon Mar 26, 2018 10:07 am
Forum: Programming
Topic: Help in changing my codes from series to matrix
Replies: 32
Views: 18424

Re: Help in changing my codes from series to matrix

That's almost certainly due to the lag dependence in the signal, i.e., for the first observation in your sample {%sig}(-1) is NA, which propagates to later observations until you get to a case number that doesn't depend on {%sig}(-1), such as case number 9 in the example you posted. In the statement...

Go to advanced search