Page 1 of 1

Minimum function

Posted: Tue Jun 03, 2014 7:40 am
by memos
I am solving a model for a panel series which is a share variable, and I want to make sure that the values are less than 100. I couldn't figure out how to use the minimum function in a proper way.

for !obs = @dtoo("2014M02") to @dtoo("2015M12")
smpl 1997M01+!obs-1 1997M01+!obs-1
AAPAgnShr.genr agnshr_? = @min(agnshr_?_0,100)
next

I want to set agnshr_? pooled series to be equal to the minimum of agnshr_?_0 and 100 for each observation after Feb 2014.

Re: Minimum function

Posted: Tue Jun 03, 2014 7:49 am
by EViews Gareth

Code: Select all

agnshr_? = @recode(agnshr_?_0 > 100,100, agnshr_?_0)

Re: Minimum function

Posted: Tue Jun 03, 2014 8:02 am
by memos
Thanks.