plotMyMatrix: Plot an adjacency or incidence Matrix

Description Usage Arguments Details Value Examples

View source: R/plotMyMatrix.R

Description

Plot an adjacency or incidence Matrix

Usage

1
2
3
4
5
6
plotMyMatrix(
  Mat,
  dimLabels = list(row = "row", col = "col"),
  clustering = NULL,
  plotOptions = NULL
)

Arguments

Mat

: a matrix representing the network

dimLabels

: a list of length 2 specifying the types of nodes in row and col (functional group) (Default is NULL)

clustering

: a list of length 2 specifying a clustering on row and col

plotOptions

: a list providing options. See details below.

Details

The list of parameters plotOptions for the matrix plot is

Value

a ggplot object corresponding to the plot

Examples

1
2
3
4
M <- matrix(sample(c(0,1),900,replace=TRUE),30,30)
plotMyMatrix(M, plotOptions= list(legend = FALSE))
M2 <- matrix( rpois(800,10),40,20)
plotMyMatrix(M2, dimLabels=list(row= 'reader',col = 'book'), plotOptions = list(legend = TRUE))

GrossSBM/sbm documentation built on April 8, 2021, 5:53 a.m.