plot2in1 {BiDAG}R Documentation

Highlighting similarities between two graphs

Description

This function plots nodes and edges from two graphs in one and indicates similarities between these graphs.

Usage

plot2in1(graph1, graph2, name1 = NULL, name2 = NULL, bidir = FALSE, ...)

Arguments

graph1

binary adjacency matrix of a graph

graph2

binary adjacency matrix of a graph, column names should coincide with column names of 'graph1'

name1

character, custom name for 'graph1'; when NULL no legend will be plotted

name2

character, custom name for 'graph2'

bidir

logical, defines if arrows of bidirected edges are drawn; FALSE by defauls.

...

optional parameters passed to Rgraphviz plotting functions e.g. main, fontsize

Value

plots the graph which includes nodes and edges two graphs; nodes which are connected to at least one other node in both graphs are plotted only once and coloured orange, edges which are shared by two graphs are coloured orange; all other nodes and edges a plotted once for each 'graph1' and 'graph2' and coloured blue and green accordingly.

Author(s)

Polina Suter


[Package BiDAG version 2.1.4 Index]