Skip to content
Prev 10649 / 398502 Next

using gee

I have this trial function to use gee,

trygee <- function (x, id) {
  y <- x + rnorm(length(x))
  dat <- data.frame(x=x, y=y, id=id)
  foo <- gee(y ~ x, id, data=dat)
  foo$coeffcients
}
Error in model.frame.default(formula = y ~ x, id = id, data = dat) : 
	Object "dat" not found

Since I want to use gee within a function to be called again and again,
what's the proper way to do this?  Thanks.

Jun

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._