Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


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

Re: st: n() option for -akdensity-


From   Katie Farrin <[email protected]>
To   [email protected]
Subject   Re: st: n() option for -akdensity-
Date   Tue, 1 Apr 2014 11:03:26 -0400

I could be wrong, but it was my understanding that the n() option
allowed for some sort of interpolation to get a smoother density
function from a finite number of data points.  If this isn't possible
I can stick with what I have, but I am trying to find a cutoff point
for a one-in-ten event and don't have that level of precision using
the data I have.

Thanks for your response.

Katie

On Tue, Apr 1, 2014 at 10:54 AM, Alfonso Sánchez-Peñalver
<[email protected]> wrote:
> Forget me if Im wrong because I dont know much about how the adaptive version of a kernel density works (by the way, you should mention that -akdensity- is available from SSC), but the whole point of a kernel density is to use the sample points as kernels and non-parametrically estimate the density function under the assumption that the sample follows the populations distribution. How are you going to use more points than those you have in the data? Are you going to make them up? I may have misunderstood what you meant with larger n, but Im really confused.
>
> Alfonso Sánchez-Peñalver, PhD
>
>
> On Apr 1, 2014, at 10:33 AM, Katie Farrin <[email protected]> wrote:
>
>> Good Morning,
>>
>> I'm trying to estimate a cdf from a kernel density using a data series
>> (n=72) I have using the -akdensity- command.  However, I'd like more
>> data points in the cdf than I have for actual observations and am
>> having trouble using the n() option for -akdensity- and am hoping
>> someone can give me some advice on how to create a cdf with a larger
>> n.
>>
>> I'm plotting the kernel density along with a normal distribution with
>> n(500) and would like the same number of data points for the kernel
>> and cdf, but I get an error message when I try to specify n in the
>> options for the cdf.
>>
>> Here is the code I'm using:
>>
>> akdensity GC, bwidth(.5) normal n(500) generate(gx_chim fgx_chim)
>> cdf(cdf_g_chim)
>> line cdf_g_chim gx_chim
>>
>> Any help would be greatly appreciated.
>>
>> Katie
>> *
>> *   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/
>
>
> *
> *   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/

*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index