Repository navigation
DOC: more barycenter and centroid equivalence - #8630
Merged
MridulS merged 13 commits intoApr 25, 2026
Merged
Conversation
Member
|
I think we dont want to add the barycenter name where it doesnt already occur (i.e. in the tree subpackage) |
Member
Author
|
@dschult Would the desirable state be that the only place |
Contributor
|
We definitely don't want to add a |
dschult
reviewed
Apr 23, 2026
dschult
reviewed
Apr 23, 2026
dschult
left a comment
Member
There was a problem hiding this comment.
I think we should go ahead and remove barycenter from the docs TOC too:
in doc/reference/algorithms/distance_measrues.rst.
And another thing (I would say "finally", but that would tempt fate), can we add in the centroid docs (line 738?)
.. versionchanged:: 3.7
centroid() is created by a renaming of barycenter().
The old name still works to call this function.
Peiffap
commented
Apr 24, 2026
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 #8491.
Follow-up to #8622.
nx.barycenterpoint to the same function object asnx.centroid, to prevent drift and to share docstrings, and add a regression test to assert this.centroidthe default terminology.