plot_network | R Documentation |
plotting the network of metabolites and OTU. Orange nodes represent the OTU, while the other color represent the metabolite. Same color metabolites nodes are constructed in the same modules.
plot_network(net, corr, seed = 123, return = FALSE, interaction = TRUE)
net |
result of function 'coExpress' |
corr |
result of function 'corr.test' |
seed |
set seed for layout in interaction ploting |
return |
whether return the igraph |
interaction |
plot method |
igraph or graph
Congcong Gong
library(data.table) path <- system.file('extdata', 'metabolites_and_genera.rda', package = 'mbOmic') load(path) names(genera)[1] <- 'rn' names(metabolites)[1] <- 'rn' b <- bSet(b = genera) m <- mSet(m = metabolites) res <- corr(m, b, method = 'spearman') net <- coExpress(m, minN = 2, power = 9, message = FALSE) plot_network(net, res[abs(rho)>=0.85])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.