Finding max and min of scalar objects
Posted: Wed Oct 29, 2014 8:51 am
Is there an EViews function that will find the max/min/etc of a set of scalar values? The @max command is only valid for series objects. I can think of roundabout ways to do this (copy all scalars to a series and then use @max or use a bunch of indicator functions) but I wanted to know if this feature was already available.
Also, a general question -- if I can't find a function, is there a way I can program my own function, such as @maxnum(scalar1, scalar2, ...), and then call that from the command window or within any command file I write? Not by using a subroutine or creating a separate .prg file but embed it inside of my copy of EViews?
Here is an example of how I intend to use this:
Thanks
Also, a general question -- if I can't find a function, is there a way I can program my own function, such as @maxnum(scalar1, scalar2, ...), and then call that from the command window or within any command file I write? Not by using a subroutine or creating a separate .prg file but embed it inside of my copy of EViews?
Here is an example of how I intend to use this:
Code: Select all
!scalar1 = 10 ' a scalar object determined previously in the code
!scalar2 = 20 ' a scalar object determined previously in the code
for !i = @maxnum(5,!scalar1) to @minnum(15,!scalar2)
...