Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: RE: yscale in anovaplot


From   "Steichen, Thomas J." <[email protected]>
To   "'[email protected]'" <[email protected]>
Subject   st: RE: yscale in anovaplot
Date   Fri, 24 Apr 2009 15:07:10 -0400

Although you have suppressed printing a symbol for the data points via -scatter(msym(none))-, Stata still allows room for that invisible data in its y-axis range. Therefore you cannot reduce the range given the way the code is written. Editing the code to allow what you want is pretty straightforward.

Change line:
                numlist "2/`= 1 + `: word count `fits'''"
To:
                numlist "1/`= 1 + `: word count `fits'''"

And line:
            twoway scatter `y' `x1' if e(sample), `scatter' ///
To:
            twoway `scatter'  ///

Then edit line:
program anovaplot, sort
To:
program anovaplot0, sort

Save it with new name anovaplot0.ado and invoke it with command -anovaplot0-

Nick Cox's original will keep working and you'll have this one for your purpose.

Of course, you could get fancy and add a -nodata- option that allows both forms in a single program.

Tom

-----------------------------------
Thomas J. Steichen
[email protected]
-----------------------------------

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Diego Bellavia
Sent: Friday, April 24, 2009 1:50 PM
To: [email protected]
Subject: st: yscale in anovaplot

Dear Statalisters,

I am trying to plot an ANOVA for repeated measures model using the amazing anovaplot command.
Everything works fine except the yscale range. I need to reduce the range and increase the scale
to make differences clear. So I tried:

anovaplot level groups, scatter(msym(none)) yscale (range(-12 -24)) ylabel(-12 (2) -24)

The problem is that I actually reduced the numbered range and the labelling but now almost half of the graph
is empty. Is there any way to change the range so that I can take advantage of all the graph extension ?

Hope I was able to express the concept, thank you in advance,

Diego
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

CONFIDENTIALITY  NOTE:  This e-mail message, including any attachment(s), contains information that may be confidential, protected by the attorney-client or other legal privileges, and/or proprietary non-public information. If you are not an intended recipient of this message or an authorized assistant to an intended recipient, please notify the sender by replying to this message and then delete it from your system. Use, dissemination, distribution, or reproduction of this message and/or any of its attachments (if any) by unintended recipients is not authorized and may be unlawful.

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



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