Fit your model in the panel function using lm and plot the fits using ?panel.points, ?panel.lines, etc.
-- Bert Bert Gunter Genentech Nonclinical Biostatistics (650) 467-7374 "Data is not information. Information is not knowledge. And knowledge is certainly not wisdom." Clifford Stoll On Tue, Oct 7, 2014 at 6:01 AM, Bond, Stephen <stephen.b...@cibc.com> wrote: > What is the way to add an arbitrary fit from a model to a lattice > conditioning plot ? > > For example > xyplot(v1 ~v2 | v3,data=mydata, > panel=function(...){ > panel.xyplot(...) > panel.loess(...,col.line="red") > } > ) > Will add a loess smoother. Instead, I want to put a fit from lm (but not a > simple straight line) and the fit has to be done for each panel separately, > not one fit for the full data set, so sth like an lm equivalent of > panel.locfit (there is no panel.lmfit) > Thank you. > > Stephen B > > > [[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. ______________________________________________ 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.