Quin Wills wrote:
> Hello all
>
> Simple question for the gurus. I'm trying to interactively label curves
> on a single plot. The labcurve() function from Hmisc seems like the way
> to do this (?). I just can't seem to get it to work. Toy example:
>
> > x <- 1:10
> > y1 <- x^2
> > y2 <- 2*x
> > plot(x,y1)
> > lines(x,y2)
> > labcurve(labels=c("curve1", "curve2"), method="locator")
>
> From the help file, this is how I would understand it should be done,
> but have tried many other combinations, with no luck.
>
> Running up-to-date R, R packages and Fedora.
>
> Many thanks,
> Quin
>
Please take time to read the help file for labcurve which makes it clear
that you need to give it the data as well as the curve labels. Also
specify pl=TRUE.
--
Frank E Harrell Jr Professor and Chair School of Medicine
Department of Biostatistics Vanderbilt University
______________________________________________
[email protected] 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.