Skip to content

Commit

Permalink
fix plotGSEA volcano function and update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
reedliu committed May 27, 2022
1 parent cf89aff commit 0a9926a
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 17 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: genekitr
Type: Package
Title: Gene Analysis Toolkit in R
Version: 0.8.4
Version: 0.8.5
Authors@R:
c(person(given = "Yunze",
family = "Liu",
Expand Down
3 changes: 1 addition & 2 deletions R/genGO.R
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@
#'
#' gego <- genGO(id, group_list = group,
#' org = "human", ont = "bp", pvalueCutoff = 0.1,
#' qvalueCutoff = 1
#' )
#' qvalueCutoff = 1)
#'
#' }
genGO <- function(id,
Expand Down
4 changes: 2 additions & 2 deletions R/plotGSEA.R
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,11 @@ plotGSEA <- function(gsea_list,
if(plot_type == 'volcano'){
gsea_df <- gsea_list$gsea_df
gsea_df <- gsea_df[order(gsea_df$NES,decreasing = TRUE),]
plot_df <- gsea_df
if(is.numeric(show_pathway)){
plot_df = gsea_df
plot_df$group <- c(rep('high',show_pathway),rep('ignore',nrow(plot_df)-2*show_pathway),rep('low',show_pathway))
}else{
nes <- plot_df[gsea_df$Description %in% show_pathway,'NES']
nes <- plot_df[plot_df$Description %in% show_pathway,'NES']
plot_df$group <- 'ignore'
plot_df[plot_df$Description %in% show_pathway,'group'] <- sapply(nes, function(x) ifelse(x>0,'high','low'))
}
Expand Down
6 changes: 2 additions & 4 deletions R/plotVenn.R
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,10 @@
#' )
#' plotVenn(sm_gene_list,
#' text_size = 1.5, alpha_degree = 1,
#' remove_grid = TRUE, color = ggsci::pal_lancet()(3)
#' )
#' remove_grid = TRUE, color = ggsci::pal_lancet()(3))
#' plotVenn(la_gene_list,
#' text_size = 15, alpha_degree = 0.2, border_thick = 2,
#' remove_grid = TRUE, use_venn = FALSE
#' )
#' remove_grid = TRUE, use_venn = FALSE)
plotVenn <- function(venn_list,
use_venn = TRUE,
color = NULL,
Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<img src="https://jieandze1314-1255603621.cos.ap-guangzhou.myqcloud.com/blog/2022-05-24-043213.png" align="left" width="200"/>

[![CRANstatus](https://www.r-pkg.org/badges/version/genekitr)](https://cran.r-project.org/package=genekitr) [![](https://img.shields.io/badge/devel%20version-0.8.4-green.svg)](https://github.com/GangLiLab/genekitr) [![](https://cranlogs.r-pkg.org/badges/grand-total/genekitr?color=orange)](https://cran.r-project.org/package=genekitr) [![lifecycle](https://img.shields.io/badge/lifecycle-stable-blue.svg)](https://lifecycle.r-lib.org/articles/stages.html)
[![CRANstatus](https://www.r-pkg.org/badges/version/genekitr)](https://cran.r-project.org/package=genekitr) [![](https://img.shields.io/badge/devel%20version-0.8.5-green.svg)](https://github.com/GangLiLab/genekitr) [![](https://cranlogs.r-pkg.org/badges/grand-total/genekitr?color=orange)](https://cran.r-project.org/package=genekitr) [![lifecycle](https://img.shields.io/badge/lifecycle-stable-blue.svg)](https://lifecycle.r-lib.org/articles/stages.html)

![Alt](https://repobeats.axiom.co/api/embed/e42ba06d30de893670c70324f19398ef0a7c26fa.svg "Repobeats analytics image")

Expand Down Expand Up @@ -37,7 +37,9 @@ Here, I want to tell you a story about Mr. Doodle, a computational biology stude

PI gave Doodle 30 genes and let him check their locations (better with sequences) and exact names. Doodle searched on NCBI one by one and copied & paste it into excel. Doodle sent the file to PI one hour later, and PI smiled, "Well done! Now I have another 50!"

<b style='color:#486CBE'>**Doodle wonders how to avoid this repeat searching work?**</b>
```diff
! Doodle wonders how to avoid this repeat searching work? (and bold)
```

### Scene 2: embarrassing name

Expand Down
3 changes: 1 addition & 2 deletions man/genGO.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 2 additions & 4 deletions man/plotVenn.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 0a9926a

Please sign in to comment.