[R] Trellis plots with two regression lines

From: yvo <yvo.fabian_at_gmx.de>
Date: Tue, 11 Mar 2008 05:18:01 -0700 (PDT)

http://www.nabble.com/file/p15976467/table.pdf table.pdf

I want to create 8 trellis (|experiment) scatterplots with regression lines for prey and pred in each plot with different colouring. So far i am creating trellis plots- but the separation in these groups is never possible.

library(lattice)
graphs<- read.table("table.txt", header=T) attach(graphs)
names(graphs)
str(graphs)
xyplot(abund ~ bif | experiment, data=graphs, groups=stage,

        panel=function(x,y){panel.xyplot(x,y, pch=16) panel.abline(lm(y~x))})

Thanks a lot for your help!!
Yvonne Fabian
University of Fribourg

-- 
View this message in context: http://www.nabble.com/Trellis-plots-with-two-regression-lines-tp15976467p15976467.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.
Received on Tue 11 Mar 2008 - 12:42:20 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 12 Mar 2008 - 10:30:21 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive