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

Rename pairwise comparisons #722

Merged
merged 10 commits into from
Mar 22, 2024
Merged

Rename pairwise comparisons #722

merged 10 commits into from
Mar 22, 2024

Conversation

nikosbosse
Copy link
Contributor

@nikosbosse nikosbosse commented Mar 20, 2024

Description

As discussed in #638, this PR

  • renames add_pairwise_comparison() to add_relative_skill()
  • renames pairwise_comparison() to get_pairwise_comparisons()
  • renames plot_pairwise_comparison() to plot_pairwise_comparisons() which is a breaking change I'm sure people will love...
  • updates tests, docs and the news file

The rationale for this change is this:

  • add_relative_skil() is a bit more descriptive than add_pairwise_comparison() in terms of what it does
  • Naming it differently from get_pairwise_comparisons() would make it clear that these are two different workflows with two different purposes (one mainly for plotting, the other for computing scores).
  • The name get_pairwise_comparisons() would make the naming of the function more in line with the other get_-functions
  • I'd still call it get_pairwise_comparisons() rather than get_relative_skill() because the main thing this function is meant to give you according to our updated workflow is the (visualisation of) mean score ratios (see below)
  • The change from plot_pairwise_comparison() to plot_pairwise_comparisons() is a bit stupid. But get_pairwise_comparisons() feels more appropriate than get_pairwise_comparison() and the get_ and the plot_ function should be consistent. We could do aliases? Or stick with the singular after all.

Visualisation of mean score ratios:

image

Checklist

  • My PR is based on a package issue and I have explicitly linked it.
  • I have included the target issue or issues in the PR title as follows: issue-number: PR title
  • I have tested my changes locally.
  • I have added or updated unit tests where necessary.
  • I have updated the documentation if required.
  • I have built the package locally and run rebuilt docs using roxygen2.
  • My code follows the established coding standards and I have run lintr::lint_package() to check for style issues introduced by my changes.
  • I have added a news item linked to this PR.
  • I have reviewed CI checks for this PR and addressed them as far as I am able.

Copy link

codecov bot commented Mar 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.27%. Comparing base (0982955) to head (004b1f3).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #722   +/-   ##
=======================================
  Coverage   95.27%   95.27%           
=======================================
  Files          21       21           
  Lines        1630     1630           
=======================================
  Hits         1553     1553           
  Misses         77       77           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@nikosbosse nikosbosse marked this pull request as ready for review March 20, 2024 13:21
@nikosbosse nikosbosse requested a review from seabbs March 20, 2024 13:27
@seabbs
Copy link
Contributor

seabbs commented Mar 21, 2024

plot_pairwise_comparisons()

For this little one shall we just chuck in an alias? It seems a bit cruel! Or shall we just be cruel?

Copy link
Contributor

@seabbs seabbs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This all seems good to me. See comment about the cruelty of the s but there are so many breaking changes people will already be on the alert?

@nikosbosse
Copy link
Contributor Author

Maybe we should just be cruel? I don't know, the downside to aliases that I see is that they clutter the docs and the autocomplete dropdown

@nikosbosse
Copy link
Contributor Author

Dear future user, if you're reading this and are upset: we apologise for our cruelty. Please blame it on me and only me.
I think the change is a bit annoying, but you're code is going to break anyways, regardless of whether we keep the s or not. So we might as well break everything hard this time..
But happy to open an issue if we think it's useful.

@nikosbosse nikosbosse merged commit f7b5283 into main Mar 22, 2024
11 of 12 checks passed
@nikosbosse nikosbosse deleted the rename-pairwise-comparison branch March 22, 2024 14:55
@nikosbosse nikosbosse restored the rename-pairwise-comparison branch March 22, 2024 14:55
@nikosbosse nikosbosse deleted the rename-pairwise-comparison branch March 22, 2024 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants