[R] plot empirical pdf
Martin Maechler
maechler at stat.math.ethz.ch
Tue Aug 26 09:30:19 CEST 2003
>>>>> "Ott" == Ott Toomet <otoomet at econ.dk>
>>>>> on Tue, 26 Aug 2003 08:47:28 +0200 writes:
Ott> Hi, are there any function to plot the empirical
Ott> probability distribution function? I just don't want
Ott> to reinvent the wheel...
As Uwe has already said, the standard "stepfun" package does this
-- and more. The idea of that mini-package was to introduce a
class "stepfun" for (1D) step functions, and a class "ecdf" which extends
"stepfun" -- at the same time demonstrating how R functions can
be used to return other R functions (with an own environment
where all information is stored). For many, it can be quite
instructive to study example(stepfun) and example(ecdf)
and the R source behind it.
Martin
More information about the R-help
mailing list