Page 1 of 1

String with dates

Posted: Thu Aug 11, 2016 4:02 am
by tvonbrasch
Hi

I want to generate a string with the dates when a variable has NA values

If I write

Code: Select all

smpl="2000q1 2010q4 if avvik=na")
I get the sample when avvik is NA. But how can I get the dates of all the NA observations? Frr example, if avvik equals NA in 2000q1 and 2003q4, i want a string with those dates, i.e., "2000q1 2003q4".
Thomas

Re: String with dates

Posted: Thu Aug 11, 2016 6:41 am
by EViews Gareth
Use a loop with the @otods function and @datestr functions

Re: String with dates

Posted: Fri Aug 12, 2016 12:02 am
by tvonbrasch
Perfect, thanks
T