File tree 1 file changed +8
-7
lines changed
1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -291,18 +291,19 @@ plot_role_network <- function(role_network,
291
291
}
292
292
293
293
294
- # ' Bootstraps measure by sampling n_samples networks from the role_ensemble.
294
+ # ' Bootstraps measure by sampling networks from role_ensemble.
295
295
# '
296
- # ' @param role_ensemble ...
297
- # ' @param measure ...
298
- # ' @param n_samples ...
299
- # ' @param n_cores ...
300
- # ' @returns ...
296
+ # ' @param role_ensemble BCCM ensemble from which to sample networks.
297
+ # ' @param measure The measure to bootstrap. It must be a function taking 1 arg,
298
+ # ' an igraph::graph.
299
+ # ' @param n_samples Number of networks to sample.
300
+ # ' @param n_cores Number of cores for parallel execution.
301
+ # ' @returns The bootstrapped values as a vector of length `n_samples`.
301
302
# ' @export
302
303
benchmark_scenario <- function (role_ensemble , measure , n_samples = 10000 ,
303
304
n_cores = 1 ) {
304
305
305
- # Define helper function run in parallel
306
+ # Helper function
306
307
boot <- function (adj , measure , directed ) {
307
308
mode <- if (directed ) " directed" else " undirected"
308
309
return (measure(graph_from_adjacency_matrix(adj , mode = mode )))
You can’t perform that action at this time.
0 commit comments