-
-
Notifications
You must be signed in to change notification settings - Fork 21
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
Rename and mutate variables #12
Comments
Should we wish to use tidyverse-style NSE I believe the only dependency we need is I don't think we would need to support more complex syntax available in So supporting tidyverse NSE should in effect add no new dependencies ( |
Yeah I think you're right that |
Having the |
Yeah, I've used If we want this I can take a stab at it. |
Thank you! I think it is a nice feature that people will ask for and I would be happy if you could take a shot at it. Perhaps starting with the |
Same! Happy for you to take a stab at it, thanks! It does seem like a nice feature to offer. |
Just a quick note that I am working on |
x <- as_draws_df(example_draws())
x <- subset(x, variable = c("mu", "tau"))
mutate_variables(x, tau2 = tau^2)
mutate_variables(x, scale = 1.96 * tau, lower = mu - scale) |
Cool! One small thing from testthat:
|
Thanks. Should be fixed now. |
When adding a new variable to |
For users it might be convenient to have
rename
andmutate
functionality to make changes to variables similar to how we do it with the related dplyr functions. To avoid function masking, we may want to name themrename_variables
andmutate_variables
which would also be consistent with our naming conventions.If we decide to implement such functions, we need to think of a proper backend for non-standard evaluation. We could of course use the one of tidyverse but I am not sure how much additional dependencies this implies. @mjskay you may have more experience with this than I have.
The text was updated successfully, but these errors were encountered: