create.multiplexHet {RandomWalkRestartMH} | R Documentation

## Create multiplex heterogeneous graphs from individual networks

### Description

`create.multiplexHet` is a function to create a multiplex and heterogeneous network (`MultiplexHet` object). It combines a multiplex network composed from 1 (monoplex case) up to 6 layers with another single network whose nodes are of different nature. See more details below.

### Usage

    create.multiplexHet(...)

    ## Default S3 method:
    create.multiplexHet(Multiplex_object, Het_graph,
      Nodes_relations, SecondNetworkName, ...)

### Arguments

`...` | Further arguments passed to `create.multiplexHet`
`Multiplex_object` | A Multiplex network (`Multiplex` object) generated by the function `create.multiplex`. This multiplex network will be integrated as the first network of the heterogeneous network.
`Het_graph` | An igraph object describing a monoplex network. It will be integrated as the second network of the heterogeneous network.
`Nodes_relations` | A data frame containing the relationships (bipartite interactions) between the nodes of the multiplex network and the nodes of the second network of the heterogeneous system. The data frame should contain two columns: the first one with the nodes of the multiplex network; the second one with the nodes of the second network. Every node should be present in their corresponing network.
`SecondNetworkName` | A vector containing the name for the second network to be integrated as part of the heterogeneous network. This name will be included as an attribute for all the edges of this network. It's optional and its default value is SecondNetwork.

### Details

A multiplex network is a collection of layers (monoplex networks) sharing the same nodes, but in which the edges represent relationships of different nature. A heterogeneous network is composed of two single networks where the nodes are of different nature. These nodes of different nature are linked through bipartite interactions.

### Value

A Multiplex Heterogeneous object. It contains a list of the different graphs integrating the multiplex network, the names and number of its nodes and the number of layers. In addition, it contains the graph of the second network integrating the heterogeneous network along with its number of nodes Finally, it contains a expanded bipartite adjacency matrix describing the relations of the nodes in every layer of the multiplex network with the nodes of the second network.

### Author(s)

Alberto Valdeolivas Urbelz alvaldeolivas@gmail.com

### See Also

`create.multiplex,isMultiplexHet`

### Examples

    m1 <- igraph::graph(c(1,2,1,3,2,3), directed = FALSE)
    m2 <- igraph::graph(c(1,3,2,3,3,4,1,4), directed = FALSE)
    multiObject <- create.multiplex(m1,m2)
    h1 <- igraph::graph(c("A","C","B","E","E","D","E","C"), directed = FALSE)
    bipartite_relations <- data.frame(m=c(1,3),h=c("A","E"))
    create.multiplexHet(multiObject,h1,bipartite_relations)

[Package RandomWalkRestartMH version 1.6.0 Index]