Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

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

st: -aaplot- available from SSC

From   Nick Cox <>
To   "''" <>
Subject   st: -aaplot- available from SSC
Date   Sat, 21 May 2011 15:18:20 +0100

Thanks to Kit Baum in a double sense -- he provided helpful detailed comments as well as putting up the files -- a single-program package -aaplot- is now available from SSC. Stata 11 is required (but see below). 

The "aa" here can be thought of as "automatic annotation", namely that this plot is for showing 

a scatter plot with linear and/or quadratic fit, automatically annotated

the annotation being, by default, model equations (with coefficients moderately rounded) and a display of R-square, sample size n and root mean square error. 

To get a formal statement, 

. ssc type aaplot.sthlp

To download 

. ssc inst aaplot

More comment if desired:  

Since Stata 8, there have been various official commands, -scatter-, -twoway lfit-, -twoway qfit-, two or three of which are commonly combined on the fly or in programs. -aaplot- is just a convenience command putting together two or three of those official commands. It is difficult to believe that this hasn't done before; rather, I incline to a guess that it has, but that I am just not currently aware of other implementations. Some users with long memories may recall a -sparl- program, still on SSC, last revised in 2000, which requires Stata 6 and up, and still works, but is confined to the old graphics.  

While hoping that -aaplot- might prove useful -- for example, in teaching or for initial explorations -- I make two broad comments now. 

First, -aaplot- is at best indicative, and certainly not definitive. Some tastes might run to showing (for example) standard errors, t statistics and P-values instead of, or in addition to, the results shown.  Users so inclined should feel free to clone -aaplot- and should feel compelled to use their own different program name. Naturally I will feel obliged to fix bugs, but I won't feel compelled to add your desired features. Totally out of the question as far as I am concerned is starring * ** *** equations as if they were hotels or movies or Lady Gaga tracks(*). 

Second, while Stata 11 is required, enterprising Stata users confined (say by financial exigency) to one of Stata 10, 9 or 8 should find that a few minutes' work should be enough to make something very similar work with their Stata. I won't support any alternative versions, but as above just encourage people to take responsibility for what they do and to find some alternative name. 


(*) No one should read anything into this sudden reference to Lady Gaga. I am happy to acknowledge that this person is widely regarded as a star. 

*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index