Hi,

i want to plot empirical cumulative density functions for two variables in
one plot. For better visualizing the differences in the two cumulative curves 
I'd like to log-scale the axis.

So far I found 3 possible functions to plot ecdf:

1) ecdf() from the package 'stats'. I don't know how to successfully set the 
log.scales? Combining two plots is not a problem:

plot(ecdf(x1))
lines(ecdf(x2),col.h="red")

2) gx.ecdf() from package 'rgr'. It is easily possible to plot log-scales, but 
I don't know how to plot two densities?

gx.ecdf(x1,log=TRUE,ifqs = TRUE)

3) Ecdf() from package 'Hmisc'. No log-option directly available and here I 
also don't know how to 'stack' two plots...

Ecdf(x1,what="F")


Probably there are many more solutions (e.g. ggplot etc.)...
...Has anyone faced a similar task and found a simple solution? Any suggestions 
are welcome!

Best regards,

Johannes


-- 

Jetzt informieren: http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a

______________________________________________
R-help@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.

Reply via email to