Skip to content

Refactor: update API for network_p2p() #228

Merged
martinctc merged 32 commits into
mainfrom
refactor/streamline-network_p2p
Aug 21, 2023
Merged

Refactor: update API for network_p2p() #228
martinctc merged 32 commits into
mainfrom
refactor/streamline-network_p2p

Conversation

@martinctc

@martinctc martinctc commented Jul 1, 2022

Copy link
Copy Markdown
Member

Summary

This branch overhauls the API design and features of network_p2p() in order to make the function usage more intuitive, and to add in the additional features around calculating network centrality. This branch mainly addresses #225. The version is also updated to v1.9.0, and a version has been pushed to CRAN.

In the commit history, network_p2p_test() is added as a temporary draft of the original network_p2p() function to enable easier testing and troubleshooting.

Changes

The changes made in this PR are:

network_p2p()

  • network_p2p() now has a centrality argument for computing and visualizing centrality as node sizes in the network plot
  • the algorithm argument is renamed to layout for better intuitiveness
  • Improved consistency and intuitiveness of the API, with style argument now controlling the network plotting mechanism and return argument controlling whether plots are generated interactively or saved as PDF
  • Added a large number of community detection algorithms from igraph
  • network_louvain() and network_leiden() have been removed.

network_summary()

network_summary() adds the ability to return pagerank.

create_dt

This version also includes some minor dependency maintenance done to create_dt().

Checks

  • All R CMD checks pass
  • roxygen2::roxygenise() has been run prior to merging to ensure that .Rd and NAMESPACE files are up to date.
  • NEWS.md has been updated.

Notes

This fixes #225.

@martinctc martinctc self-assigned this Jul 1, 2022
@martinctc martinctc added the refactor Code that neither fixes a bug nor changes feature label Aug 11, 2022
@martinctc martinctc marked this pull request as ready for review August 21, 2023 14:59
@martinctc martinctc merged commit 2c017f9 into main Aug 21, 2023
@martinctc martinctc deleted the refactor/streamline-network_p2p branch August 21, 2023 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactor Code that neither fixes a bug nor changes feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature request: Improvements to network_p2p()

1 participant