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

Centrality update #313

Merged
merged 7 commits into from
Mar 28, 2023
Merged

Centrality update #313

merged 7 commits into from
Mar 28, 2023

Conversation

nwlandry
Copy link
Collaborator

  • Removed the ZEC_centrality because it doesn't converge and the paper by Austin Benson talks a bit about this
  • Added tests for all centrality measures.
  • Added additional tests for the xgi_data module.
  • Added the ability for centrality to handle empty/invalid hypergraphs. Because these are Node/EdgeStats, I opted to return NaN when the centralities are invalid.

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@codecov
Copy link

codecov bot commented Mar 28, 2023

Codecov Report

Patch coverage: 95.45% and project coverage change: +2.07 🎉

Comparison is base (7cc3b6b) 84.32% compared to head (803fa2a) 86.39%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #313      +/-   ##
==========================================
+ Coverage   84.32%   86.39%   +2.07%     
==========================================
  Files          35       35              
  Lines        2756     2757       +1     
==========================================
+ Hits         2324     2382      +58     
+ Misses        432      375      -57     
Impacted Files Coverage Δ
xgi/classes/function.py 100.00% <ø> (ø)
xgi/classes/hypergraph.py 85.89% <ø> (ø)
xgi/classes/simplicialcomplex.py 83.73% <ø> (ø)
xgi/drawing/draw.py 24.01% <0.00%> (ø)
xgi/drawing/layout.py 100.00% <ø> (ø)
xgi/dynamics/synchronization.py 81.66% <ø> (ø)
xgi/linalg/matrix.py 94.24% <ø> (ø)
xgi/stats/nodestats.py 72.34% <ø> (+2.34%) ⬆️
xgi/algorithms/centrality.py 97.91% <100.00%> (+34.87%) ⬆️

... and 3 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@maximelucas
Copy link
Collaborator

maximelucas commented Mar 28, 2023

Genius. Thanks so much.

Very good call adding those tests for the loading too.
This PR fixes #310 and #311 and partially fixes #298.

@nwlandry nwlandry merged commit 7d5accb into main Mar 28, 2023
@maximelucas maximelucas deleted the centrality-update branch March 28, 2023 19:32
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