Skip to content

Commit

Permalink
Add argument condition to rba_string_enrichment_image
Browse files Browse the repository at this point in the history
- enforce species paramater if more than 100 IDs are supplied
  • Loading branch information
moosa-r committed Jan 6, 2025
1 parent c5c77e7 commit 3b1fbdb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion R/stringdb.R
Original file line number Diff line number Diff line change
Expand Up @@ -1430,7 +1430,10 @@ rba_string_enrichment_image <- function(ids,
min_val = 1),
list(arg = "x_axis",
class = "character",
val = c("signal", "strength", "FDR", "gene_count"))
val = c("signal", "strength", "FDR", "gene_count"))),
cond = list(list(quote(length(ids) > 100 && is.null(species)),
sprintf("You supplied %s IDs. Please Specify the species (Homo Sapiens NCBI taxonomy ID is 9606).",
length(ids)))
))

.msg("Retrieving STRING enrichment plot of %s input Identifiers.", length(ids))
Expand Down

0 comments on commit 3b1fbdb

Please sign in to comment.