Graves, Gregory wrote:
I will attempt to distill my problem down to a simpler one, the solution of
which will hopefully lead me to the nirvana of complete understanding, i.e.,
inserting a polygon beneath an irregular line terminated by the x axis.
I 'know' that polygon will work -provided- I knew the xy coordinates of the
line(s) beneath which I desire to create the polygon. Unfortunately, I don't
know how to get at that info.
Below is an example of a irregular line for which the xy coordinates are not known (i.e., at least not by me). I assume my problem boils down to finding out how to extract the xy from that line.
attach(cars)
plot(dist ~ speed)
scatter.smooth(speed, dist,family = "gaussian",span = .2)
Hi Gregory,
That's right, just call the underlying function (loess.smooth) and use
"str" on the result. There should be x and y components that can be
passed to "lines".
Jim
______________________________________________
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.