search for: lmerframes

Displaying 2 results from an estimated 2 matches for "lmerframes".

2007 Jan 26
2
Using functions within functions (environment problems)
...and modify the formula for include these two new variables, and then fit this expanded model using lmer. Clearly the example is silly, but it illustrates the problem as it fails with the error: Error in eval(expr, envir, enclos) : object "xNew" not found because a function within lmer (lmerFrames) makes an eval call where the environment is specified as the .GlobalEnv which doesn't contain xNew - it needs to be looking in the environment from which it was called rather than going right back to the root. In a more general context, I might like to create a function where I don't speci...
2007 Jan 26
0
R crash with modified lmer code
...atDim, rand_matI = rand_mat, ...) { method <- match.arg(method) formula <- as.formula(formula) if (length(formula) < 3) stop("formula must be a two-sided formula") cv <- do.call("lmerControl", control) mc <- match.call() fr <- lmerFrames(mc, formula, data, contrasts) if (matDimI[1] != length(fr$Y)) stop("forSmoothing is not a sensible length") #insert Y <- fr$Y X <- fr$X weights <- fr$weights offset <- fr$offset mf <- fr$mf mt <- fr$mt if (is.chara...