listInstances: Lists all instances that conform to the selection criteria.

Description Usage Arguments Value Author(s) Examples

Description

Lists all instances that conform to the selection criteria. In contrast to selectInstances this function returns an easier to read list. This function returns an ordered data.table of class, id and name of the instances. Selection criteria are wether instances belong to a certain class or have the specified id or name. Setting a criteria to NULL ignores this criteria. If includeSubClasses is set to TRUE the class criteria is broadened to include all classes that inherit from the given class, e.g. if class="control" and includeSubClasses=TRUE the function will select catalyses and modulations too, since they are a subclass of class control.

Usage

1
2
3
4
5
6
7
8
9
listInstances(
  biopax,
  id = NULL,
  class = NULL,
  name = NULL,
  includeSubClasses = FALSE,
  returnIDonly = FALSE,
  biopaxlevel = 3
)

Arguments

biopax

A biopax model

id

string. ID of the instances to select

class

string. Class of the instances to select

name

string. Name of the instances to select

includeSubClasses

logical. If includeSubClasses is set to TRUE the class criteria is broadened to include all classes that inherit from the given class

returnIDonly

logical. If TRUE only IDs of the components are returned. This saves time for looking up names for every single ID.

biopaxlevel

integer. Set the biopax level here if you supply a data.table directly.

Value

Returns a data.frame containing all instances conforming to the given selection criteria. If returnIDonly=TRUE, only the selector for the internal data.table otherwise.

Author(s)

Frank Kramer

Examples

1
2
3
4
5
6
7
8
 # load data
 data(biopaxexample)
 # list all instances of class "protein"
 listInstances(biopax, class="protein")
 # list all instances of class "pathway"
 listInstances(biopax, class="pathway")
 # list all interaction including all subclasses of interactions
 listInstances(biopax, class="interaction", includeSubClasses=TRUE)

rBiopaxParser documentation built on Nov. 8, 2020, 8:21 p.m.