Subnetwork extraction

Share:

Description

Extract a sub network from the original one.

Usage

1
2
extraction(graph, mode = c("exact", "sample"), sample.number = 10,
  nodes = NULL, vertex.name = NULL, vertex.expression = NULL, ...)

Arguments

graph

An igraph object.

mode

Extraction mode, either be exact or sample.

sample.number

Sampled nodes if mode is sample, no more than the total nodes in the network. Default value is 10.

nodes

A vector of vertex id to extract the subnetwork if mode is exact.

vertex.name

A vector of vertex name to extract the subnetwork if mode is exact.

vertex.expression

Attribute used to choose the vertex and extract the subnetwork.

...

Other vertex or edge atrributes.

Value

An igraph object.

Examples

1
2
g<-graph.ring(100)
g1<-extraction(g,mode="sample",sample.number=5)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.