Perform AIC forward selection for nrm.

nrmSelection(
  adj,
  predictors,
  directed,
  selfloops,
  pval = 0.05,
  xi = NULL,
  init = NULL,
  ncores = NULL,
  ...
)

nrm_selection(
  adj,
  predictors,
  directed,
  selfloops,
  pval = 0.05,
  xi = NULL,
  init = NULL,
  ncores = NULL,
  ...
)

# S3 method for default
nrm_selection(
  adj,
  predictors,
  directed,
  selfloops,
  pval = 0.05,
  xi = NULL,
  init = NULL,
  ncores = NULL,
  ...
)

# S3 method for nrmpredictor
nrm_selection(
  adj,
  predictors,
  directed,
  selfloops,
  pval = 0.05,
  xi = NULL,
  init = NULL,
  ncores = NULL,
  ...
)

# S3 method for nrm_selection
print(x, ...)

Arguments

adj

the adjacency matrix of the response network

predictors

list containing the set of predictors as sublists.

directed

logical, is the response network directed?

selfloops

logical, do the response network allows selfloops?

pval

the significance at which computing confidence intervals.

xi

optional, the possibility matrix \(\Xi\).

init

optional, initial values passed to the solver to estimate the MLE.

ncores

optional, number of cores over which parallelise the task.

...

optional arguments to print or plot methods.

x

object of class 'nrm_selection'.

Value

A nrm object

Methods (by class)

  • nrm_selection(default): Default method for the nrm stepwise selection.

  • nrm_selection(nrmpredictor): Method for the nrm stepwise selection when nrmpredictors are passed.

Methods (by generic)

  • print(nrm_selection): Print method for elements of class 'nrm_selection'.

See also

nrm

nrm_selection

Author

Giona Casiraghi

Examples

# \donttest{
data('highschool.predictors')
models <- nrm_selection(adj=contacts.adj,predictors=create_predictors(highschool.predictors),
  ncores=1,directed=FALSE,selfloops=FALSE)
#> Creating predictors list...
#> 
#> Estimating Null model...
#> 
#> Performing forward stepwise selection:
#> 
#> Step 1 of 5...
#> 
#> Step 2 of 5...
#> 
#> Step 3 of 5...
#> 
#> Step 4 of 5...
#> 
#> Step 5 of 5...
#> 
#> Model estimation concluded.
texreg::screenreg(models$models, digits=3)
#> 
#> ==============================================================================================
#>                 Model 1         Model 2         Model 3         Model 4         Model 5       
#> ----------------------------------------------------------------------------------------------
#> class                2.016 ***       1.914 ***       1.391 ***       1.393 ***       1.392 ***
#>                     (0.004)         (0.004)         (0.005)         (0.005)         (0.005)   
#> friendship                           0.679 ***       0.675 ***       0.703 ***       0.696 ***
#>                                     (0.002)         (0.002)         (0.002)         (0.002)   
#> topic                                                0.999 ***       1.011 ***       1.000 ***
#>                                                     (0.009)         (0.009)         (0.009)   
#> facebook                                                            -0.088 ***      -0.089 ***
#>                                                                     (0.002)         (0.002)   
#> gender                                                                               0.077 ***
#>                                                                                     (0.002)   
#> ----------------------------------------------------------------------------------------------
#> AIC             692711.753      627181.581      612308.357      610880.109      609529.798    
#> McFadden $R^2$       0.486           0.534           0.545           0.546           0.547    
#> ==============================================================================================
#> *** p < 0.001; ** p < 0.01; * p < 0.05
 # }