Hello,
I am Eviews7 user.
I would like to create a matrix(7,3) from the extraction of 3 vector columns from different other matrixs.
One of this 3 vector columns should contain the serie (or variable) names of a group.
As serie names are string, how can I create a vector contaning these string names?
(Later, this should allow me to identify the corresponding (vlookup) variable name for an identified value).
...
group groupC {%jres} groupA
for !k =1 to groupC.@count
!lmk=groupC.@count
%kname = groupC.@seriesname(!k)
vector (!lmk) varnames
varnames(!k) = %kname
etc..
matrix(!lkm,3) matcorprob
colplace(matcorprob, vcorabs,1)
colplace(matcorprob,vcorprob,2)
colplace(matcorprob,varnames,3)
How to create a vector containing series name?
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13603
- Joined: Tue Sep 16, 2008 5:38 pm
Re: How to create a vector containing series name?
Vectors and matrices can only contain numerical data, not strings. You can use an svector to contain strings rather than numbers. However you cannot place an svector inside a matrix using the colplace command (since matrices cannot contain strings).
Re: How to create a vector containing series name?
Thanks for your answer.
Therefore, the only way is to use numerical serie names instead of string serie name i.e. X1 to Xn into 1 to n, or is there an another way?
Therefore, the only way is to use numerical serie names instead of string serie name i.e. X1 to Xn into 1 to n, or is there an another way?
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13603
- Joined: Tue Sep 16, 2008 5:38 pm
How to create a vector containing series name?
I'm not certain I follow what you're doing. You might prefer to use a table object.
Who is online
Users browsing this forum: No registered users and 2 guests
