Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: strange kdensity behavior


From   Nick Cox <njcoxstata@gmail.com>
To   "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   Re: st: strange kdensity behavior
Date   Fri, 31 May 2013 19:13:45 +0100

I guess you'll need to -generate- the density and the corresponding
variable values, then  re-graph.

Nick
njcoxstata@gmail.com


On 31 May 2013 17:15, Rebecca Pope <rebecca.a.pope@gmail.com> wrote:

> As an add-on question, is there a way to "zoom in" on the lower end of
> the plot? If I use -if-, -kdensity- calculates the density over that
> range (which I don't want).
> To see this:
> kdensity lognorm if lognorm<=10, addplot((kdensity lognorm if
> lognorm<=5, lpattern(dash))) ///
> legend(order(1 "Default Plot" 2 "Added Plot")) name(plot2)
>
> You'll notice that the greatest change is in Default Plot.
>
> If I use the x-axis options, it just changes the labeling without
> excluding the higher values of X.
>
> I'm running Stata 12.1 on Windows 7. Stata is updated to 20 Mar 13 &
> when I checked for updates, nothing new showed up.
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index