Learn R Programming

bulkAnalyseR (version 1.1.0)

get_link_list_rename: Convert the adjacency matrix to network links

Description

This function converts an adjacency matrix to a data frame of network links, subset to the most important ones.

Usage

get_link_list_rename(weightMat, plotConnections)

Value

A data frame with fields from, to and value, describing the edges of the network

Arguments

weightMat

the (weighted) adjacency matrix - regulators in rows, targets in columns

plotConnections

the number of connections to subset to

Examples

Run this code
weightMat <- matrix(
  c(0.1, 0.4, 0.8, 0.3), nrow = 2, ncol = 2,
  dimnames = list("regulators" = c("r1", "r2"), "targets" = c("t1", "t2"))
)
get_link_list_rename(weightMat, 2)

Run the code above in your browser using DataLab