-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
with.mids() using eval_tidy() breaks compatibility with metafor #292
Comments
Sorry about the hassle. I'd expected that the change wouldn't affect any downstream packages, but your problem proves that my expectation was not well grounded. I'd also expected that the change would solve a problem with dot expansion in formula (#265), but also that one didn't work out as I'd hoped for. I have tried a few thing to make the |
Thank you for reverting to the old version. I will let you know if I can figure out a way to make |
Commit 4634094 changed
with.mids()
to useeval_tidy()
in place ofeval(expr = substitute(expr), envir = data.i, enclos = parent.frame())
. This breaks compatibility with the metafor package. An example:This fails with error
Error in eval(predvars, data, env) : object 'ablat' not found
. Apparently,eval_tidy()
is not able to find the predictor variables. Usingeval()
as before works:I read
help(eval_tidy, package="rlang")
to figure out what it does differently thaneval()
but this gets quite technical. I think the crucial part may be "Functions that require the evaluation environment to correspond to a frame on the call stack do not work." In any case, is there any advantage to usingeval_tidy()
besides saving a few lines of code? If not, would you consider reverting to the old version ofwith.mids()
?The text was updated successfully, but these errors were encountered: