[R] How to denote a line on the graph
David Winsemius
dwinsemius at comcast.net
Sat Sep 18 04:39:15 CEST 2010
On Sep 17, 2010, at 7:57 PM, aegea wrote:
>
> Please give me some help, many thanks.
>
> I graphed a expected CDF line of a binomial distribution on a graph,
> And I have some observed points (observed CDF) from 4 groups fall on
> the
> smooth CDF line.
>
> I cannot really get the legend I want
>
>
> legend ('topleft', c('a, 'b', 'c', 'd', 'expected CDF'),
> col=c(1,2,3,4),
> pch=c(0,1,2, 3, '' ), lty=c(0,0,0,0,1) )
Does this deliver the sought after "graph notations" and line?
legend ('topleft', c('a', 'b', 'c', 'd', 'expected CDF'),
col=c(1,2,3,4),
pch=c(0,1,2, 3, NA ), lty=c(0,0,0,0,1) )
>
> Ideally, in legend I want to show different graphics marks for
> different
> group, and a short line in the legend to show the smooth line on the
> graph
> is the CDF. but, the legend with my code shows 0, 1, 2, 3 instead
> different
> graph notations for the four groups.
> --
> View this message in context: http://r.789695.n4.nabble.com/How-to-denote-a-line-on-the-graph-tp2544595p2544595.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