Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: histogram plot with lines

From   "Scott Merryman" <[email protected]>
To   <[email protected]>
Subject   st: RE: histogram plot with lines
Date   Fri, 17 Nov 2006 05:17:30 -0600

I don't know if the undocumented command -twoway__histogram_gen- is
available in Stata 8, if so, this should work:

sysuse auto,clear
histogram mpg
twoway__histogram_gen mpg,  start(12) bin(8) gen(h x)
drop if x==.
keep x h
expand 2
sort x
replace x = x[_n+1] if _n <_N
replace x = x + `r(width)' in l
drop if h ==.
twoway line h x, name(gr2,replace)  xlabel(minmax)


> -----Original Message-----
> From: [email protected] [mailto:owner-
> [email protected]] On Behalf Of Munro, Cameron
> Sent: Friday, November 17, 2006 2:16 AM
> To: [email protected]
> Subject: st: histogram plot with lines
> I'm looking for a package that would allow me to plot a histogram but
> display as a line chart rather than as bars as per hist. Is anyone aware
> of such a package? I'm using Stata 8.
> Many thanks,
> Cameron.

*   For searches and help try:

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