Skip to content
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

Make functions pipe-friendly #304

Open
strengejacke opened this issue Jan 9, 2025 · 0 comments · May be fixed by #320
Open

Make functions pipe-friendly #304

strengejacke opened this issue Jan 9, 2025 · 0 comments · May be fixed by #320
Assignees
Labels
Feature idea 🔥 New feature or request

Comments

@strengejacke
Copy link
Member

strengejacke commented Jan 9, 2025

API-wise I think it would make sense to add a estimate_contrasts() method to apply to estimate_slopes() outputs

estimate_slopes(m) |> estimate_contrasts()

Instead of complexifying the estimate_slopes() itself

Originally posted by @DominiqueMakowski in #301 (comment)

Yes, we would still not recompute from scratch

I reckon a pipe workflow would just be syntactic sugar for:

estimate_contrasts.estimate_means <- function(x) {
  model <- extract_model(x)
  # recompute contrasts
  estimate_contrasts(model, ...)
}
@strengejacke strengejacke added the Feature idea 🔥 New feature or request label Jan 9, 2025
@strengejacke strengejacke self-assigned this Jan 10, 2025
strengejacke added a commit that referenced this issue Jan 10, 2025
@strengejacke strengejacke linked a pull request Jan 10, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature idea 🔥 New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant