我使用这种方法来生成chord diagrams
已经有一段时间了,为了协调我工作中的图形,我需要继续使用这个包。
使用这种方法时,我从未收到过任何错误,而且我也不知道是什么原因导致了这个问题以及如何解决它。
我对“长”数据样本表示歉意,但需要它来重现错误。
问题为什么我会收到此错误,是否可以修复?:
f()
中的错误:!分隔符和标签长度不同
library(tidyverse)
library(GOplot)
i_circle <- circle_dat(i_GOterms, i_genelist) %>%
na.omit()
chord_i <- chord_dat(data = i_circle,
genes = i_genelist,
process = unique(i_circle$term))
GOChord(chord_i)
数据结构1
i_genelist <- structure(list(ID = structure(1:128, levels = c("A1BG", "A2M",
"ACTB;ACTG1", "AGT", "AHSG", "ALB", "AMBP", "APLP1", "APOA1",
"APOA2", "APOA4", "APOC3", "APOD", "APOE", "APOH", "APP", "AZGP1",
"B2M", "B4GAT1", "BCAN", "C1QC", "C1R", "C1S", "C3", "C4A", "C7",
"CD14", "CD59", "CDH2", "CFB", "CFH", "CHGA", "CHGB", "CHL1",
"CLSTN1", "CLU", "CNDP1", "CNTN1", "CP", "CPE", "CRTAC1", "CSF1",
"CSF1R", "CST3", "CTSD", "DAG1", "DKK3", "ECM1", "EFEMP1", "ENPP2",
"EPHA4", "EXOC3L4", "F2", "FAM3C", "FBLN1", "FCGBP", "FGA", "FGB",
"FGG", "FN1", "FSTL1", "GC", "GM2A", "GRIK1", "HBA1", "HBB",
"HP", "HPX", "HSPG2", "IGF2", "IGFBP2", "IGFBP6", "IGFBP7", "IGHA1",
"IGHG1", "IGHG2", "IGHG3", "IGKC", "IGLL5;IGLC1", "ITIH2", "ITIH4",
"KLK6", "KNG1", "LDHB", "LGALS3BP", "LRG1", "LY6H", "NCAM1",
"NCAM2", "NEGR1", "NELL2", "NOV", "NPC2", "NPTXR", "NRCAM", "OGN",
"ORM1", "ORM2", "PAM", "PCOLCE", "PCSK1N", "PENK", "PLG", "PLTP",
"PSAP", "PTGDS", "RARRES2", "RBP4", "RNASE1", "SCG2", "SCG3",
"SCG5", "SERPINA1", "SERPINA3", "SERPINC1", "SERPIND1", "SERPINF1",
"SERPING1", "SIRPA;SIRPB1", "SOD3", "SPARCL1", "SPP1", "TF",
"TIMP1", "TTR", "VGF", "VSTM2A", "VTN"), class = "factor"), logFC = c(16,
17, 13, 14, 14, 21, 12, 16, 17, 13, 15, 11, 15, 18, 14, 13, 15,
16, 13, 14, 12, 13, 11, 18, 17, 11, 13, 14, 14, 14, 15, 15, 14,
13, 15, 17, 14, 13, 15, 12, 14, 11, 12, 17, 12, 11, 14, 12, 14,
15, 10, 12, 15, 13, 15, 12, 15, 12, 12, 16, 11, 16, 11, 13, 15,
16, 17, 17, 10, 12, 12, 11, 14, 14, 18, 14, 16, 16, 13, 12, 11,
13, 16, 12, 12, 13, 11, 14, 11, 12, 14, 11, 13, 13, 13, 14, 15,
14, 13, 11, 14, 12, 12, 12, 12, 17, 12, 13, 12, 12, 12, 13, 18,
15, 13, 11, 16, 15, 14, 12, 16, 12, 19, 11, 16, 15, 12, 14)), row.names = c(NA,
-128L), class = "data.frame")
数据结构2
i_GOterms <- structure(list(Category = c("GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT",
"GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT",
"GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT",
"GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT",
"GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT",
"GOTERM_BP_DIRECT", "GOTERM_BP_DIRECT"), Term = c("inflammatory response",
"defense response to bacterium", "plasminogen activation", "positive regulation of B cell activation",
"phagocytosis, recognition", "high-density lipoprotein particle assembly",
"negative regulation of fibrinolysis", "negative regulation of blood coagulation",
"phagocytosis, engulfment", "positive regulation of peptidase activity",
"protein localization to secretory granule", "protein polymerization",
"complement activation, alternative pathway", "axon guidance",
"cholesterol metabolic process", "B cell receptor signaling pathway",
"negative regulation of very-low-density lipoprotein particle remodeling",
"regulation of beta-amyloid clearance", "aging", "positive regulation of phagocytosis"
), Genes = c("SERPINA3, CSF1R, ECM1, ORM1, CSF1, RARRES2, HSPG2, KNG1, C3, C4A, SPP1, CD14, SCG2",
"CHGA, IGHG3, IGLL5, IGHG1, IGHG2, VGF, IGKC, HP, IGLC1, IGHA1",
"FGB, FGA, APOH, FGG", "IGHG3, IGLL5, IGHG1, IGHG2, IGKC, IGLC1, IGHA1",
"IGHG3, IGLL5, IGHG1, IGHG2, IGKC, IGLC1, IGHA1", "APOA2, APOA1, APOA4, APOE",
"VTN, APOH, PLG, F2", "VTN, APOH, APOE, KNG1", "IGHG3, IGLL5, IGHG1, IGHG2, IGKC, IGLC1, IGHA1",
"APP, FN1, FBLN1, PCOLCE", "CHGA, CPE, SCG3", "FGB, FGA, VTN, FGG",
"C3, CFH, C7, CFB", "NELL2, EPHA4, CSF1R, B4GAT1, CHL1, DAG1, CNTN1, NRCAM",
"APP, NPC2, APOA2, APOA1, APOA4, APOE", "IGHG3, IGLL5, IGHG1, IGHG2, IGKC, IGLC1, IGHA1",
"APOA2, APOC3, APOA1", "APP, APOE, CLU", "SERPINF1, PENK, IGFBP2, DAG1, SERPING1, APOD, TIMP1, AGT",
"AHSG, APOA2, SIRPA, APOA1, SIRPB1"), adj_pval = c(0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)), row.names = c(NA,
-20L), class = "data.frame")
1条答案
按热度按时间umuewwlo1#
您需要增加
lfc.max
,因为您的logFC
列中的所有值都超出了默认范围c(-3, 3)
:我发现这是相当困难的,以适应图例到这个情节,由于长度的术语的标签。