Learn R Programming

tidygraph (version 1.3.1)

component_games: Graph games based on connected components

Description

This set of graph creation algorithms simulate the topology by, in some way, connecting subgraphs. The nature of their algorithm is described in detail at the linked igraph documentation.

Usage

play_blocks(n, size_blocks, p_between, directed = TRUE, loops = FALSE)

play_blocks_hierarchy(n, size_blocks, rho, p_within, p_between)

play_islands(n_islands, size_islands, p_within, m_between)

play_smallworld( n_dim, dim_size, order, p_rewire, loops = FALSE, multiple = FALSE )

Value

A tbl_graph object

Arguments

n

The number of nodes in the graph.

size_blocks

The number of vertices in each block

p_between, p_within

The probability of edges within and between groups/blocks

directed

Should the resulting graph be directed

loops

Are loop edges allowed

rho

The fraction of vertices per cluster

n_islands

The number of densely connected islands

size_islands

The number of nodes in each island

m_between

The number of edges between groups/islands

n_dim, dim_size

The dimension and size of the starting lattice

order

The neighborhood size to create connections from

p_rewire

The rewiring probability of edges

multiple

Are multiple edges allowed

Functions

See Also

Other graph games: evolution_games, sampling_games, type_games

Examples

Run this code
plot(play_islands(4, 10, 0.7, 3))

Run the code above in your browser using DataLab