--- Ashim Kapoor <[email protected]> wrote:
> Maybe I should say why I am asking this. It just seems like STRANGE
> to me that the person who programmed stata to work the way it does
> INTENTIONALLY allows us to do :-
>
> egen x=max(y)
>
> but does not allow us to do
>
> local x=max(y).
>
> It just seems counterintuitive and a waste of memory. Seems unlikely
> that the guy who programmed this did not think of this. That is why I
> think that I am missing something.
That is because -egen- subcommand -max()- has a different syntax than
the -max()- function (see -help max-). Fuctions are much more general
animals than -egen- subcommands in that they can be directly applied in
a variety circumstances, like defining a macro, while -egen- can only
be used for creating a variable. (see -help function-, the User's guide
section 13.3, and -help egen-)
-- Maarten
-----------------------------------------
Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands
visiting address:
Buitenveldertselaan 3 (Metropolitan), room N515
+31 20 5986715
http://home.fsw.vu.nl/m.buis/
-----------------------------------------
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/