Dear Stata users,
I want to get a series of varlist name in my task. So I resort to -describe- in order to get return of r(varlist). However in practice, it seems that -describe- dose not provide such a return. Hope someone can help me, thank you very much.
Here are what I cited from help file of -describe-:
I want to get a series of varlist name in my task. So I resort to -describe- in order to get return of r(varlist). However in practice, it seems that -describe- dose not provide such a return. Hope someone can help me, thank you very much.
Here are what I cited from help file of -describe-:
describe stores the following in r():
Scalars
r(N) number of observations
r(k) number of variables
r(width) width of dataset
r(changed) flag indicating data have changed since last saved
Macros
r(datalabel) dataset label
r(varlist) variables in dataset (if varlist specified)
r(sortlist) variables by which data are sorted (if varlist specified)
Scalars
r(N) number of observations
r(k) number of variables
r(width) width of dataset
r(changed) flag indicating data have changed since last saved
Macros
r(datalabel) dataset label
r(varlist) variables in dataset (if varlist specified)
r(sortlist) variables by which data are sorted (if varlist specified)
Code:
sysuse auto describe mpg price weight length return list
Comment