zoukankan      html  css  js  c++  java
  • 报错:Error in ans[ypos] <- rep(yes, length.out = len)[ypos] : replacement has length zero

    运行以下命令时:

    ego.down <- enrichGO(gene = down$newid,
                       universe = bg.list$newid,
                       OrgDb = org.Hs.eg.db,
                       keyType       = 'ENSEMBL',
                       ont = "BP", # biological process, change this to "MF" for molecular function, or "CC" for cellular components
                       pAdjustMethod = "BH",
                       pvalueCutoff = 0.01,
                       qvalueCutoff = 0.05,
                       readable = TRUE)
    
    dotplot(ego.down,showCategory=20,x="GeneRatio",font.size=13) + ggtitle("GO (BP) terms of down-regulated genes")+
    scale_y_discrete(labels=function(x) str_wrap(x,width = 40))  +
      theme(plot.title = element_text(size=16,face = "bold",hjust = .5),
            legend.title = element_text(size=15),
            legend.text = element_text(size=14))
    

    出现报错:

    Error in ans[ypos] <- rep(yes, length.out = len)[ypos] : replacement has length zero

    检查了一下,发现是阈值设的太高,把阈值调低即可:

    pvalueCutoff = 0.01,
    qvalueCutoff = 0.05,
    

    把上面的改为:

    pvalueCutoff = 0.2,
    qvalueCutoff = 0.2,
    
  • 相关阅读:
    webpack的安装与配置
    npm初始化
    gitignore的配置
    git本地已有文件夹和远程仓库对应
    git 配置
    开发环境和开发工具
    git 码云使用教程
    递归
    LeetCode 392. 判断子序列
    MongoDB基本操作
  • 原文地址:https://www.cnblogs.com/chenwenyan/p/15225007.html
Copyright © 2011-2022 走看看