I'd like to report some unusual performance of the -ksm- command.
I have a binary outcome Y and a continuous predictor X. I wanted to do a
lowess, separately for subgroups of data (by the variable Z, which takes on
four distinct values in my data), so I tried the undocumented
. ksm y x, lowess by(z)
This actually worked fine, producing four plots on a single page (Z has 4
separate values in my dataset).
But when I tried
. ksm y x, lowess logit by(z)
I got flat lines in all my graphs (something was not working). So, I
figured, it's an undocumented feature, so I can't be picky.
But then, I tried to do the simple (and correct)
. ksm y x, lowess
and got an error message
by() invalid
r(198)
And this correct -ksm- specification would not work from then on.
Now this seems to be a bug. An incorrect invocation of -ksm- should not
effect future correct specifications of the same command.
[By the way, a supported by() option would be very handy for -ksm-, so
maybe Stata can implement one?]
But now I have a big problem in my hands.
Even when I quit Stata and restart, I keep getting the same error message
with any (correct) specification of the -ksm- command.
And this still happens even if I reboot my computer!
In effect, I cannot use the -ksm- command any more.
I updated my version of Stata (hoping that an updated executable might
solve this) but the problem persists.
It seems that I have to reinstall Stata from scratch.