Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 1 addition & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,11 +154,7 @@ pak::pak("igraph/igraph.r2cdocs")
[roxygen2](https://roxygen2.r-lib.org/), and run `devtools::document()` or `make
igraph` to update the `.Rd` files.

- Links to C docs are added using the cdocs tag, for instance:

```
#' @cdocs igraph_assortativity
```
- Links to C docs are added automatically thanks to the igraph.r2cdocs's roclet.

### Maintaining igraph.r2cdocs

Expand Down
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ Config/testthat/start-first: aaa-auto, vs-es, scan, vs-operators, weakref,
watts.strogatz.game
Encoding: UTF-8
Roxygen: list(markdown = TRUE, roclets = c("collate", "rd", "namespace",
"igraph.r2cdocs::cdocs_roclet", "devtag::dev_roclet"), packages =
"igraph.r2cdocs::docs_rd", "devtag::dev_roclet"), packages =
"igraph.r2cdocs")
RoxygenNote: 7.3.3.9000
SystemRequirements: libxml2 (optional), glpk (>= 4.57, optional)
3 changes: 0 additions & 3 deletions R/assortativity.R
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,6 @@ assortativity.degree <- function(graph, directed = TRUE) {
#'
#' # BA model, tends to be dissortative
#' assortativity_degree(sample_pa(10000, m = 4))
#' @cdocs igraph_assortativity
assortativity <- function(
graph,
values,
Expand Down Expand Up @@ -240,7 +239,6 @@ assortativity_legacy <- function(
#' with [as.integer()].
#' @rdname assortativity
#' @export
#' @cdocs igraph_assortativity_nominal
assortativity_nominal <- function(
graph,
types,
Expand All @@ -257,7 +255,6 @@ assortativity_nominal <- function(

#' @rdname assortativity
#' @export
#' @cdocs igraph_assortativity_degree
assortativity_degree <- function(graph, directed = TRUE) {
assortativity_degree_impl(
graph = graph,
Expand Down
2 changes: 0 additions & 2 deletions R/bipartite.R
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,6 @@ bipartite_projection <- function(

#' @rdname bipartite_projection
#' @export
#' @cdocs igraph_bipartite_projection_size
bipartite_projection_size <- function(graph, types = NULL) {
bipartite_projection_size_impl(
graph = graph,
Expand Down Expand Up @@ -283,7 +282,6 @@ bipartite_projection_size <- function(graph, types = NULL) {
#' bipartite_mapping(g3)
#' @family bipartite
#' @export
#' @cdocs igraph_is_bipartite
bipartite_mapping <- function(graph) {
is_bipartite_impl(
graph = graph
Expand Down
6 changes: 0 additions & 6 deletions R/centrality.R
Original file line number Diff line number Diff line change
Expand Up @@ -1291,7 +1291,6 @@ eigen_defaults <- function() {
#' eigen_centrality(g)
#' @family centrality
#' @export
#' @cdocs igraph_eigenvector_centrality
eigen_centrality <- function(
graph,
directed = FALSE,
Expand Down Expand Up @@ -1371,7 +1370,6 @@ eigen_centrality <- function(
#' strength(g)
#' @family centrality
#' @export
#' @cdocs igraph_strength
strength <- function(
graph,
vids = V(graph),
Expand Down Expand Up @@ -1429,7 +1427,6 @@ strength <- function(
#' diversity(g3)
#' @family centrality
#' @export
#' @cdocs igraph_diversity
diversity <- function(graph, weights = NULL, vids = V(graph)) {
diversity_impl(
graph = graph,
Expand Down Expand Up @@ -1497,7 +1494,6 @@ diversity <- function(graph, weights = NULL, vids = V(graph)) {
#' g2 <- make_ring(10)
#' hits_scores(g2)
#' @family centrality
#' @cdocs igraph_hub_and_authority_scores
hits_scores <- function(
graph,
...,
Expand Down Expand Up @@ -1681,7 +1677,6 @@ hub_score <- function(
#' page_rank(g3, personalized = reset)$vector
#' @family centrality
#' @export
#' @cdocs igraph_personalized_pagerank
page_rank <- function(
graph,
algo = c("prpack", "arpack"),
Expand Down Expand Up @@ -1749,7 +1744,6 @@ page_rank <- function(
#' harmonic_centrality(g2, mode = "out")
#' harmonic_centrality(g %du% make_full_graph(5), mode = "all")
#'
#' @cdocs igraph_harmonic_centrality_cutoff
harmonic_centrality <- function(
graph,
vids = V(graph),
Expand Down
7 changes: 0 additions & 7 deletions R/centralization.R
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,6 @@ NULL
#' g1 <- make_star(10, mode = "undirected")
#' centr_eigen(g0)$centralization
#' centr_eigen(g1)$centralization
#' @cdocs igraph_centralization
centralize <- function(scores, theoretical.max = 0, normalized = TRUE) {
centralization_impl(
scores = scores,
Expand Down Expand Up @@ -362,7 +361,6 @@ centralize <- function(scores, theoretical.max = 0, normalized = TRUE) {
#' centr_clo(g, mode = "all")$centralization
#' centr_betw(g, directed = FALSE)$centralization
#' centr_eigen(g, directed = FALSE)$centralization
#' @cdocs igraph_centralization_degree
centr_degree <- function(
graph,
mode = c("all", "out", "in", "total"),
Expand Down Expand Up @@ -511,7 +509,6 @@ centr_betw <- function(graph, directed = TRUE, normalized = TRUE) {
#' centr_betw(g, normalized = FALSE)$centralization %>%
#' `/`(centr_betw_tmax(g))
#' centr_betw(g, normalized = TRUE)$centralization
#' @cdocs igraph_centralization_betweenness_tmax
centr_betw_tmax <- function(graph = NULL, nodes = 0, directed = TRUE) {
centralization_betweenness_tmax_impl(
graph = graph,
Expand Down Expand Up @@ -556,7 +553,6 @@ centr_betw_tmax <- function(graph = NULL, nodes = 0, directed = TRUE) {
#' centr_clo(g, mode = "all")$centralization
#' centr_betw(g, directed = FALSE)$centralization
#' centr_eigen(g, directed = FALSE)$centralization
#' @cdocs igraph_centralization_closeness
centr_clo <- function(
graph,
mode = c("out", "in", "all", "total"),
Expand Down Expand Up @@ -593,7 +589,6 @@ centr_clo <- function(
#' centr_clo(g, normalized = FALSE)$centralization %>%
#' `/`(centr_clo_tmax(g))
#' centr_clo(g, normalized = TRUE)$centralization
#' @cdocs igraph_centralization_closeness_tmax
centr_clo_tmax <- function(
graph = NULL,
nodes = 0,
Expand Down Expand Up @@ -655,7 +650,6 @@ centr_clo_tmax <- function(
#' g1 <- make_star(10, mode = "undirected")
#' centr_eigen(g0)$centralization
#' centr_eigen(g1)$centralization
#' @cdocs igraph_centralization_eigenvector_centrality
centr_eigen <- function(
graph,
directed = FALSE,
Expand Down Expand Up @@ -707,7 +701,6 @@ centr_eigen <- function(
#' centr_eigen(g, normalized = FALSE)$centralization %>%
#' `/`(centr_eigen_tmax(g))
#' centr_eigen(g, normalized = TRUE)$centralization
#' @cdocs igraph_centralization_eigenvector_centrality_tmax
centr_eigen_tmax <- function(
graph = NULL,
nodes = 0,
Expand Down
11 changes: 0 additions & 11 deletions R/cliques.R
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,6 @@ clique.number <- function(graph) {
#'
#' # Check that all returned vertex sets are indeed cliques
#' all(sapply(max_cliques(g), function (c) is_clique(g, c)))
#' @cdocs igraph_cliques
cliques <- function(graph, min = 0, max = 0) {
cliques_impl(
graph = graph,
Expand All @@ -249,7 +248,6 @@ cliques <- function(graph, min = 0, max = 0) {

#' @rdname cliques
#' @export
#' @cdocs igraph_largest_cliques
largest_cliques <- function(graph) {
largest_cliques_impl(
graph = graph
Expand Down Expand Up @@ -361,7 +359,6 @@ count_max_cliques <- function(graph, min = NULL, max = NULL, subset = NULL) {

#' @rdname cliques
#' @export
#' @cdocs igraph_clique_number
clique_num <- function(graph) {
clique_number_impl(
graph = graph
Expand Down Expand Up @@ -418,7 +415,6 @@ clique_num <- function(graph) {
#' weighted_cliques(g, maximal = TRUE)
#' largest_weighted_cliques(g)
#' weighted_clique_num(g)
#' @cdocs igraph_weighted_cliques
weighted_cliques <- function(
graph,
vertex.weights = NULL,
Expand All @@ -436,7 +432,6 @@ weighted_cliques <- function(
}
#' @export
#' @rdname cliques
#' @cdocs igraph_largest_weighted_cliques
largest_weighted_cliques <- function(graph, vertex.weights = NULL) {
largest_weighted_cliques_impl(
graph = graph,
Expand All @@ -445,7 +440,6 @@ largest_weighted_cliques <- function(graph, vertex.weights = NULL) {
}
#' @export
#' @rdname cliques
#' @cdocs igraph_weighted_clique_number
weighted_clique_num <- function(graph, vertex.weights = NULL) {
weighted_clique_number_impl(
graph = graph,
Expand Down Expand Up @@ -590,8 +584,6 @@ independence_number <- ivs_size

#' @rdname cliques
#' @export
#' @cdocs igraph_maximal_cliques_hist
#' @cdocs igraph_clique_size_hist
clique_size_counts <- function(graph, min = 0, max = 0, maximal = FALSE) {
if (maximal) {
maximal_cliques_hist_impl(
Expand Down Expand Up @@ -620,7 +612,6 @@ clique_size_counts <- function(graph, min = 0, max = 0, maximal = FALSE) {
#' @keywords graphs
#' @seealso [make_full_graph()]
#' @export
#' @cdocs igraph_is_complete
#' @examples
#'
#' g <- make_full_graph(6, directed = TRUE)
Expand Down Expand Up @@ -648,7 +639,6 @@ is_complete <- function(graph) {
#' a clique.
#' @keywords graphs
#' @export
#' @cdocs igraph_is_clique
is_clique <- function(graph, candidate, directed = FALSE) {
is_clique_impl(
graph = graph,
Expand All @@ -665,7 +655,6 @@ is_clique <- function(graph, candidate, directed = FALSE) {
#' independent set.
#' @keywords graphs
#' @export
#' @cdocs igraph_is_independent_vertex_set
is_ivs <- function(graph, candidate) {
is_independent_vertex_set_impl(
graph = graph,
Expand Down
1 change: 0 additions & 1 deletion R/coloring.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
#' col <- greedy_vertex_coloring(g)
#' plot(g, vertex.color = col)
#'
#' @cdocs igraph_vertex_coloring_greedy
greedy_vertex_coloring <- function(
graph,
heuristic = c("colored_neighbors", "dsatur")
Expand Down
2 changes: 0 additions & 2 deletions R/community.R
Original file line number Diff line number Diff line change
Expand Up @@ -3196,7 +3196,6 @@ communities <- groups.communities
#'
#' @export
#' @family functions for manipulating graph structure
#' @cdocs igraph_contract_vertices
contract <- function(
graph,
mapping,
Expand Down Expand Up @@ -3252,7 +3251,6 @@ contract <- function(
#'
#' @export
#' @family community
#' @cdocs igraph_voronoi
voronoi_cells <- function(
graph,
generators,
Expand Down
4 changes: 0 additions & 4 deletions R/components.R
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,6 @@ decompose <- function(
#'
#' @family components
#' @export
#' @cdocs igraph_articulation_points
articulation_points <- function(graph) {
articulation_points_impl(
graph = graph
Expand All @@ -265,7 +264,6 @@ articulation_points <- function(graph) {

#' @rdname articulation_points
#' @export
#' @cdocs igraph_bridges
bridges <- function(graph) {
bridges_impl(
graph = graph
Expand Down Expand Up @@ -320,7 +318,6 @@ bridges <- function(graph) {
#' bc <- biconnected_components(g)
#' @family components
#' @export
#' @cdocs igraph_biconnected_components
biconnected_components <- function(graph) {
# Function call
res <- biconnected_components_impl(
Expand Down Expand Up @@ -392,7 +389,6 @@ biconnected_components <- function(graph) {
#' is_biconnected(make_full_graph(2))
#' @family components
#' @export
#' @cdocs igraph_is_biconnected
is_biconnected <- function(graph) {
is_biconnected_impl(
graph = graph
Expand Down
2 changes: 0 additions & 2 deletions R/conversion.R
Original file line number Diff line number Diff line change
Expand Up @@ -599,7 +599,6 @@ as_edgelist <- function(graph, names = TRUE) {
#' )
#' print(ug4, e = TRUE)
#'
#' @cdocs igraph_to_directed
as_directed <- function(
graph,
mode = c("mutual", "arbitrary", "random", "acyclic")
Expand Down Expand Up @@ -1274,7 +1273,6 @@ as_data_frame <- function(x, what = c("edges", "vertices", "both")) {
#' which_multiple(g3)
#' @family conversion
#' @export
#' @cdocs igraph_adjlist
graph_from_adj_list <- function(
adjlist,
mode = c("out", "in", "all", "total"),
Expand Down
2 changes: 0 additions & 2 deletions R/cycles.R
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@
#' find_cycle(sample_tree(5))
#'
#' @family cycles
#' @cdocs igraph_find_cycle
#' @export

find_cycle <- function(graph, mode = c("out", "in", "all", "total")) {
Expand Down Expand Up @@ -85,7 +84,6 @@ find_cycle <- function(graph, mode = c("out", "in", "all", "total")) {
#' simple_cycles(g, mode = "all", min = 2, max = 3) # limit cycle lengths
#'
#' @family cycles
#' @cdocs igraph_simple_cycles
#' @export

simple_cycles <- function(
Expand Down
1 change: 0 additions & 1 deletion R/degseq.R
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,6 @@ is_degseq <- function(out.deg, in.deg = NULL) {
#' is_degseq(degree(g))
#' is_graphical(degree(g))
#' @export
#' @cdocs igraph_is_graphical
is_graphical <- function(
out.deg,
in.deg = NULL,
Expand Down
3 changes: 0 additions & 3 deletions R/efficiency.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@
#' g <- make_graph("zachary")
#' global_efficiency(g)
#' average_local_efficiency(g)
#' @cdocs igraph_global_efficiency
global_efficiency <- function(graph, weights = NULL, directed = TRUE) {
global_efficiency_impl(
graph = graph,
Expand All @@ -77,7 +76,6 @@ global_efficiency <- function(graph, weights = NULL, directed = TRUE) {

#' @rdname global_efficiency
#' @export
#' @cdocs igraph_local_efficiency
local_efficiency <- function(
graph,
vids = V(graph),
Expand All @@ -96,7 +94,6 @@ local_efficiency <- function(

#' @rdname global_efficiency
#' @export
#' @cdocs igraph_average_local_efficiency
average_local_efficiency <- function(
graph,
weights = NULL,
Expand Down
3 changes: 0 additions & 3 deletions R/embedding.R
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@
#' embed <- embed_adjacency_matrix(RDP, 5)
#' @family embedding
#' @export
#' @cdocs igraph_adjacency_spectral_embedding
embed_adjacency_matrix <- function(
graph,
no,
Expand Down Expand Up @@ -181,7 +180,6 @@ embed_adjacency_matrix <- function(
#'
#' @family embedding
#' @export
#' @cdocs igraph_dim_select
dim_select <- function(sv) {
dim_select_impl(
sv = sv
Expand Down Expand Up @@ -277,7 +275,6 @@ dim_select <- function(sv) {
#' RDP <- sample_dot_product(lpvs)
#' embed <- embed_laplacian_matrix(RDP, 5)
#' @family embedding
#' @cdocs igraph_laplacian_spectral_embedding
embed_laplacian_matrix <- function(
graph,
no,
Expand Down
Loading
Loading