gof_p2: Computes GOF statistics for a p2 model fit

Description Usage Arguments Details Value

View source: R/p2.R

Description

This is a slight modification of the function gof.ergmm from the package latentnet.

Usage

1
2
gof_p2(objfit, nsim = 100, GOF = ~idegree + odegree + distance,
  verbose = FALSE, conditional = FALSE)

Arguments

objfit

An object produced by a call to fit_p2.

nsim

Number of simulated networks.

GOF

A formula object to specify the statistics to use to diagnosis the goodness-of-fit of the model, among those suitable for directed networks. See the help file of gof.ergmm for more details.

verbose

Provides verbose information on the progress of the simulation. Default is FALSE.

conditional

Should the random effects be set at the estimated values, or else simulated from the normal distribution? Default is FALSE.

Details

The function makes only a minor modification to the function gof.ergmm from the package latentnet. The only change is actually that the function simulate.p2 is employed to generate the networks. This means that this function is based on 'statnet' project software (http://statnet.org). For license and citation information see http://statnet.org/attribution. It would have been much preferable to pass the simulated networks to gof.ergmm, but unfortunately such functionality is not supported, therefore it has been necessary to duplicate the function.

Value

Like gof.ergmm, it returns an object of class gofobject.


rugbel/p2model documentation built on March 8, 2021, 8:16 p.m.