[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
st: simple method to identify string variables?
Dear Statalisters,
Is there a simple way to identify string variables using an if
statement? As an obviously contrived example, suppose I wanted to use
the -mean- command for all numeric variables. I would get this error
message:
. sysuse auto,clear
. mean _all
varlist: make: string variable not allowed
r(109);
Can I limit the command to numeric variables only? I suspect there is
an easy, even obvious solution, but I can't find it anywhere.
Thanks,
David
--
David Radwin, Principal Analyst // [email protected]
Office of Student Research, University of California, Berkeley
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/