Learn R Programming

sna (version 2.8)

nties: Find the Number of Possible Ties in a Given Graph or Graph Stack

Description

nties returns the number of possible edges in each element of dat, given mode and diag.

Usage

nties(dat, mode="digraph", diag=FALSE)

Value

The number of possible edges, or a vector of the same

Arguments

dat

a graph or set thereof.

mode

one of ``digraph'', ``graph'', and ``hgraph''.

diag

a boolean indicating whether or not diagonal entries (loops) should be treated as valid data; ignored for hypergraphic (``hgraph'') data.

Author

Carter T. Butts buttsc@uci.edu

Details

nties is used primarily to automate maximum edge counts for use with normalization routines.

Examples

Run this code
#How many possible edges in a loopless digraph of order 15?
nties(rgraph(15),diag=FALSE)

Run the code above in your browser using DataLab