Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

RE: st: Referring to a varname, leading to errors


From   "Nick Winter" <nwinter@policystudies.com>
To   <statalist@hsphsun2.harvard.edu>
Subject   RE: st: Referring to a varname, leading to errors
Date   Wed, 12 Feb 2003 08:46:27 -0500

> -----Original Message-----
> From: Philippe Glaziou [mailto:glaziou@pasteur-kh.org] 
> Sent: Wednesday, February 12, 2003 5:26 AM
> To: statalist@hsphsun2.harvard.edu
> Subject: Re: st: Referring to a varname, leading to errors
> 
> 
> Ulrich Kohler <ukohler@sowi.uni-mannheim.de> wrote:
> > From that point of view some sort of command and variable
> > completion in the command window -- like in unix-shells --
> > would be as comfortable as abbreviations but slightly more
> > secure. 
> 
> A tab completion mode for var names was introducted in stata8.
> Unfortunately not for command names. 

Wow - look at that!  Hadn't noticed that, but it's cool.

> In the case of an ambiguity --i.e. completion may lead to several
> different var names, then the tab key does nothing. Displaying a
> list of all possible completions, similar to what the sh, bash or
> zsh shells do, would be rather useful.

Not quite right.  Pressing -tab- seems to complete the variable name up
to the point of ambiguity.  If there is no ambiguity, that is the whole
variable name.  But if you have two variables "displacement1" and
"displacement2", typing "d<tab>" will give you "displacement".

There is a subtle clue that you don't yet have the complete
varname--Stata adds a space after completing a complete varname, and
does not when only filling in to the point of ambiguity.

--Nick Winter
*
*   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/



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index