Skip to contents

Network-Valued to Matrix-Valued Data

Usage

repr_nvd(x, y = NULL, representation = "adjacency")

Arguments

x

An nvd object.

y

An nvd object. If NULL (default), it is not taken into account.

representation

A string specifying the requested matrix representation. Choices are: "adjacency", "laplacian" or "modularity". Default is "adjacency".

Value

A list of matrices.

Examples

params <- list(n = 24L, p = 1/3)
x <- nvd(sample_size = 1L, model = "gnp", !!!params)
#>  Calling the `tidygraph::play_gnp()` function with the following arguments:
#> • n: 24
#> • p: 0.333333333333333
#> • directed: TRUE
#> • loops: FALSE
xm <- repr_nvd(x)