I never intentionally use abbreviations. In this case, my model included
interactions between quantitative predictors, and I chose (perhaps
foolishly) to name the product terms like this:
. gen maxmin=max*min
Subsequently, for reasons that don't matter, it made sense to be fitting
models including some interactions without their main effects. Following
the fit I still had expressions involving _b[max] that SHOULD have crashed
but didn't, because that expression returned _b[maxmin] even though I had
set varabbrev off. Hence my whinge about hidden errors.
Returning zero instead of crashing would also be ok I suppose, and makes a
sort of sense if a term is not in the model at all.
fyi: Stata have responded (in a personal email) "we agree this is something
we should look at. It will require an internal code hit (rather than just
ado code), so at this stage we don't know how difficult a change this will
be. If we do manage to do it, it will be in an executable update, rather
than an ado update."
Keith
At 05:25 AM 11/5/05, you wrote:
On the general question:
1. I'd say there is a good purist case for
saying that variable abbreviations should never
have been introduced, as they do complicate
the language and introduce an extra source of bugs.
The practical case is sordidly pragmatic by
comparison and hinges on saving time and trying
to avoid repetitive strain injuries!
2. Variable abbreviations are voluntary on
your part. If you think they are a bad idea,
why do you use them, or is that just by
accident?
Nick
[email protected]
Keith Dear
> set varabbrev off
> reg y somexvar
> ...
> di _b[some]
>
> This displays the estimate _b[somexvar], instead of reporting
> "[some] not
> found".
>
> Bug or feature? Is there some other option I can -set- to
> stop this happening?
>
> Do others concur that variable abbreviations are a BAD IDEA?
> It seems to me
> they add no real functionality, and too often conceal errors
> in (my) do-files.
*
* 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/
==========================================================
Dr Keith B.G. Dear
Senior Fellow in Biostatistics
National Centre for Epidemiology and Population Health (NCEPH)
The Australian National University
Canberra, ACT 0200, Australia
Tel: 02 612 54865, Fax: 02 612 50740
http://nceph.anu.edu.au/Staff_Students/staff_pages/dear.php
CRICOS provider #00120C
*
* 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/