@@ -5,7 +5,7 @@ date: last-modified
55date-format : " [Last Updated on] MMMM DD, YYYY"
66---
77
8- These are your pathways .
8+ These are your networks .
99
1010``` {r}
1111#| label: "networks_common"
@@ -31,15 +31,14 @@ generate_subnetwork <- function(kinograte_res, genes) {
3131 Kinase = as.numeric(str_detect(type.y, "Kinase")),
3232 Hidden = as.numeric(str_detect(type.y, "Hidden")),
3333 Protein = as.numeric(str_detect(type.y, "Protein")),
34- Special = sample(c(TRUE, FALSE), nrow(.), replace = TRUE))
34+ Peptide = as.numeric(str_detect(type.y, "Peptide")),
35+ TF = as.numeric(str_detect(type.y, "TF")))
3536
3637 plot = plot_data %>%
3738 ggplot(aes(x = x, y = y, xend = xend, yend = yend)) +
3839 geom_edges(color = "grey50", curvature = 0.05) +
39- #geom_nodes(aes(color=Special), size=11)+
40- #geom_nodes(size=9, color = "white")+
41- geom_scatterpie(data = plot_data %>% distinct(vertex.names, .keep_all = TRUE), cols = c("RNA", "Protein", "Kinase", "Hidden"), pie_scale = .5) +
42- geom_nodetext_repel(aes(label = vertex.names), fontface = "bold", size = 11 / ggplot2:::.pt, box.padding = unit(.35, "lines")) +
40+ geom_scatterpie(data = plot_data %>% distinct(vertex.names, .keep_all = TRUE), cols = c("RNA", "Kinase", "Hidden", "Protein", "Peptide", "TF"), pie_scale = .5) +
41+ geom_nodetext_repel(aes(label = vertex.names), family = "Arial Narrow", fontface = "bold.italic", size = 9 / ggplot2:::.pt, box.padding = unit(.25, "lines")) +
4342 coord_equal() +
4443 theme_blank() +
4544 theme(legend.position = "none")
@@ -50,7 +49,7 @@ generate_subnetwork <- function(kinograte_res, genes) {
5049```
5150
5251``` {r}
53- genes_input <- gsea_pathways[831, ]$leadingEdge %>% unlist( )
52+ genes_input <- names(combined) %>% sample(100 )
5453
5554plot <- generate_subnetwork(kinograte_res, genes_input)
5655
0 commit comments