Skip to content

Commit 00705ce

Browse files
authored
docs: reorganize function reference (#662)
2 parents 5b4d19d + 2d25e9f commit 00705ce

File tree

208 files changed

+1813
-507
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

208 files changed

+1813
-507
lines changed

.github/workflows/pkgdown.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
33
on:
44
push:
5-
branches: [main, master, config-draft]
5+
branches: [main, master]
66
pull_request:
77
branches: [main, master]
88
release:

R/aaa-auto.R

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1518,6 +1518,8 @@ count_triangles <- function(graph, vids=V(graph)) {
15181518
res
15191519
}
15201520

1521+
#' @family triangles
1522+
#' @rdname count_triangles
15211523
#' @export
15221524
triangles <- function(graph) {
15231525
# Argument checks
@@ -2143,6 +2145,7 @@ embed_adjacency_matrix <- function(graph, no, weights=NULL, which=c("lm", "la",
21432145
res
21442146
}
21452147

2148+
#' @family embedding
21462149
#' @export
21472150
embed_laplacian_matrix <- function(graph, no, weights=NULL, which=c("lm", "la", "sa"), type=c("default", "D-A", "DAD", "I-DAD", "OAP"), scaled=TRUE, options=igraph.arpack.default) {
21482151
# Argument checks

R/attributes.R

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
#' @return A list of graph attributes, or a single graph attribute.
4444
#'
4545
#' @aliases get.graph.attribute graph.attributes
46-
#' @family graph attributes
46+
#' @family attributes
4747
#'
4848
#' @export
4949
#' @examples
@@ -72,7 +72,7 @@ graph_attr <- function(graph, name) {
7272
#' @return The graph, with the attribute(s) added.
7373
#'
7474
#' @aliases graph.attributes<-
75-
#' @family graph attributes
75+
#' @family attributes
7676
#'
7777
#' @export
7878
#' @examples
@@ -102,7 +102,7 @@ graph_attr <- function(graph, name) {
102102
#' @param value New value of the attribute.
103103
#' @return The graph with the new graph attribute added or set.
104104
#'
105-
#' @family graph attributes
105+
#' @family attributes
106106
#' @aliases set.graph.attribute
107107
#'
108108
#' @export
@@ -152,7 +152,7 @@ graph.attributes <- function(graph) {
152152
#' all vertex attributes, if `name` is missing.
153153
#'
154154
#' @aliases get.vertex.attribute vertex.attributes
155-
#' @family graph attributes
155+
#' @family attributes
156156
#'
157157
#' @export
158158
#' @examples
@@ -197,7 +197,7 @@ vertex_attr <- function(graph, name, index = V(graph)) {
197197
#' @return The graph, with the vertex attribute(s) added or set.
198198
#'
199199
#' @aliases vertex.attributes<-
200-
#' @family graph attributes
200+
#' @family attributes
201201
#'
202202
#' @export
203203
#' @examples
@@ -229,7 +229,7 @@ vertex_attr <- function(graph, name, index = V(graph)) {
229229
#' @return The graph, with the vertex attribute added or set.
230230
#'
231231
#' @aliases set.vertex.attribute
232-
#' @family graph attributes
232+
#' @family attributes
233233
#'
234234
#' @export
235235
#' @examples
@@ -363,7 +363,7 @@ vertex.attributes <- function(graph, index = V(graph)) {
363363
#' edge attributes if `name` is missing.
364364
#'
365365
#' @aliases get.edge.attribute edge.attributes
366-
#' @family graph attributes
366+
#' @family attributes
367367
#'
368368
#' @export
369369
#' @examples
@@ -407,7 +407,7 @@ edge_attr <- function(graph, name, index = E(graph)) {
407407
#' @return The graph, with the edge attribute(s) added or set.
408408
#'
409409
#' @aliases edge.attributes<-
410-
#' @family graph attributes
410+
#' @family attributes
411411
#'
412412
#' @export
413413
#' @examples
@@ -439,7 +439,7 @@ edge_attr <- function(graph, name, index = E(graph)) {
439439
#' @return The graph, with the edge attribute added or set.
440440
#'
441441
#' @aliases set.edge.attribute
442-
#' @family graph attributes
442+
#' @family attributes
443443
#'
444444
#' @export
445445
#' @examples
@@ -567,7 +567,7 @@ edge.attributes <- function(graph, index = E(graph)) {
567567
#' @return Character vector, the names of the graph attributes.
568568
#'
569569
#' @aliases list.graph.attributes attributes
570-
#' @family graph attributes
570+
#' @family attributes
571571
#'
572572
#' @export
573573
#' @examples
@@ -590,7 +590,7 @@ graph_attr_names <- function(graph) {
590590
#' @return Character vector, the names of the vertex attributes.
591591
#'
592592
#' @aliases list.vertex.attributes
593-
#' @family graph attributes
593+
#' @family attributes
594594
#'
595595
#' @export
596596
#' @examples
@@ -617,7 +617,7 @@ vertex_attr_names <- function(graph) {
617617
#' @return Character vector, the names of the edge attributes.
618618
#'
619619
#' @aliases list.edge.attributes
620-
#' @family graph attributes
620+
#' @family attributes
621621
#'
622622
#' @export
623623
#' @examples
@@ -643,7 +643,7 @@ edge_attr_names <- function(graph) {
643643
#' @return The graph, with the specified attribute removed.
644644
#'
645645
#' @aliases remove.graph.attribute
646-
#' @family graph attributes
646+
#' @family attributes
647647
#'
648648
#' @export
649649
#' @examples
@@ -673,7 +673,7 @@ delete_graph_attr <- function(graph, name) {
673673
#' @return The graph, with the specified vertex attribute removed.
674674
#'
675675
#' @aliases remove.vertex.attribute
676-
#' @family graph attributes
676+
#' @family attributes
677677
#'
678678
#' @export
679679
#' @examples
@@ -704,7 +704,7 @@ delete_vertex_attr <- function(graph, name) {
704704
#' @return The graph, with the specified edge attribute removed.
705705
#'
706706
#' @aliases remove.edge.attribute
707-
#' @family graph attributes
707+
#' @family attributes
708708
#'
709709
#' @export
710710
#' @examples
@@ -809,6 +809,7 @@ is_weighted <- function(graph) {
809809
}
810810

811811
#' @rdname make_bipartite_graph
812+
#' @family bipartite
812813
#' @export
813814
is_bipartite <- function(graph) {
814815
if (!is_igraph(graph)) {
@@ -895,6 +896,7 @@ igraph.i.attribute.combination <- function(comb) {
895896
#' new edge should be sum of the weights of the corresponding edges in the old
896897
#' graph; and that the rest of the attributes should be ignored (=dropped).
897898
#'
899+
#' @family attributes
898900
#' @name igraph-attribute-combination
899901
#' @aliases attribute.combination
900902
#' @section Predefined combination functions: The following combination
@@ -971,7 +973,7 @@ NULL
971973
#' @method $ igraph
972974
#' @name igraph-dollar
973975
#' @export
974-
#' @family graph attributes
976+
#' @family attributes
975977
#' @examples
976978
#' g <- make_ring(10)
977979
#' g$name

R/centrality.R

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ estimate_closeness <- function(graph, vids = V(graph), mode = c("out", "in", "al
303303
}
304304

305305
#' @rdname arpack
306-
#' @family centrality
306+
#' @family arpack
307307
#' @export
308308
arpack_defaults <- list(
309309
bmat = "I", n = 0, which = "XX", nev = 1, tol = 0.0,
@@ -497,7 +497,7 @@ arpack_defaults <- list(
497497
#' which = "LM", maxiter = 2000
498498
#' ))
499499
#' }
500-
#' @family centrality
500+
#' @family arpack
501501
#' @export
502502
arpack <- function(func, extra = NULL, sym = FALSE, options = arpack_defaults,
503503
env = parent.frame(), complex = !sym) {
@@ -909,6 +909,7 @@ diversity <- diversity
909909
#' g2 <- make_ring(10)
910910
#' hub_score(g2)$vector
911911
#' authority_score(g2)$vector
912+
#' @family centrality
912913
hub_score <- hub_score
913914

914915

R/community.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2548,6 +2548,6 @@ communities <- groups.communities
25482548
#' ## combined using the 'toString' function.
25492549
#' print(g2, g = TRUE, v = TRUE, e = TRUE)
25502550
#'
2551-
#' @family community
25522551
#' @export
2552+
#' @family functions for manipulating graph structure
25532553
contract <- contract

R/decomposition.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
#' linear-time algorithms to test chordality of graphs, test acyclicity of
6464
#' hypergraphs, and selectively reduce acyclic hypergraphs. *SIAM Journal
6565
#' of Computation* 13, 566--579.
66-
#' @family decomposition
66+
#' @family chordal
6767
#' @export
6868
#' @keywords graphs
6969
#' @examples

R/embedding.R

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@
8888
#' })
8989
#' RDP <- sample_dot_product(lpvs)
9090
#' embed <- embed_adjacency_matrix(RDP, 5)
91+
#' @family embedding
9192
#' @export
9293
embed_adjacency_matrix <- embed_adjacency_matrix
9394

@@ -148,6 +149,7 @@ embed_adjacency_matrix <- embed_adjacency_matrix
148149
#' RDP.graph.3 <- sample_dot_product(lpvs.sph)
149150
#' dim_select(embed_adjacency_matrix(RDP.graph.3, 10)$D)
150151
#'
152+
#' @family embedding
151153
#' @export
152154
dim_select <- dim_select
153155

R/epi.R

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,15 @@
1919
#
2020
###################################################################
2121

22-
#' @family epi
22+
#' @family processes
2323
#' @export
2424
time_bins <- function(x, middle = TRUE) {
2525
UseMethod("time_bins")
2626
}
2727

2828
#' @method time_bins sir
2929
#' @rdname sir
30-
#' @family epi
30+
#' @family processes
3131
#' @export
3232
#' @importFrom stats IQR
3333
time_bins.sir <- function(x, middle = TRUE) {
@@ -52,7 +52,7 @@ time_bins.sir <- function(x, middle = TRUE) {
5252
#' @importFrom stats median
5353
#' @method median sir
5454
#' @rdname sir
55-
#' @family epi
55+
#' @family processes
5656
#' @export
5757
median.sir <- function(x, na.rm = FALSE, ...) {
5858
sir <- x
@@ -73,7 +73,7 @@ median.sir <- function(x, na.rm = FALSE, ...) {
7373
#' @importFrom stats quantile
7474
#' @method quantile sir
7575
#' @rdname sir
76-
#' @family epi
76+
#' @family processes
7777
#' @export
7878
quantile.sir <- function(x, comp = c("NI", "NS", "NR"), prob, ...) {
7979
sir <- x
@@ -144,7 +144,7 @@ quantile.sir <- function(x, comp = c("NI", "NS", "NR"), prob, ...) {
144144
#' @references Bailey, Norman T. J. (1975). The mathematical theory of
145145
#' infectious diseases and its applications (2nd ed.). London: Griffin.
146146
#' @method plot sir
147-
#' @family epi
147+
#' @family processes
148148
#' @export
149149
#' @importFrom graphics plot lines
150150
#' @keywords graphs

R/eulerian.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,21 +59,21 @@
5959
#' has_eulerian_cycle(g)
6060
#' try(eulerian_cycle(g))
6161
#'
62-
#' @family eulerian
62+
#' @family cycles
6363
#' @export
6464
has_eulerian_path <- function(graph) is_eulerian(graph)$has_path
6565

6666
#' @rdname has_eulerian_path
67-
#' @family eulerian
67+
#' @family cycles
6868
#' @export
6969
has_eulerian_cycle <- function(graph) is_eulerian(graph)$has_cycle
7070

7171
#' @rdname has_eulerian_path
72-
#' @family eulerian
72+
#' @family cycles
7373
#' @export
7474
eulerian_path <- eulerian_path
7575

7676
#' @rdname has_eulerian_path
77-
#' @family eulerian
77+
#' @family cycles
7878
#' @export
7979
eulerian_cycle <- eulerian_cycle

R/flow.R

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -614,6 +614,7 @@ dominator_tree <- function(graph, root, mode = c("out", "in", "all", "total")) {
614614
#'
615615
#' chvatal <- make_graph("chvatal")
616616
#' min_st_separators(chvatal)
617+
#' @family flow
617618
min_st_separators <- min_st_separators
618619

619620

0 commit comments

Comments
 (0)