View source: R/create_graphs.R
graph_tolerance | R Documentation |
Create a random tolerance graph. A tolerance graph is an interval graph, where nodes are only connected if the overlap is larger than a nodes tolerance level. These graphs are directed.
graph_tolerance(n, r = 2, sd = 0.5, tol = 0.5)
n |
number of nodes |
r |
radius (see details) |
sd |
standard deviation (see details) |
tol |
tolerance |
Tolerance 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. When overlaps are calculated, it is checked whether the overlap is larger than the tolerance of the node. If so, the edge is included.
tolerance graph as igraph object and interval representation and tolerance as node attributes
David Schoch
[graph_interval,graph_indifference]
graph_tolerance(n = 10)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.