Nodes: Nodes

NodesR Documentation

Nodes

Description

This function creates nodes for networks.

Usage

createNodes(id = NULL, name = NULL, represents = NULL)

Arguments

id

integer (optional); node IDs

name

character (optional); names of the nodes

represents

character (optional); representation, e.g. a link to another database

Details

Nodes are represented by NodesAspect objects. A single node is defined by its unique id, which must be an (positive) integer, which serves as reference to other aspects. Optionally, nodes can have a name and a represents attribute. If no IDs are provided, but either names or representations (or both) IDs are assigned automatically. To be valid, a nodes aspect must contain at least one node. However, if no parameters are set (i.e. id, name and represents = NULL) there is still one node created with neither name nor representation, just an ID. The NodesAspect is the only mandatory aspect for an RCX-object.

Value

NodesAspect object

See Also

updateNodes, RCX-object

Examples

## a minimal example
nodes = createNodes()

## ids will be generated
nodes = createNodes(name = c("a","b","c"))

## with all parameters
nodes = createNodes(id=c(1, 2, 3), 
                    name=c("CDK1", "CDK2", "CDK3"),
                    represents=c("HGNC:CDK1", 
                                 "Uniprot:P24941", 
                                 "Ensembl:ENSG00000250506"))

frankkramer-lab/RCX documentation built on Feb. 4, 2023, 5:12 p.m.