Skip to contents

weaveWeb wrapper for the MultiAssayExperiment class

Usage

# S4 method for class 'MultiAssayExperiment'
getWeb(
  x,
  link = NULL,
  ...,
  tableY = NULL,
  tableX = NULL,
  typeY = NULL,
  typeX = NULL,
  force_new = FALSE,
  experiment1 = NULL,
  experiment2 = NULL,
  assay.type1 = NULL,
  assay.type2 = NULL
)

Arguments

x

a MultiAssayExperiment::MultiAssayExperiment().

...

additional parameters passed to AnansiWeb().

One of the following:

  • Character scalar with value "none"

  • data.frame with two columns

  • list with two such data.frames

tableY, tableX

Character scalar or numeric scalar. Selects experiment corresponding to tableY and tableX from experiments(x) of MultiAssayExperiment object by name or index, name is recommended. (Default slots: Y = 1L, X = 2L).

typeY, typeX

Character scalar or numeric scalar. Selects assay from experiments to tableY and tableX from experiments(x). (Default: 1L - the first assay in that experiment).

force_new

boolean If x already has a dictionary Matrix in metadata, ignore it and generate a new object anyway? (Default: FALSE).

experiment1, experiment2

synonymous args to tableY,tableX for compatibility with mia argument style.

assay.type1, assay.type2

synonymous args to typeY,typeX for compatibility with mia argument style.

Value

an AnansiWeb object, with sparse binary biadjacency matrix with features from y as rows and features from x as columns in dictionary slot. If x already contains a dictionary in metadata, use that one, unless force_new = TRUE.

Details

This wrapper of weaveWeb() allows to generate an AnansiWeb S4 object directly from objects of class MultiAssayExperiment::MultiAssayExperiment() . First, the assays specified by assay.typeY and assay.typeX are passed to AnansiWeb() to build an AnansiWeb object.

Examples

# Make a random anansiWeb
web <- randomWeb()

# Combine experiments into MultiAssayExperiment object
mae <- as(web, "MultiAssayExperiment")

# Back to AnansiWeb
outWeb <- getWeb(mae, tableY = "y", tableX = "x")