compareNetworks {BioNet} | R Documentation

## Compare parameters of two networks

### Description

The function compares the following parameters of two networks: diameter, average degree, degree exponent, average path length and plots the cumulative degree distributions. The networks have to be connected components.

### Usage

    compareNetworks(network1, network2, plot=TRUE)

### Arguments

`network1` | Network graphNEL or igraph format.
`network2` | Second network in graphNEL or igraph format, or subnetwork drawn from first network.
`plot` | Boolean value, whether to plot the cumulative degree distributions.

### Value

A vector of network parameters is returned:

`diam.network1` | Network diameter
`diam.network2` | Diameter of the subnetwork
`av.degree.network1` | Average degree of the network
`av.degree.network2` | Average degree of the subnetwork
`degree.exponent.network1` | Degree exponent of the network
`degree.exponent.network2` | Degree exponent of the subnetwork
`av.path.length.network1` | Average path lenght of the network
`av.path.length.network2` | Average path length of the subnetwork

### Author(s)

Daniela Beisser

### Examples

    library(DLBCL)
    data(interactome)
    subnet1 <- largestComp(subNetwork(nodes(interactome)[1:100], interactome))
    subnet2 <- largestComp(subNetwork(nodes(interactome)[101:200], interactome))
    compareNetworks(network1=subnet1, network2=subnet2)

[Package BioNet version 1.46.0 Index]