{smcl}
{hline}
help for {hi:slist}
{hline}

{title:Smart listing of variables}

{p 8 15}
{cmd:slist} [{it:varlist}] [{cmd:if} {it:exp}] [{cmd:in} {it:range}]
[{cmd:,} 
    {cmdab:d:ecimal(}{it:number}{cmd:)}
    {cmdab:i:d(}{it:varlist}{cmd:)}
    {cmdab:noo:bs}
    {cmdab:l:abel}]

{p}{hi:by ...:} may {hi:not} be used with {hi:slist}.

{p}{it:varlist} may contain any variable types; see help {help varlist}.


{title:Description}

{p}
{cmd:slist} for Stata 7 and 8 displays compact lists fitting current width of output window. If more than
one line is needed, a new block of variables is created.


{title:Options}

{p 0 4}
{cmd:decimal(}{it:number}{cmd:)} lets you select the number of decimals for floating point
numbers. If omitted, {cmd:slist} uses general format.

{p 0 4}
{cmd:id(}{it:varlist}{cmd:)} ensures that one or more id variables are displayed at the
beginning
of each line.

{p 0 4}
{cmd:noobs} omits observation numbers. Frequently used in combination with
{cmd:id(}{it:varlist}{cmd:)}.

{p 0 4}
{cmd:label} lists value labels instead of numerical codes for variables having value
labels


{title:Remarks}

{p}
The {help list} command is clumsy in displaying lists with more than a few variables.
{cmd:slist} displays compact lists with numeric codes. Value labels are only shown when
explicitly
requested. 

{p}
{cmd:slist} compresses the data in memory and finds the most economic formats. This may
take some time with large uncompressed data sets, and it is recommended to keep your
data in compressed form, for this and other reasons; see {help compress}. After
completion the original data format is restored.

{p}
IF you wish a permanent change of display formats, see {help format} or automatic
formatting with {help aformat}. {cmd:aformat} is available from the 
{browse "http://ideas.repec.org/s/boc/bocode.html":Statalist source code archives (ssc-ideas)} 


{title:Examples}

     {inp:. slist}
     {inp:. slist v1-v27}
     {inp:. slist , decimal(2)}
     {inp:. slist v1-v27 in 1/20 if sex == 1}
     {inp:. slist v1-v27 , noobs id(idno)}
     {inp:. slist        , label} 

{inp:. slist in 3/4 , d(2) id(idno)}

     idno  sex  age  wt   ht  smoke  cigaret  cheroot  pipe  agegr
  3.    7    1   49  85  190      1       10        2     0      2
  4.   11    2   71  85  166      2        0        0     0      3

     idno  tobacco    bmi  bmigr
  3.    7       14  23.55     20
  4.   11        0  30.85     30

{inp:. slist idno sex smoke in 3/4 , label} 

     idno  sex  smoke  
  3.    7    M    Yes  
  4.   11    F    No


{title:Authors}
{browse "mailto:sj@soci.au.dk":Svend Juul}, Department of Epidemiology and Social Medicine, University of Aarhus,
Denmark.
{browse "mailto:JM.Lauritsen@dadlnet.dk":JM.Lauritsen}, Accident Analysis Group, Odense University Hospital, Denmark. 
John Gallup developIT.org, USA. 

{title:Also see}
Help for  {help list}, {help format}, {help aformat}, {help compress}
