Learn R Programming

ergm (version 3.9.4)

ergm_proposal: Functions to initialize the ergm_proposal object

Description

S3 Functions that initialize the Metropolis-Hastings Proposal (ergm_proposal) object using the InitErgmProposal.* function that corresponds to the name given in 'object'. These functions are not generally called directly by the user. See ergm-proposals for general explanation and lists of available Metropolis-Hastings proposal types.

Usage

ergm_proposal(object, ...)

# S3 method for character ergm_proposal(object, arguments, nw, ..., response = NULL, reference = reference)

# S3 method for formula ergm_proposal(object, arguments, nw, weights = "default", class = "c", reference = ~Bernoulli, response = NULL, ...)

# S3 method for ergm ergm_proposal(object, ..., constraints = NULL, arguments = NULL, nw = NULL, weights = NULL, class = "c", reference = NULL, response = NULL)

Arguments

object

Either a character, a formula or an ergm object. The formula should be of the form y ~ <model terms>, where y is a network object or a matrix that can be coerced to a network object.

Further arguments passed to other functions.

arguments

A list of parameters used by the InitErgmProposal routines

nw

The network object originally given to ergm via 'formula'

response

Name of the edge attribute whose value is to be modeled in the valued ERGM framework. Defaults to NULL for simple presence or absence, modeled via a binary ERGM.

reference

One-sided formula whose RHS gives the reference measure to be used. (Defaults to ~Bernoulli.)

weights

Specifies the method used to allocate probabilities of being proposed to dyads; options are "TNT", "TNT10", "random", "nonobserved" and "default"; default="default"

class

The class of the proposal; choices include "c", "f", and "d" default="c".

constraints

A one-sided formula specifying one or more constraints on the support of the distribution of the networks being simulated. See the documentation for a similar argument for ergm and see list of implemented constraints for more information.

Value

Returns an ergm_proposal object: a list with class ergm_proposal containing the following named elements:

name

the C name of the proposal

inputs

inputs to be passed to C

package

shared library name where the proposal can be found (usually "ergm")

arguments

list of arguments passed to the InitErgmProposal function; in particular,

constraints

list of constraints

Methods (by class)

  • character: object argument is a character string giving the R name of the proposal.

  • formula: object argument is an ERGM constraint formula.

  • ergm: object argument is an ergm fit whose proposals are extracted which is reproduced as best as possible.

See Also

InitErgmProposal