subnetwork: Extract a custom subnetwork from a large network

subnetworkR Documentation

Extract a custom subnetwork from a large network

Description

Extract a custom subnetwork from a large network

Usage

subnetwork(
  network,
  nodes = NULL,
  order = 1L,
  mode = "all",
  mindist = 0L,
  return_df = TRUE
)

Arguments

network

Either an OmniPath interaction data frame, or an igraph graph object.

nodes

Character or integer vector: names, identifiers or indices of the nodes to build the subnetwork around.

order

Integer: order of neighbourhood around nodes; i.e., number of steps starting from the provided nodes.

mode

Character: "all", "out" or "in". Follow directed edges from the provided nodes in any, outbound or inbound direction, respectively.

mindist

Integer: The minimum distance to include the vertex in the result.

return_df

Logical: return an interaction data frame instead of an igraph object.

Value

A network data frame or an igraph object, depending on the “return_df“ parameter.

See Also

  • interaction_graph

  • graph_interaction

  • show_network


saezlab/OmnipathR documentation built on Nov. 10, 2024, 11:02 p.m.