[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: pdf estimation
From: |
HALL, BENJAMIN PW |
Subject: |
RE: pdf estimation |
Date: |
Mon, 3 Oct 2011 13:36:05 -0400 |
>-----Original Message-----
>From: address@hidden [mailto:address@hidden On Behalf Of >CdeMills
>Sent: Monday, October 03, 2011 1:02 PM
>To: address@hidden
>Subject: pdf estimation
>
>Hello,
>let's define x as x=randn(200,1);
>
>An approximation of x cdf can be obtained as
>plot(sort(x), (0:199)/200);
>
>I tried to estimate the pdf as:
>pp=spline(sort(x), (0:199)/200);
>ppd=ppder(pp);
>x_pdf = ppval(ppd, sort(x))
>
>but the obtained values just exhibit large spikes and nothing usefull can be
>extracted. Is there some way, starting from a random variable, to obtain a
>smooth estimator of its cdf which can lead to an estimator of its pdf ?
>
>Regards
>
>Pascal
The attached might be useful. This is a quick translation of the R function
with the options I was interested in at the time. I'm struggling now to find
an appropriate reference on the R web site (www.r-project.org) to point you to
for more information. I also don't know if there is some pseudo matlab
equivalent, but I find this function to be handy.
density.m
Description: density.m
- pdf estimation, CdeMills, 2011/10/03
- RE: pdf estimation,
HALL, BENJAMIN PW <=