search for: lmcoef

Displaying 1 result from an estimated 1 matches for "lmcoef".

Did you mean: plmcoef
2006 Jun 06
0
xYplot, lmline and abline
...your time, Dan library(Hmisc) windows(record=TRUE) panelgrp=rep(LETTERS[1:3], 20) sites=c(rep("d", 15), rep("e", 15), rep("f", 15), rep("g", 15)) data1=data.frame(panelgrp=factor(panelgrp), sites=factor(sites)) data1$pred=runif(60) data1$resp=runif(60) lmcoef=lm(resp~pred, data=data1[data1$panelgrp=="A",]) xYplot(resp~pred|panelgrp, groups=sites, data=data1, pch=c(1,2,3,4), abline=list(a=lmcoef$coefficients[1], b=lmcoef$coefficients[2], lty=2)) Key() xYplot(resp ~ pred|panelgrp, groups=sites, pch=c(1,2,3,4), data=data1,...