draw.bn {Pigengene} | R Documentation

## Draws a Bayesian network

### Description

Draws the BN using appropriate colors and font size.

### Usage

    draw.bn(BN, plotFile = NULL, inputType = "ENTREZIDat", edgeColor = "blue",
      DiseaseCol = "darkgreen", DiseaseFill = "red", DiseaseChildFill = "pink",
      nodeCol = "darkgreen", nodeFill = "yellow", moduleNamesFile = NULL,
      mainText = NULL, nodeFontSize = 14 * 1.1, verbose = 0)

### Arguments

`BN` | An object of `bn-class`
`plotFile` | If not `NULL`, the plot will be saved here.
`inputType` | The type of gene IDs in `BN`
`edgeColor` | The color of edges
`DiseaseCol` | The color of the border of the Disease node
`DiseaseFill` | The color of the area inside the Disease node
`DiseaseChildFill` | The color of the area inside the children of the Disease node
`nodeCol` | The color of the border of the usual nodes excluding Disease and its children
`nodeFill` | The color of the area inside the usual nodes
`moduleNamesFile` | An optional csv file including the information to rename the nodes name. See coderename.node.
`mainText` | The main text shown at the top of the plot
`nodeFontSize` | Adjusts the size of nodes
`verbose` | The integer level of verbosity. 0 means silent and higher values produce more details of computation.

### Value

A list with following components:

`call` | The call that created the results
`BN` | An echo of input `BN` argument
`renamedBN` | An object of `bn-class` when `moduleNamesFile` is provided
`gr` | The full output of `graphviz.plot` function

### Author(s)

Habil Zare

### See Also

`bnlearn-package`, `Pigengene-package`, `learn.bn`, `graph-class`

### Examples

    ## See lear.bn function.

[Package Pigengene version 1.6.0 Index]