Value Maps

For questions regarding programming in the EViews programming language.

Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt

Redwing153
Posts: 30
Joined: Sat May 30, 2015 5:10 am

Value Maps

Postby Redwing153 » Sat Aug 22, 2015 4:28 am

Hello
I find Value Maps very useful, but I am wondering is there a way to create a value map from two alpha series;
In a similar manner one can create a string object=@wjoin(@convert(seriesname)) - can one do something similar with value maps?

Many thanks all.

RW

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13583
Joined: Tue Sep 16, 2008 5:38 pm

Re: Value Maps

Postby EViews Gareth » Sat Aug 22, 2015 1:06 pm

Look up alpha.makemap in the Alpha section of Chapter 1 of the Object Reference PDF (available from Help menu).

Redwing153
Posts: 30
Joined: Sat May 30, 2015 5:10 am

Re: Value Maps

Postby Redwing153 » Sat Aug 22, 2015 3:14 pm

Thanks. I have investigated that already and (unless I'm missing something, which is entirely possible) it won't allow to make many to one mappings.
In addition, I'm always stuck with an observation number on the left hand side, whereas I want the left hand side to be one of my series.
What would be ideal (or rather easy) would be a program routine that enables me to copy and paste into a valmap, which is currently the way I am trying to solve it.

Thanks anyway.

RW

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13583
Joined: Tue Sep 16, 2008 5:38 pm

Re: Value Maps

Postby EViews Gareth » Sat Aug 22, 2015 3:42 pm

I'm a little lost as to what you're trying to do then. What do you mean by create a value map out of two alpha series?

Redwing153
Posts: 30
Joined: Sat May 30, 2015 5:10 am

Re: Value Maps

Postby Redwing153 » Sun Aug 23, 2015 6:17 am

Thanks.
So both the value and label in my value map will be text ; the text in both cases is generated from an alpha series, which is separately maintained.
This program is close to what I want, but I've had to substitute hyphens into the text (the text contains a number of 'int' elements) as the string is space delimited.

Code: Select all

for !i=1 to 25 smpl {!i} {!i} string1=@wdelim(@last(ticker)," ","-") string2=@wdelim(@last(region)," ","-") mymap.append {series1} {series2} next
Thanks.

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13583
Joined: Tue Sep 16, 2008 5:38 pm

Re: Value Maps

Postby EViews Gareth » Sun Aug 23, 2015 8:53 am

I see. I don't think you can make that happen.


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 2 guests