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

Re: st: kernel density

From   Svend Juul <SJ@SOCI.AU.DK>
To   <>
Subject   Re: st: kernel density
Date   Thu, 18 Sep 2008 09:03:26 +0200

Nigussie wrote:

I am PhD student and request your assistance on this issues.  Suppose I
have two columns variable "lnexp" and "region" where lnexp is log of
expenditure (continuous) and region is a categorivsl variable; 1=Eastern
region, 2=Southern region and 3= Northern region. If I want to draw
kernel graphs of "lnexp" for these regions on one chart,  what should I
do on Stata 10? I need a command. 

You can use the addplot() option, like this:

   sysuse auto.dta , clear
   kdensity weight if foreign==1 , addplot(kdensity weight if

Hope this helps

Svend Juul
Institut for Folkesundhed, Afdeling for Epidemiologi
(Institute of Public Health, Department of Epidemiology)
Vennelyst Boulevard 6
DK-8000  Aarhus C, Denmark
Phone:  +45 8942 6090
Home:   +45 8693 7796

*   For searches and help try:

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