net.gen.from.P: generates a network from the given connection probability

Description Usage Arguments Value Author(s)

View source: R/SP_Inf.R

Description

Generates an adjacency matrix from a given probability matrix, according independent Bernoulli – the so-called inhomogeneous Erdos-Renyi model. It is used to generate new networks from a given model.

Usage

1
net.gen.from.P(P, mode = "undirected")

Arguments

P

connection probability between nodes

mode

"undirected" (default) if the network is undirected, so the adjacency matrix will be symmetric with only upper diagonal entries being generated as independent Bernoulli. Otherwise, the adjacency matrix gives independent Bernoulli everywhere.

Value

An adjacency matrix

Author(s)

Can M. Le and Tianxi Li.

Maintainer: Tianxi Li <tianxili@virginia.edu>


NetworkReg documentation built on July 8, 2020, 5:12 p.m.