plotDnf: Plot disjunctive normal form.

Description Usage Arguments Value Author(s) Examples

View source: R/mnems.r

Description

This function visualizes a graph encoded as a disjunctive nromal form.

Usage

 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
plotDnf(
  dnf = NULL,
  freq = NULL,
  stimuli = c(),
  signals = c(),
  inhibitors = c(),
  connected = TRUE,
  CNOlist = NULL,
  cex = NULL,
  fontsize = NULL,
  labelsize = NULL,
  type = 2,
  lwd = 1,
  edgelwd = 1,
  legend = 0,
  x = 0,
  y = 0,
  xjust = 0,
  yjust = 0,
  width = 1,
  height = 1,
  layout = "dot",
  main = "",
  sub = "",
  cex.main = 1.5,
  cex.sub = 1,
  col.sub = "grey",
  fontcolor = NULL,
  nodestates = NULL,
  simulate = NULL,
  edgecol = NULL,
  labels = NULL,
  labelcol = "blue",
  nodelabel = NULL,
  nodecol = NULL,
  bordercol = NULL,
  nodeshape = NULL,
  verbose = FALSE,
  edgestyle = NULL,
  nodeheight = NULL,
  nodewidth = NULL,
  edgewidth = NULL,
  lty = NULL,
  hierarchy = NULL,
  showall = FALSE,
  edgehead = NULL,
  edgelabel = NULL,
  edgetail = NULL,
  bool = TRUE,
  draw = TRUE,
  ...
)

Arguments

dnf

Hyper-graph in disjunctive normal form, e.g. c("A=B", "A=C+D", "E=!B") with the child on the left and the parents on the right of the equation with "A=C+D" for A = C AND D. Alternatively, dnf can be an adjacency matrix, which is converted on the fly to a disjunctive normal form.

freq

Frequency of hyper-edges which are placed on the edges.

stimuli

Highlights vertices which can be stimulated.

signals

Highlights vertices which regulate E-genes.

inhibitors

Highlights vertices which can be inhibited.

connected

If TRUE, only includes vertices which are connected to other vertices.

CNOlist

CNOlist object. Optional instead of stimuli, inhibitors or signals. See package CellNOptR.

cex

Global font size.

fontsize

Vertice label size.

labelsize

Edge label size.

type

Different plot types. 2 for Rgraphviz and 1 for graph.

lwd

Line width.

edgelwd

Edgeline width.

legend

0 shows no legend. 1 shows legend as a graph. 2 shows legend in a standard box.

x

x coordinate of box legend.

y

y coordinate of box legend.

xjust

Justification of legend box left, right or center (-1,1,0).

yjust

Justification of legend box top, bottom or middle (-1,1,0).

width

Vertice width.

height

Vertice height.

layout

Graph layout. See graphvizCapabilities()$layoutTypes.

main

Main title.

sub

Subtitle.

cex.main

Main title font size.

cex.sub

Subtitle font size.

col.sub

Font color of subtitle.

fontcolor

Global font color.

nodestates

Binary state of each vertice.

simulate

Simulate stimulation and inhibition of a list of vertices. E.g. simulate = list(stimuli = c("A", "B"), inhibitors = c("C", "D")).

edgecol

Vector with colors for every edge of the graph (not hyper-graph). E.g. an AND gate consists of three distinct edges.

labels

Vector with labels for the edges.

labelcol

Vector with label colors for the edges.

nodelabel

List of vertices with labels as input. E.g. labels = list(A="test", B="label for B").

nodecol

List of vertices with colors as input.

bordercol

List of vertices with colors as input.

nodeshape

List of vertices with shapes (diamond, box, square,...).

verbose

Verbose output.

edgestyle

set the edge style like dashed, can be numerical

nodeheight

List of vertices with height as input.

nodewidth

List of vertices with width as input.

edgewidth

Vector with edge widths.

lty

Vector with edge styles (line, dotted,...).

hierarchy

List with the hierarchy of the vertices. E.g. list(top = c("A", "B"), bottom = c("C", "D")).

showall

See "connected" above.

edgehead

Vector with edge heads.

edgelabel

Vector with edge labels.

edgetail

Vector with edge tails.

bool

If TRUE, only shows normal graph and no AND gates.

draw

Do not plot the graph and only output the graphNEL object.

...

additional arguments

Value

Rgraphviz object

Author(s)

Martin Pirkl

Examples

1
2
g <- c("!A+B+C=G", "C=G", "!D=G")
plotDnf(g)

mnem documentation built on Nov. 18, 2020, 2 a.m.