diff options
Diffstat (limited to 'man')
| -rw-r--r-- | man/networkplot.Rd | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/man/networkplot.Rd b/man/networkplot.Rd index 055bc46..a4a622d 100644 --- a/man/networkplot.Rd +++ b/man/networkplot.Rd @@ -4,11 +4,13 @@ \alias{networkplot} \title{Network Plot} \usage{ -networkplot(R, title = NULL) +networkplot(R, groups = NULL, title = NULL) } \arguments{ \item{R}{A square numeric matrix with names columns and rows} +\item{groups}{Optional data.frame mapping nodes to groups} + \item{title}{Optional plot title} } \value{ @@ -24,5 +26,11 @@ entries are the strength of the relationship X <- matrix(data = rnorm(100), nrow = 10) R <- cor(X) networkplot(R, title = 'Example Correlation Plot') +colnames(R) <- as.character(seq_len(ncol(R))) +g <- data.frame( +node = colnames(R), +group = rep(c('A', 'B'), length.out = ncol(R)) +) +networkplot(R, groups = g, title = 'Example Correlation Plot') } |
