graph_interval: Random Interval Graph

View source: R/create_graphs.R

graph_intervalR Documentation

Random Interval Graph

Description

Create a random interval graph. In an interval graph, each node is characterized by an interval on the real line. Two nodes are connected, if their intervals overlap.

Usage

graph_interval(n, r = 2, sd = 0.5)

Arguments

n

number of nodes

r

radius (see details)

sd

standard deviation (see details)

Details

Interval graphs are created as follows. First, n random points x are created uniformly at random between 0 and 'r'. For each point, a value Y is created from a normal distribution with mean X and standard deviation is 'sd'. In this way, it is possible to control the density of the network. The larger 'r' and the larger 'sd' the more likely do intervals overlap.

Value

interval graph as igraph object and interval representation as node attribute (a,b)

Author(s)

David Schoch

See Also

[graph_indifference,graph_tolerance]

Examples

graph_interval(n = 10)

schochastics/levelnet documentation built on Feb. 3, 2023, 4:20 a.m.