MseekGraphs: MseekGraphs

setLayout,MseekGraph-methodR Documentation

MseekGraphs

Description

setLayout(): change the graph layout of an existing MseekGraph object.

MseekGraph objects are igraph objects which have layout information and slots that are the same as MseekFT objects, except that the bulk of data is kept in an igraph object instead of a data.frame. These objects are read and displayed by the NetworkModule.

saveMseekGraph: save a MseekGraph object to a file, registering the save event in the processHistory if the format allows

loadMseekGraph: load a MseekGraph object from an .mskg or .graphml file (file extensions inform how file is loaded in)

simplify: simplify an MseekGraph object, reducing the number of edges using additional filters.

limitComponents: simplify an MseekGraph object, reducing the number of edges for any subgraph with more than n components.

Usage

## S4 method for signature 'MseekGraph'
setLayout(object, layoutFunction = "qgraph::qgraph.layout.fruchtermanreingold")

## S4 method for signature 'MseekFT'
buildMseekGraph(
  object,
  cosineThreshold = 0.6,
  layoutFunction = "qgraph::qgraph.layout.fruchtermanreingold"
)

## S4 method for signature 'MseekGraph'
saveMseekGraph(object, file, writeGraphML = FALSE, writeRDS = TRUE)

## S4 method for signature 'character'
loadMseekGraph(
  object,
  layoutFunction = "qgraph::qgraph.layout.fruchtermanreingold"
)

## S4 method for signature 'MseekGraph'
simplify(
  object,
  rankBy = NULL,
  maxK = 10,
  cosineThreshold = NULL,
  layoutFunction = "qgraph::qgraph.layout.fruchtermanreingold"
)

## S4 method for signature 'MseekGraph'
limitComponents(
  object,
  rankBy = "cosine",
  n = Inf,
  layoutFunction = "qgraph::qgraph.layout.fruchtermanreingold",
  percentile = TRUE
)

Arguments

object

an MseekGraph object (MseekFT for buildMseekGraph())

layoutFunction

function to use for layout of the resulting graph

cosineThreshold

if length > 0, will remove all edges with a cosine value below this

file

file path to write to

writeGraphML

write object to a .graphML file (will drop metadata and some columns)

writeRDS

write object to an .mskg (RDS) file; saves the entire object

rankBy

if length > 0, will use this edge attribute to iteratively remove the lowest scoring edges from the large clusters until

maxK

if length > 0, will only allow at most this many edges from each node

n

maximum number of nodes connected in a cluster

percentile

remove edges in percentile steps

Value

the MseekFT object, with saving event added to processHistory


mjhelf/METABOseek documentation built on April 27, 2022, 5:13 p.m.