RCX-object: Create an RCX objects from aspects

Description Usage Arguments Details Value Examples

Description

ddd

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
createRCX(
  nodes,
  edges,
  nodeAttributes,
  edgeAttributes,
  networkAttributes,
  cartesianLayout,
  cyGroups,
  cyVisualProperties,
  cyHiddenAttributes,
  cyNetworkRelations,
  cySubNetworks,
  cyTableColumn,
  checkReferences = T
)

Arguments

nodes

Nodes aspect;

edges

Edges aspect (optional);

nodeAttributes

NodeAttributes aspect (optional);

edgeAttributes

EdgeAttributes aspect (optional);

networkAttributes

NetworkAttributes aspect (optional);

cartesianLayout

CartesianLayout aspect (optional);

cyGroups

CyGroups aspect (optional);

cyVisualProperties

CyVisualProperties aspect (optional);

cyHiddenAttributes

CyHiddenAttributes aspect (optional);

cyNetworkRelations

CyNetworkRelations aspect (optional);

cySubNetworks

CySubNetworks aspect (optional);

cyTableColumn

CyTableColumn aspect (optional);

checkReferences

logical; whether to check if references to other aspects are present in the RCX object

Details

vignette("CX-Data", package = "RCX")

Value

RCX object

Examples

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
## minimal example
rcx = createRCX(createNodes())

## create by aspect
nodes = createNodes(name = c("a","b","c"))
edges = createEdges(source=c(0,0), target=c(1,2))

nodeAttributes = createNodeAttributes(
  propertyOf=c(1,1),
  name=c("A","B"),
  value=c("a","b")
)

edgeAttributes = createEdgeAttributes(
  propertyOf=c(0,0), 
  name=c("A", "B"), 
  value=c("a","b")
)

networkAttributes = createNetworkAttributes(
  name=c("A","B"),
  value=list("a",3.14)
)

cartesianLayout = createCartesianLayout(
  node=c(0, 1),
  x=c(5.5, 110.1), 
  y=c(200.3, 210.2)
)

cyGroups = createCyGroups(
  name = c("Group One", "Group Two"),
  nodes = list(c(0,1), 0)                   
)

vpPropertyP = createCyVisualPropertyProperties(c(NODE_BORDER_STROKE="SOLID"))
vpPropertyD = createCyVisualPropertyDependencies(c(nodeSizeLocked="false"))
vpPropertyM = createCyVisualPropertyMappings(c(NODE_FILL_COLOR="CONTINUOUS"), 
                                             "COL=directed,T=boolean,K=0=true,V=0=ARROW")
vpProperty = createCyVisualProperty(properties=vpPropertyP, 
                                    dependencies=vpPropertyD, 
                                    mappings=vpPropertyM)

cyVisualProperties = createCyVisualProperties(nodes=vpProperty)

cyHiddenAttributes = createCyHiddenAttributes(
  name=c("A","B"),
  value=list(c("a1","a2"), "b")
)

cyNetworkRelations = createCyNetworkRelations(
  child = c(0,1),
  name = c("Network A", NA)
)

cySubNetworks = createCySubNetworks(
  nodes = list("all", c(0,1,2)),
  edges = list("all", c(0,1))                    
)

cyTableColumn = createCyTableColumn(
  appliesTo=c("nodes","edges","networks"),
  name=c("weight","weight","collapsed"),
  dataType=c("double","double","boolean")
)

rcx = createRCX(nodes, edges,
                nodeAttributes, edgeAttributes,
                networkAttributes, 
                cartesianLayout,
                cyGroups, 
                cyVisualProperties, 
                cyHiddenAttributes, 
                cyNetworkRelations, 
                cySubNetworks, 
                cyTableColumn)

## create all at once
rcx = createRCX(
  createNodes(name = c("a","b","c")), 
  createEdges(source=c(0,0), target=c(1,2)),
  createNodeAttributes(
    propertyOf=c(1,1),
    name=c("A","B"),
    value=c("a","b")
  ), 
  createEdgeAttributes(
    propertyOf=c(0,0), 
    name=c("A", "B"), 
    value=c("a","b")
  ),
  networkAttributes = createNetworkAttributes(
    name=c("A","B"),
    value=list("a",3.14)
  ), 
  cartesianLayout = createCartesianLayout(
    node=c(0, 1),
    x=c(5.5, 110.1), 
    y=c(200.3, 210.2)
  ),
  createCyGroups(
    name = c("Group One", "Group Two"),
    nodes = list(c(0,1), 0)                   
  ), 
  createCyVisualProperties(
    nodes=createCyVisualProperty(
      properties=createCyVisualPropertyProperties(
        c(NODE_BORDER_STROKE="SOLID")
      ), 
      dependencies=createCyVisualPropertyDependencies(
        c(nodeSizeLocked="false")
      ), 
      mappings=createCyVisualPropertyMappings(
        c(NODE_FILL_COLOR="CONTINUOUS"), 
        "COL=directed,T=boolean,K=0=true,V=0=ARROW")
    )
  ), 
  createCyHiddenAttributes(
    name=c("A","B"),
    value=list(c("a1","a2"), "b")
  ), 
  createCyNetworkRelations(
    child = c(0,1),
    name = c("Network A", NA)
  ), 
  createCySubNetworks(
    nodes = list("all", c(0,1,2)),
    edges = list("all", c(0,1))                    
  ), 
  createCyTableColumn(
    appliesTo=c("nodes","edges","networks"),
    name=c("weight","weight","collapsed"),
    dataType=c("double","double","boolean")
  )
)

frankkramer-lab/RCX documentation built on July 14, 2021, 6:33 p.m.