@@ -2509,8 +2509,8 @@ sample_sbm <- function(
25092509) {
25102510 sbm_game_impl(
25112511 n = n ,
2512- pref.matrix = pref.matrix ,
2513- block.sizes = block.sizes ,
2512+ pref_matrix = pref.matrix ,
2513+ block_sizes = block.sizes ,
25142514 directed = directed ,
25152515 loops = loops
25162516 )
@@ -2693,12 +2693,22 @@ dot_product <- function(...) constructor_spec(sample_dot_product, ...)
26932693# ' @export
26942694# ' @cdocs igraph_simple_interconnected_islands_game
26952695sample_islands <- function (islands.n , islands.size , islands.pin , n.inter ) {
2696- simple_interconnected_islands_game_impl(
2697- islands.n = islands.n ,
2698- islands.size = islands.size ,
2699- islands.pin = islands.pin ,
2700- n.inter = n.inter
2696+ res <- simple_interconnected_islands_game_impl(
2697+ islands_n = islands.n ,
2698+ islands_size = islands.size ,
2699+ islands_pin = islands.pin ,
2700+ n_inter = n.inter
27012701 )
2702+
2703+ # Add backward-compatible dotted names
2704+ if (igraph_opt(" add.params" )) {
2705+ res $ islands.n <- res $ islands_n
2706+ res $ islands.size <- res $ islands_size
2707+ res $ islands.pin <- res $ islands_pin
2708+ res $ n.inter <- res $ n_inter
2709+ }
2710+
2711+ res
27022712}
27032713
27042714
@@ -2745,7 +2755,7 @@ sample_k_regular <- function(
27452755 multiple = FALSE
27462756) {
27472757 k_regular_game_impl(
2748- no.of.nodes = no.of.nodes ,
2758+ no_of_nodes = no.of.nodes ,
27492759 k = k ,
27502760 directed = directed ,
27512761 multiple = multiple
@@ -2907,8 +2917,8 @@ sample_chung_lu <- function(
29072917 variant = c(" original" , " maxent" , " nr" )
29082918) {
29092919 chung_lu_game_impl(
2910- out.weights = out.weights ,
2911- in .weights = in .weights ,
2920+ out_weights = out.weights ,
2921+ in_weights = in .weights ,
29122922 loops = loops ,
29132923 variant = variant
29142924 )
@@ -3002,9 +3012,9 @@ sample_fitness <- function(
30023012 multiple = FALSE
30033013) {
30043014 static_fitness_game_impl(
3005- no.of.edges = no.of.edges ,
3006- fitness.out = fitness.out ,
3007- fitness.in = fitness.in ,
3015+ no_of_edges = no.of.edges ,
3016+ fitness_out = fitness.out ,
3017+ fitness_in = fitness.in ,
30083018 loops = loops ,
30093019 multiple = multiple
30103020 )
@@ -3084,15 +3094,24 @@ sample_fitness_pl <- function(
30843094 multiple = FALSE ,
30853095 finite.size.correction = TRUE
30863096) {
3087- static_power_law_game_impl(
3088- no.of.nodes = no.of.nodes ,
3089- no.of.edges = no.of.edges ,
3090- exponent.out = exponent.out ,
3091- exponent.in = exponent.in ,
3097+ res <- static_power_law_game_impl(
3098+ no_of_nodes = no.of.nodes ,
3099+ no_of_edges = no.of.edges ,
3100+ exponent_out = exponent.out ,
3101+ exponent_in = exponent.in ,
30923102 loops = loops ,
30933103 multiple = multiple ,
3094- finite.size.correction = finite.size.correction
3104+ finite_size_correction = finite.size.correction
30953105 )
3106+
3107+ # Add backward-compatible dotted names
3108+ if (igraph_opt(" add.params" )) {
3109+ res $ exponent.out <- res $ exponent_out
3110+ res $ exponent.in <- res $ exponent_in
3111+ res $ finite.size.correction <- res $ finite_size_correction
3112+ }
3113+
3114+ res
30963115}
30973116
30983117
@@ -3163,13 +3182,21 @@ sample_forestfire <- function(
31633182 ambs = 1 ,
31643183 directed = TRUE
31653184) {
3166- forest_fire_game_impl(
3185+ res <- forest_fire_game_impl(
31673186 nodes = nodes ,
3168- fw.prob = fw.prob ,
3169- bw.factor = bw.factor ,
3187+ fw_prob = fw.prob ,
3188+ bw_factor = bw.factor ,
31703189 ambs = ambs ,
31713190 directed = directed
31723191 )
3192+
3193+ # Add backward-compatible dotted names
3194+ if (igraph_opt(" add.params" )) {
3195+ res $ fw.prob <- res $ fw_prob
3196+ res $ bw.factor <- res $ bw_factor
3197+ }
3198+
3199+ res
31733200}
31743201
31753202
@@ -3217,7 +3244,7 @@ sample_correlated_gnp <- function(
32173244 permutation = NULL
32183245) {
32193246 correlated_game_impl(
3220- old.graph = old.graph ,
3247+ old_graph = old.graph ,
32213248 corr = corr ,
32223249 p = p ,
32233250 permutation = permutation
0 commit comments