@datediff between quarter end

For questions regarding programming in the EViews programming language.

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

bcchen
Posts: 31
Joined: Tue May 02, 2017 8:34 am

@datediff between quarter end

Postby bcchen » Wed Apr 10, 2019 3:03 pm

Hi Eviews fellows,

I was trying to calculate quarter difference between some quarter end dates and found something weird:


=@datediff(@dateval("2011-09-30"),@datefloor(@dateval("2011-06-30"),"Q"),"Q")
the result is 1;

=@datediff(@dateval("2011-06-30"),@datefloor(@dateval("2011-03-31"),"Q"),"Q")
the result is 0.

I thought the second one should return 1 as well?

Please help.
BC

bcchen
Posts: 31
Joined: Tue May 02, 2017 8:34 am

Re: @datediff between quarter end

Postby bcchen » Wed Apr 10, 2019 3:03 pm

I am using EVIEWS 9.5

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

Re: @datediff between quarter end

Postby EViews Matt » Wed Apr 10, 2019 3:55 pm

Hello,

Both of those expressions evaluate to 1 for me. Is your copy of EViews 9.5 up to date? Nov 1, 2018 is the most recent patch.


Return to “Programming”

Who is online

Users browsing this forum: Google [Bot] and 29 guests