qunetwork: Construction and visualization of co-expression network

Description Usage Arguments Value See Also Examples

View source: R/qunetwork.R

Description

This function can automatically create co-expression networks along with their visualization based on identified biclusters in QUBIC. Three correlation methods, Pearson, Kendall and Spearman, are available for a user, facilitating different preferences in practical usage.

Usage

1
2
qunetwork(x, BicRes, number = 1:BicRes@Number, groups = c(number[[1]]),
  method = c("pearson", "kendall", "spearman"))

Arguments

x

The data matrix

BicRes

biclust::BiclustResult object

number

Which bicluster to be plotted

groups

An object that indicates which nodes belong together.

method

A character string indicating which correlation coefficient (or covariance) is to be computed. One of 'pearson' (default), 'kendall', or 'spearman', can be abbreviated.

Value

a list contains a weights matrix and groupinfo

See Also

qunet2xml QUBIC cor

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Load microarray matrix
data(BicatYeast)
res <- biclust::biclust(BicatYeast[1:50, ], method=BCQU(), verbose = FALSE)
# Constructing the networks for the 4th and 13th identified biclusters.
net <- qunetwork(BicatYeast[1:50, ], res, number = c(4, 13), group = c(4, 13), method = 'spearman')
## Not run: 
if (requireNamespace('qgraph'))
    qgraph::qgraph(net[[1]], groups = net[[2]], layout = 'spring', minimum = 0.6,
       color = cbind(rainbow(length(net[[2]]) - 1),'gray'), edge.label = FALSE)


## End(Not run)
## Not run: 
#Load microarray matrix
data(BicatYeast)
res <- biclust::biclust(BicatYeast[1:50, ], method=BCQU(), verbose = FALSE)
# Constructing the networks for the 4th and 13th identified biclusters,
#   using the whole network as a background.
net <- qunetwork(BicatYeast[1:50, ], res, group = c(4, 13), method = 'spearman')
if (requireNamespace('qgraph'))
    qgraph::qgraph(net[[1]], groups = net[[2]], layout = 'spring', minimum = 0.6,
       color = cbind(rainbow(length(net[[2]]) - 1),'gray'), edge.label = FALSE)

## End(Not run)

Example output

Loading required package: biclust
Loading required package: MASS
Loading required package: grid
Loading required package: colorspace
Loading required package: lattice
Loading required namespace: qgraph
Warning message:
In qgraph::qgraph(net[[1]], groups = net[[2]], layout = "spring",  :
  The following arguments are not documented and likely not arguments of qgraph and thus ignored: edge.label
Warning message:
In qgraph::qgraph(net[[1]], groups = net[[2]], layout = "spring",  :
  The following arguments are not documented and likely not arguments of qgraph and thus ignored: edge.label

QUBIC documentation built on Nov. 8, 2020, 8:17 p.m.