Thanks. That took care of my problem. I will keep a sharper eye for such
things in the future.
Doug
>>> [email protected] 1/25/2004 13:10:47 >>>
I confirm the same behaviour
with the auto data, substituting -mpg- for
-comprate- and -weight- for -week- and
-foreign- for -unit-.
I fixed all problems by removing spaces between -by- and
-(<its argument>)-.
In essence, no space is ever _required_ there
and I don't believe that one is ever used in
code examples in Stata documentation. Although
your examples seem inconsistent, it seems that
Stata is trying to read your mind from what
you typed, and succeeding sometimes and not
others. Sometimes spaces are ignored as superfluous, but
not always.
Stata isn't human but as in other contexts
you can be misunderstood if you bend linguistic
rules too much. I recommend always following
an option name immediately by any argument in
parentheses that it may have.
Nick
[email protected]
> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]]On Behalf Of Doug
Simmons
> Sent: 23 January 2004 21:23
> To: [email protected]
> Subject: st: -by()- suboptions with -twoway- plots
>
>
> My apologies. As I have done some more testing I have learned
> it is not
> a difference between command line and .do file operation.
>
> This code works as expected:
> scatter comprate week || ///
> fpfit comprate week ||, ///
> by (unit)
>
> However, this block fails with the message ") required":
> scatter comprate week || ///
> fpfit comprate week ||, ///
> by (unit, total)
>
> There appears to be yet another issue as the following works:
> scatter comprate week ||, by (unit)
>
> But, this does not:
> scatter comprate week, by (unit)
>
> The inclusion of suboptions fails in all cases and it does not seem
to
> matter what suboptions are used. I have tried several
> different -twoway-
> plottypes, each yielding the same results.
>
> Thanks again for any insight and assistance.
> Doug
*
* 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/