"Nostalgia's not what it used to be" Department:
graph7 mpg price, twoway oneway
What R people -- and many others -- would usually
call a rug can be obtained in another way too:
levelsof mpg , local(mpgval)
levelsof price , local(priceval)
twoway scatter mpg price, ytic(`mpgval', tpos(inside)) xtic(`priceval', tpos(inside))
Nick
[email protected]
Maarten Buis replied to Scott Merryman:
> > Tufte's dot-dash-plot ("The Visual Display of Quantitative
> > Information" page 133) could be created as:
>
> Cool,
> It might be improved a bit by adding a jitter to mpg:
>
> sysuse auto,clear
>
> gen wherex = 11
> gen wherey = 3000
> gen pipe = "|"
> gen mpgjit = mpg + .4*invnorm(uniform())
>
> twoway scatter mpg price , msize(small) || ///
> scatter wherex price, ms(none) mlab(pipe) mlabcolor(black) ///
> mlabpos(0) || ///
> scatter mpgjit wherey , ms(none) mlab(pipe)
> mlabang(vertical)///
> mlabcolor(black) mlabpos(0) || , ///
> legend(off) yscale(noline) ylabel(none) xscale(noline) ///
> xlabel(none) xtitle(Price)
>
*
* 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/