Greetings helpRs --
I would like to use plot() to plot two cumulative distribution curves so that a user of the plot can compare the distributions of the two variables. The following code draws two distributions separately, but I cannot find the instruction necessary to add a second cumulative distribution to the first one. Any suggestion would be very welcome. x1 <- sort(rnorm(1000,50,10)) x2 <- sort(rnorm(1000,40,8)) plot(x1,1:length(x1)/length(x1),type="l") plot(x2,1:length(x2)/length(x2),type="l") grid(col = "black") Ben Fairbank [[alternative HTML version deleted]] ______________________________________________ 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.