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

RE: st: histogram height as avg of another variable

From   "Nick Cox" <>
To   <>
Subject   RE: st: histogram height as avg of another variable
Date   Wed, 13 Feb 2008 16:53:57 -0000


. search binsm 


Maarten buis

Have a look at -graph bar-. If the variable along x is continuous you
can create your own grouped variable, and use that in the -over- option
in -graph bar-.

Prashant Loyalka 

> I would like to create histogram(-type) graphs where the baseline
> axis is
> one variable (say x) and the height of each bin is an average of
> another
> variable (say y). The average of the y variable is based on the
> observation
> points within the bin as decided by a set binwidth along x. I would
> also like
> to be able to adjust the bindwidth size (a constant bindwidth size,
> i.e.) and the starting point of the bins along the x axis--also so
> that each bin can be centered around the midpoint of the binwidth.
> Does Stata have this capability? If so, under what commands?
> If not, could someone offer some guidance about how to program this?

*   For searches and help try:

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