[R] [Plea to the R Gods] Theoretical and Empirical CDFs

Greg Snow Greg.Snow at imail.org
Fri Jun 3 05:01:27 CEST 2011


Look at the logspline package for one approach to doing this.

-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org] On Behalf Of teriri
Sent: Thursday, June 02, 2011 12:19 AM
To: r-help at r-project.org
Subject: [R] [Plea to the R Gods] Theoretical and Empirical CDFs

http://r.789695.n4.nabble.com/file/n3567636/ecdfs.jpg ecdfs.jpg 
http://r.789695.n4.nabble.com/file/n3567636/ecdf_curve.gif ecdf_curve.gif 

Hello,

I have generated a plot of two empirical CDFs (attachment 1). As a result,
they are stepwise when plotted. The following code was used:
> plot(ecdf(mut), do.points=FALSE, verticals=TRUE, xlim=range(mut, non),
> col="red")
> plot(ecdf(non), do.points=FALSE, verticals=TRUE, add=TRUE, col="blue")

But what I need instead are smooth curves, similar to ones that are
generated from a theoretical cdf (attachment 2). 

I have looked at so many threads; one suggestion to someone else was to use
library(fitdistplot) and look for distributions that may fit (e.g. weibull).
But I could really use guidance before spending additional time on this.

Thank you!


-TW

--
View this message in context: http://r.789695.n4.nabble.com/Plea-to-the-R-Gods-Theoretical-and-Empirical-CDFs-tp3567636p3567636.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list