Frequency conversion

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Jason, EViews Steve, EViews Moderator

tvonbrasch
Posts: 540
Joined: Fri Apr 15, 2011 5:35 am

Frequency conversion

Postby tvonbrasch » Tue Aug 15, 2017 11:21 pm

Hi

Frequency conversion:

I have a dataseries for NOK/EURO exchange rate looking something like this (see attachment):

7/02/2000 8.058999999999999
8/02/2000 8.071999999999999
9/02/2000 8.0825
10/02/2000 8.0695
11/02/2000 8.0395
12/02/2000
13/02/2000
14/02/2000 8.0795
15/02/2000 8.0685
16/02/2000 8.112500000000001
17/02/2000 8.1565
18/02/2000 8.1455
19/02/2000
20/02/2000

that is, a daily frequency with alot of NA values. When converting to anual frequency, i want to take the average of the non-NA values, i.e., i use the command:

Code: Select all

euro.setconvert a
.

However, I do not want the annual series to show a value for 2017. Correspondingly, I do not want the quarterly series showing a value for 2017:q3.

In general, when using frequency conversion, how can I make it so that a series will show NA in the period (quarter, month, year) belonging to the current date?
Thomas
Attachments
euro.WF1
(11.65 KiB) Downloaded 219 times

EViews Matt
EViews Developer
Posts: 557
Joined: Thu Apr 25, 2013 7:48 pm

Re: Frequency conversion

Postby EViews Matt » Wed Aug 16, 2017 1:22 pm

Hello,

I don't think you can accomplish what you want with linked data that contains NAs. With non-linked data, it's trivial to overwrite the last observation after the frequency conversion, e.g.:

Code: Select all

euro(@obsrange) = na

Code: Select all

smpl @last @last
euro = na

Code: Select all

smpl if @after(@datestr(@now))
euro = na

The last example has the advantage that if the last observation doesn't include the current date, the series won't be modified (if that's a possibility for your data).

tvonbrasch
Posts: 540
Joined: Fri Apr 15, 2011 5:35 am

Re: Frequency conversion

Postby tvonbrasch » Wed Aug 16, 2017 10:30 pm

great, thanks for showing many different ways of doing this!

yes, that is a possibility with the other data I have, so i will go for the last option you provided
Thomas

tvonbrasch
Posts: 540
Joined: Fri Apr 15, 2011 5:35 am

Re: Frequency conversion

Postby tvonbrasch » Wed Oct 18, 2017 1:32 am

Hi

Can you make it so that also linked variables can be converted to another frequency in this manner in a future release? I.e. it should be an option so that linked series show NA if time equals @after(@datestr(@now)) when copied to other frequencies


Thomas


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 9 guests