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

Re: st: -kdensity, normal normopts(lpattern(dash))- ?

From   [email protected] (Jeff Pitblado, StataCorp LP)
To   [email protected]
Subject   Re: st: -kdensity, normal normopts(lpattern(dash))- ?
Date   Sat, 27 Mar 2004 22:55:52 -0600

Dimitris Christodoulou <[email protected]> asks about changing line styles
when using -kdensity-:

> What is the equivalent correct syntax for something like
> -normopts(lpattern(dash))- in the -kdensity- command? I wish to superimpose a
> normal density over a kernel estimator, but I need the normal curve to be
> dashed or dotted and not as thick as the line of the kernel.
> Here is part of the (incorrect) command:
> -kdensity var, parzen lwidth(thick) normal normopts(lpattern(dash)
> lwidth(medium))-
> Note that I will like the kernel line to be -lwidth(thick)- and the normal
> density line to be -lpattern(dash) lwidth(medium)-.

Use the cline_options (see help cline_options).  Here are the options
appropriate for Dimitris' example and the auto data:

	. sysuse auto, clear
	. kdensity mpg, parzen clwidth(thick) normopts(clpatter(dash))

[email protected]
*   For searches and help try:

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