Repository navigation
refactor: Rename algorithm-selection arguments to algorithm and measure selection to measure - #2951
Merged
schochastics merged 37 commits intoDec 3, 2026
Conversation
…sure selection to `measure` `method` (isomorphism functions, `sample_tree()`, `sample_degseq()`, `realize_degseq()`, `realize_bipartite_degseq()`, `merge_coords()`), `impl` (`induced_subgraph()`), `implementation` (`cluster_spinglass()`, `fit_power_law()`) and `heuristic` (`greedy_vertex_coloring()`) become `algorithm`; `method` in `compare()` and `similarity()` becomes `measure`. Legacy names are recovered with a soft-deprecation. Closes #2932. Part of #2788. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This was referenced Oct 15, 2026
Merged
Contributor
|
This is how benchmark results would change (along with a 95% confidence interval in relative change) if 809e79f is merged into claude/issue-2788-subagents-faw1t1-13:
|
…e-2788-subagents-faw1t1-14 # Conflicts: # man/cluster_spinglass.Rd # man/degree.sequence.game.Rd # man/fit_power_law.Rd # man/realize_bipartite_degseq.Rd # man/realize_degseq.Rd # man/sample_degseq.Rd # man/spinglass.community.Rd
…e-2788-subagents-faw1t1-14 # Conflicts: # R/coloring.R # R/community.R # R/games.R # R/layout.R # R/make.R # R/similarity.R # R/structural-properties.R # tests/testthat/_snaps/topology.md # tests/testthat/test-community.R # tests/testthat/test-games.R # tests/testthat/test-layout.R
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14
Contributor
|
This is how benchmark results would change (along with a 95% confidence interval in relative change) if ff6dfb8 is merged into claude/issue-2788-subagents-faw1t1-13:
Further explanation regarding interpretation and methodology can be found in the documentation. Last updated for commit ff6dfb8. |
…e-2788-subagents-faw1t1-14 # Conflicts: # R/fit.R # tests/testthat/test-games.R # tests/testthat/test-similarity.R # tests/testthat/test-structural-properties.R # tests/testthat/test-topology.R
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14 # Conflicts: # tests/testthat/_snaps/structural-properties.md
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14
…e-2788-subagents-faw1t1-14 # Conflicts: # tests/testthat/_snaps/structural-properties.md
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e-2788-subagents-faw1t1-14 # Conflicts: # R/fit.R # R/games.R
… values follow `fit_power_law(implementation = )` joins the registry entry, so the generator re-matches calls that use any of its old names against the old signature and the hand-written bridges are gone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t1-13' into HEAD # Conflicts: # revdep/README.md # revdep/cran.md # revdep/failures.md # revdep/manifest.json # revdep/problems.md # revdep/problems/glyrepr.md # revdep/problems/manynet.md # revdep/problems/nat.md # revdep/problems/netrics.md # revdep/problems/tidygraph.md
This was referenced Dec 3, 2026
schochastics
added a commit
to schochastics/rigraph
that referenced
this pull request
Dec 4, 2026
…sure selection to `measure` (igraph#2951) Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Co-authored-by: krlmlr <krlmlr@users.noreply.github.com> Co-authored-by: schochastics <schochastics@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> (cherry picked from commit 004a6ba)
schochastics
added a commit
to schochastics/rigraph
that referenced
this pull request
Dec 4, 2026
…sure selection to `measure` (igraph#2951) Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Co-authored-by: krlmlr <krlmlr@users.noreply.github.com> Co-authored-by: schochastics <schochastics@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> (cherry picked from commit 004a6ba)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #2932. Part of #2788 (PR 14 of the stack, on top of #2950).
This implements the two-word proposal from #2932 (#2932 (comment)):
algorithmfor how something is computed,measurefor what is computed.What this does
→ algorithm:methodin the isomorphism family:isomorphic(),subgraph_isomorphic(),count_isomorphisms(),count_subgraph_isomorphisms(),isomorphisms(),subgraph_isomorphisms()(the aliasesis_isomorphic_to()andis_subgraph_isomorphic_to()follow)methodinsample_tree(),sample_degseq(),realize_degseq(),realize_bipartite_degseq(),merge_coords()implininduced_subgraph()implementationincluster_spinglass()andfit_power_law()heuristicingreedy_vertex_coloring()→ measure:methodincompare()(generic and itscommunities/membership/defaultmethods) andsimilarity()Unchanged by design:
layout_with_fr(grid)(an acceleration switch) andmake_clusters(algorithm)(a free-text label read back byalgorithm()). With this PR, no live exported function has amethodargument any more.How
sample_tree(),sample_degseq(),realize_degseq(),merge_coords(),induced_subgraph(),cluster_spinglass(),greedy_vertex_coloring(),similarity()): legacy names are recovered under the standard single soft-deprecation.fit_power_law(), plusrealize_bipartite_degseq()andcompare(): positional calls are unchanged and silent, and the old name stays as a trailingmethod/implementation=deprecated()formal.fit_power_law()has a registry entry, so the generated block handles its rename (see refactor: Renamealgotoalgorithminpage_rank(),feedback_arc_set()andfeedback_vertex_set()#2859). The isomorphism functions,realize_bipartite_degseq()andcompare()have none and use a hand-written bridge. Forcompare()the formal and bridge live in the S3 methods, which must share the generic's formals, because a value reassigned in the generic does not reach the method....to the per-algorithm backends. An abbreviatedmeth =used to partial-match the head formal and now lands in....component_wise()→merge_coords()). Thesample_degseq()messages for retired values ("simple", …) now sayalgorithm =. Deprecated wrappers (graph.isomorphic(),similarity.jaccard(),degree.sequence.game(), …) are untouched; only their "please usesimilarity()with …" hints now namemeasure.Tests
There are
expect_legacy_arg()checks for every renamed function, including the spec twinstree()/degseq(), a positional call, and the conflict error when both spellings are supplied.The #2788 stack
Each PR is based on the previous one and merges in this order:
algotoalgorithminpage_rank(),feedback_arc_set()andfeedback_vertex_set()#2859:algo→algorithmnodestonin generators andcentr_*_tmax()#2860:nodes→n(vertex counts)cluster_infomap()#2861: weights argumentsnormalized#2862: normalization flags →normalizedverticesandvertex#2864: selectors →vertices/vertexedges#2943: edge selectors →edgesindextovertices/edgesin the attribute accessors #2944: attribute accessors:index→vertices/edgesn_iter/max_iter#2945: iterations →n_iter/max_iterMu→mu)algorithm/measure(Algorithm-selection argument names: census ofmethod/algorithm/algo/impl/implementation#2932)🤖 Generated with Claude Code