Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: Cannot simultaneously use weight and marker label options in scatter plot?


From   "Nick Cox" <n.j.cox@durham.ac.uk>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: RE: Cannot simultaneously use weight and marker label options in scatter plot?
Date   Wed, 16 Mar 2005 18:20:31 -0000

Try superimposing the graphs: 

scatter price mpg [w=rep78],  msymbol(Oh) || /// 
scatter price mpg [w=rep78], ms(none) mlabel(foreign) 

Nick 
n.j.cox@durham.ac.uk 

Steve Lin
 
> I would like to display a scatter plot in which (1) the markers are
> labeled with observation identifiers and (2) the size of each 
> marker is
> scaled according to its weight in a weighted least squares regression.
> 
> I can display the plot with either option alone, but for some reason,
> when I try to use both simultaneously, the marker labels are displayed
> properly, but the markers are no longer scaled.
> 
> Here's a simple program that illustrates the problem, using the Stata
> user manual auto dataset:
> 
> clear all
> use http://www.stata-press.com/data/r8/auto.dta
> collapse (mean) price mpg (count) rep78, by(foreign)
> describe
> scatter price mpg [w=rep78], mlabel(foreign) 
> scatter price mpg [w=rep78],  msymbol(Oh) 
> scatter price mpg [w=rep78],  msymbol(Oh) mlabel(foreign) 

*
*   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/



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