Giter Site home page Giter Site logo

moosa-r / rbioapi Goto Github PK

View Code? Open in Web Editor NEW
17.0 1.0 1.0 38.67 MB

rbioapi: User-Friendly R Interface to Biologic Web Services' API

Home Page: https://rbioapi.moosa-r.com/

License: GNU General Public License v3.0

R 100.00%
api-client bioinformatics biology cran enrichment-analysis r rstats rstats-package jaspar over-representation-analysis

rbioapi's Introduction

rbioapi: User-Friendly R Interface to Biologic Web Services’ API

Moosa Rezwani 2023-07-27

CRAN_Status_Badge R-CMD-check

What does rbioapi do?

Currently fully supports Enrichr, JASPAR, miEAA, PANTHER, Reactome, STRING, and UniProt!

The goal of rbioapi is to provide a user-friendly and consistent interface to biological databases and services: In a way that insulates the user from technicalities of using web services API and creates a unified and easy-to-use interface to biological and medical web services.

With rbioapi, you do not need to have technical knowledge about web services API or learn how to work with a new package for every biologic service or database. This an ongoing project; New databases and services will be added periodically. Feel free to suggest any databases or services you often use.

What is Supported by rbioapi?

rbioapi is dedicated to Biological or Medical databases and web services. Currently, rbioapi supports and covers every API resources in the following services: (in alphabetical order):

On CRAN (Stable) version: (https://cran.r-project.org/package=rbioapi)

  1. Enrichr (rbioapi vignette article) (new)
  2. JASPAR (rbioapi vignette article) (new)
  3. miEAA (rbioapi vignette article)
  4. PANTHER (rbioapi vignette article)
  5. Reactome (rbioapi vignette article)
  6. STRING (rbioapi vignette article)
  7. UniProt (rbioapi vignette article)

Only on Github (Developmental) version: (https://github.com/moosa-r/rbioapi/):

  1. currently none

Each of the services has its dedicated vignette article. However, In this article, I will write about the general framework of rbioapi. Make sure to check the vignette article of each service to learn more about how to use them.

Note That: rbioapi is an ongoing project. New databases and services will be implemented periodically in order to gradually make the package as comprehensive as possible. Do you see yourself often using a certain database/service? Feel free to suggest any database/service by creating an issue on our GitHub repository. I will appreciate any suggestions.

How to install?

You can install the stable release version of rbioapi from CRAN with:

install.packages("rbioapi")

However, the CRAN version is released at most once every 1-2 months, You can install the most recent (development) version from GitHub with:

install.packages("remotes")
remotes::install_github("moosa-r/rbioapi")

Now, we can load the package:

library(rbioapi)

Naming conventions

To make the namespace more organized, functions has been named with the following pattern:

rba_[service_name]_[resource_name]

For example, rba_string_version() will call STRING’s version resource.

rba_string_version()
#> Retrieving the STRING database version and address used by rbioapi.
#> $string_version
#> [1] "11.5"
#> 
#> $stable_address
#> [1] "https://version-11-5.string-db.org"

Thus, to this version, rbioapi function will have one of the following naming schema:

  1. rba_enrichr_*
  2. rba_jaspar_*
  3. rba_mieaa_*
  4. rba_panther_*
  5. rba_reactome_*
  6. rba_string_*
  7. rba_uniprot_*

There are three exceptions: rba_options(), rba_connection_test(), and rba_pages(); these are helper functions. More on that later.

Changing the options

To provide more control, multiple options have been implemented. See the manual of rba_options() function for a full description of available options. In short, some of the options will govern rbioapi’s connection with servers (e.g. timeout, retry) and some of the options will modify your experience with rbioapi (e.g. verbose, diagnostics, save_file). There are two ways that you may use to change any option. Also, you can get table of available rbioapi options and their current values by calling rba_options()without any argument:

rba_options()
#>   rbioapi_option current_value            allowed_value
#> 1    diagnostics         FALSE     Logical (TRUE/FALSE)
#> 2       dir_name       rbioapi                Character
#> 3       progress         FALSE     Logical (TRUE/FALSE)
#> 4      retry_max             0   Numeric (0 or greater)
#> 5     retry_wait            10   Numeric (0 or greater)
#> 6      save_file         FALSE     Logical (TRUE/FALSE)
#> 7     skip_error          TRUE     Logical (TRUE/FALSE)
#> 8        timeout            30 Numeric (0.1 or greater)
#> 9        verbose          TRUE     Logical (TRUE/FALSE)

Now, let us consider the ways in which we can alter the settings:

Change the option globally

Changing an option globally means that for the rest of your R session, any rbioapi function will respect the changed option. To do this, use rba_options(). Each argument in this function corresponds to a certain option; Thus by running this function with your desired new values, you could globally alter that rbioapi option. for example:

rba_options(save_file = TRUE)
## From now on, the raw file of server's response will be saved to your working directory.
rba_options(verbose = FALSE)
## From now on, the package will be quiet.

Change the option only within a function call

You can pass additional arguments to any rbioapi function using “ellipsis” (the familiar or dot dot dot!). Meaning that you can call any function with additional arguments where each is ‘option = value’ pair. This way, any changes in options will be confined within that particular function call. For example:

## Save the server's raw response file:
x <- rba_reactome_species(only_main = TRUE, save_file = "reactome_species.json")
## Also, in the case of connection failure, retry up to 10 times:
x <- rba_reactome_species(only_main = TRUE,
                         save_file = "reactome_species.json", retry_max = 10)
## Run these codes in your own R session to see the difference.
## show internal diagnostics boring details
x <- rba_uniprot_proteins_crossref(db_id = "CD40", db_name = "HGNC", diagnostics = TRUE)
## The next function you call, will still use the default rbioapi options
x <- rba_uniprot_proteins_crossref(db_id = "CD40", db_name = "HGNC")

Connection test

The second exception in functions’ naming schema is rba_connection_test(). Run this simple function to check your connection with the supported services/databases. If you encounter errors when using rbioapi, kindly run this function to make sure that your internet connection or the servers are fine.

rba_connection_test(print_output = TRUE)
#> Checking Your connection to the Databases currently supported by rbioapi:
#> --->>> Internet :
#> +++ Connected to the Internet.
#> --->>> Enrichr :
#> +++ The server is responding.
#> --->>> Ensembl :
#> +++ The server is responding.
#> --->>> JASPAR :
#> +++ The server is responding.
#> --->>> miEAA :
#> +++ The server is responding.
#> --->>> PANTHER :
#> +++ The server is responding.
#> --->>> Reactome Content Service :
#> +++ The server is responding.
#> --->>> Reactome Analysis Service :
#> +++ The server is responding.
#> --->>> STRING :
#> +++ The server is responding.
#> --->>> UniProt :
#> +++ The server is responding.

Iterating over paginated results

Some API resources will return paginated responses. This is particularly common in API resources which return potentially very large responses. In rbioapi, for these cases, there are arguments such as “page_number” (with default value of 1) and -if the API resource allows- “page_size”. To save your time, you may use rba_pages(). This function will iterate over the pages you have specified.

Take rba_uniprot_taxonomy_name as an example. This function allows you to search taxonomic nodes in UniProt. The response can potentially have a huge size, so UniProt returns a paginated response. For example, if we search for nodes that contain “adenovirus”, there is a large number of hits:

adeno <- rba_uniprot_taxonomy_name(name = "adenovirus",
                                   search_type = "contain",
                                   page_number = 1)
str(adeno, max.level = 2)
#> List of 2
#>  $ taxonomies:'data.frame':  200 obs. of  8 variables:
#>   ..$ taxonomyId    : int [1:200] 10509 10510 10511 10512 10513 10514 10515 10519 10521 10522 ...
#>   ..$ mnemonic      : chr [1:200] "9ADEN" "ADEB3" "ADEB7" "9ADEN" ...
#>   ..$ scientificName: chr [1:200] "Mastadenovirus" "Bovine adenovirus B serotype 3" "Bovine adenovirus 7" "Canine adenovirus 1" ...
#>   ..$ rank          : chr [1:200] "genus" "no rank" "no rank" "no rank" ...
#>   ..$ superregnum   : chr [1:200] "V" "V" "V" "V" ...
#>   ..$ hidden        : logi [1:200] FALSE TRUE TRUE TRUE TRUE TRUE ...
#>   ..$ commonName    : chr [1:200] NA "BAdV-3" "BAdV-7" NA ...
#>   ..$ synonym       : chr [1:200] NA "Mastadenovirus bos3" NA NA ...
#>  $ pageInfo  :List of 3
#>   ..$ resultsPerPage: int 200
#>   ..$ currentPage   : int 1
#>   ..$ totalRecords  : int 985

As you can see, the server has returned the first page of the response, to retrieve the other pages, you should make separate calls and change the “page_number” argument within each call, or simply use rba_pages() as demonstrated below:

adeno_pages = rba_pages(quote(rba_uniprot_taxonomy_name(name = "adenovirus",
                                   search_type = "contain",
                                   page_number = "pages:1:3")))
## You can inspect the structure of the response:
str(adeno_pages, max.level = 2)
#> List of 3
#>  $ page_1:List of 2
#>   ..$ taxonomies:'data.frame':   200 obs. of  8 variables:
#>   ..$ pageInfo  :List of 3
#>  $ page_2:List of 2
#>   ..$ taxonomies:'data.frame':   200 obs. of  8 variables:
#>   ..$ pageInfo  :List of 3
#>  $ page_3:List of 2
#>   ..$ taxonomies:'data.frame':   200 obs. of  8 variables:
#>   ..$ pageInfo  :List of 3

As you can see, what we have done was:

  1. Wrap the function call in qoute() and enter that as the input for rba_pages().

  2. Replace the argument we want to iterate over it, with a string in this format: “pages:start:end”. For example, we supplied page_number = “pages:1:3” to get the responses of pages 1 to 3.

How and what to cite?

rbioapi is an interface between you and other databases and services. Thus, if you have used rbioapi in published research, in addition to kindly citing rbioapi, make sure to fully and properly cite the databases/services you have used. Suggested citations have been added in the functions’ manuals, under the “references” section; Nevertheless, it is the user’s responsibility to check for proper citations and to properly cite the database/services that they have used.

How to cite rbioapi

  • Moosa Rezwani, Ali Akbar Pourfathollah, Farshid Noorbakhsh, rbioapi: user-friendly R interface to biologic web services’ API, Bioinformatics, Volume 38, Issue 10, 15 May 2022, Pages 2952–2953, https://doi.org/10.1093/bioinformatics/btac172

How to cite the databases and web services

Code of conduct

This package, rbioapi, is an unofficial interface implementation and is not associated, endorsed, or officially connected in any way with the original databases and web services. The creators and maintainers of rbioapi are independent entities and have no official relationship with those databases and web services.

When using rbioapi, remember that you are querying data from web services; So please be considerate. Never flood a server with requests, if you need to download unreasonably large volumes of data, directly downloading the databases supplied in those services may be a better alternative. If you see yourself being rate-limited from any server (HTTP 429 Too Many Requests response status code), know that you are sending more requests than what the server interprets as normal behavior, so please seek other methods or use Sys.sleep() between your requests.

What next?

Each supported service has a dedicated vignette article. Make sure to check those too.

  1. Enrichr
  2. JASPAR
  3. miEAA
  4. PANTHER
  5. Reactome
  6. STRING
  7. UniProt

We are also adding vignette articles focusing on tasks and workflows:

  1. Do with rbioapi: Enrichment (Over-Representation) Analysis in R

Design philosophy of rbioapi

To learn more about the design philosophy and the concepts behind developing rbioapi, please read our paper in Bioinformatics:

rbioapi: user-friendly R interface to biologic web services’ API

Links

Session info

#> R version 4.3.1 (2023-06-16 ucrt)
#> Platform: x86_64-w64-mingw32/x64 (64-bit)
#> Running under: Windows 11 x64 (build 22621)
#> 
#> Matrix products: default
#> 
#> 
#> locale:
#> [1] LC_COLLATE=English_United States.utf8 
#> [2] LC_CTYPE=English_United States.utf8   
#> [3] LC_MONETARY=English_United States.utf8
#> [4] LC_NUMERIC=C                          
#> [5] LC_TIME=English_United States.utf8    
#> 
#> time zone: Europe/Brussels
#> tzcode source: internal
#> 
#> attached base packages:
#> [1] stats     graphics  grDevices utils     datasets  methods   base     
#> 
#> other attached packages:
#> [1] rbioapi_0.7.9
#> 
#> loaded via a namespace (and not attached):
#>  [1] digest_0.6.33     R6_2.5.1          fastmap_1.1.1     xfun_0.39        
#>  [5] knitr_1.43        htmltools_0.5.5   rmarkdown_2.23    cli_3.6.1        
#>  [9] compiler_4.3.1    httr_1.4.6        rstudioapi_0.15.0 tools_4.3.1      
#> [13] curl_5.0.1        evaluate_0.21     yaml_2.3.7        rlang_1.1.1      
#> [17] jsonlite_1.8.7

rbioapi's People

Contributors

moosa-r avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

echo-xu-zhao

rbioapi's Issues

Installation Error: could not find function "cwd"

Hi, thanks for the nice-looking package.
I tried to install the package (throught CRAN and Github) but I am getting this error:
Error: could not find function "cwd" Execution halted Warning message: In i.p(...) : installation of package ‘/tmp/RtmpLK3yuT/file13f3058005337/rbioapi_0.8.0.tar.gz’ had non-zero exit status
Thanks!
Session info:

setting value
version R version 4.1.3 (2022-03-10)
os Ubuntu 20.04.4 LTS
system x86_64, linux-gnu
ui RStudio
language (EN)
collate en_US.UTF-8
ctype en_US.UTF-8
tz Etc/UTC
date 2024-01-10
rstudio 2022.02.1+461 Prairie Trillium (server)
pandoc 2.17.1.1 @ /usr/lib/rstudio-server/bin/quarto/bin/ (via rmarkdown)

Issue with pantherDB API

Hi,
I launched this morning a code that was working yesterday and get a message asking to report it to you, Here is an example of command giving the error message :

rba_panther_enrich(genes = c("PRMT6", "GDAP2", "WDR3",  "TBX15", "WARS2", "HAO2"), organism = 9606, annot_dataset = 'GO:0048241')
Performing over-representation enrichment analysis of 6 input genes of organism 9606 against GO:0048241 datasets.

Error in .rba_skeleton(input_call): Internal Error: Failed to parse the server's response. This is probably because the server has changed the response format. Please report this bug to us: 
 Error in jsonlite::flatten(x$result) : is.data.frame(x) n'est pas TRUE

Thank you for your help,
Audrey

pulling hierarchy sort indices from Panther

Thank you very much for the tool! Its great to have consistent access to a lot of resources.

Recently, Panther introduced sorting resulting GO terms based on the hierarchy, which is pretty helpful in my hands. Is there any way to retrieve that information?

Regards,
Amel

Parse Error

I encountered a parse error while performing "Physical Entities".
Is there a way to fix it?

> rba_reactome_participants(event_id = "Q9BXM7-1", 
+                           only_physical_entities = TRUE)
Retrieving 'Physical Entities' Participants of Reactome event Q9BXM7-1.
Error in .rba_skeleton(input_call) : 
  Internal Error: Failed to parse the server's response. This is probably because the server has changed the response format. Please report this bug to us: 
 Error : parse error: premature EOF
                                       
                     (right here) ------^

Connection refused issue

Hi there,

Last month I run rbioapi smoothly on my laptop. But for last four days, every time I run rba_panther_enrich() I got an error even use the test input:

rba_panther_enrich(genes = c("p53", "BRCA1", "cdk2", "Q99835", "CDC42",
"CDK1", "KIF23", "PLK1", "RAC2", "RACGAP1"),
organism = 9606, annot_dataset = "GO:0008150", cutoff = 0.01)

Performing over-representation enrichment analysis of 10 input genes of organism 9606 against GO:0008150 datasets.
Error: Failed to connect to www.pantherdb.org port 80: Connection refused

R is 4.2.2 and rbioapi is 0.7.9.

Have I been blocked? The analysis is somehow a bit of a hurry. Any comments and suggestions appreciate!

Thanks,
Bohu

rba_panther_family gives NULL

Hello! I was using rba_panther_family("PTHR11937",'tree') and it worked perfectly fine, but now gives NULL for some reason. Also it gives NULL for other families and for rba_panther_family("PTHR11937",'msa')

STRING version outdated

Hi,

just wanted to let you know, that STRING is currently on version 11.5, while the API still calls version 11.0.

It would be great if there was an option to explicitly set the STRING version for API calls.

Cheers,
Stephan

getting genes associated with PANTHER terms

thanks for this helpful tool! after running rba_panther_enrich(), how can I get the list of genes in my gene list that are associated with each significant term? I can't seem to find a function that will allow that. Thanks!

rbioapi - Panther - Internal Error: Failed to parse the server's response. This is probably because the server has changed the response format.

Hello,

I am trying to run the enrichment analysis for maize using the Zm00001d type gene ids, which usually works fine on the Panther website.

genes <- result_table_interaction_ash$gene_id
genes
[1] "Zm00001d029136" "Zm00001d053999" "Zm00001d033416" "Zm00001d033985" "Zm00001d018414" "Zm00001d017251" "Zm00001d027760" "Zm00001d046865"
[9] "Zm00001d041323" "Zm00001d024291" "Zm00001d024423" "Zm00001d038223" "Zm00001d027715" "Zm00001d047538" "Zm00001d005934" "Zm00001d020557"
[17] "Zm00001d007301" "Zm00001d013960" "Zm00001d012791" "Zm00001d031943" "Zm00001d022396" "Zm00001d044686" "Zm00001d023312" "Zm00001d044285"
[25]

enriched <- rba_panther_enrich(genes = genes,
organism = 4577,
annot_dataset = "molecular_function",
cutoff = 0.05)

But it returns this error.

Performing over-representation enrichment analysis of 29 input genes of organism 4577 against molecular_function datasets.
Error in .rba_skeleton(input_call) :
Internal Error: Failed to parse the server's response. This is probably because the server has changed the response format. Please report this bug to us:
Error in jsonlite::flatten(x$result) : is.data.frame(x) is not TRUE

Thanks in advance for any help with this issue.

Panther API update

Hi,

I have started using your tool and realized there are some differences between the results from the rba_panther_enrich function and the Panther website (including their version of the Panther API).

It would be great if you could incorporate these updates in rbioapi.

Cheers,
Alex

Error running example line of code from ?rba_panther_enrich

In rbioapi_0.7.9 I get the following error while trying to run the example line of code from ?rba_panther_enrich man page:

> rba_panther_enrich(genes = c("p53", "BRCA1", "cdk2", "Q99835", "CDC42",
+                              "CDK1", "KIF23", "PLK1", "RAC2", "RACGAP1"),
+                    organism = 9606, annot_dataset = "GO:0008150",
+                    cutoff = 0.01)
Performing over-representation enrichment analysis of 10 input genes of organism 9606 against GO:0008150 datasets.

$search
$search$error
[1] "Error annotation type data set not specified"

$search$search_type
[1] "overrepresentation"

Session information:

> sessionInfo()
R version 4.2.2 (2022-10-31)
Platform: aarch64-apple-darwin20 (64-bit)
Running under: macOS Ventura 13.4.1

Matrix products: default
LAPACK: /Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats4    stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] rbioapi_0.7.9         shiny_1.7.4.1         clustermole_1.1.0     GSEABase_1.60.0      
 [5] graph_1.76.0          annotate_1.76.0       XML_3.99-0.14         AnnotationDbi_1.60.2 
 [9] IRanges_2.32.0        S4Vectors_0.36.2      Biobase_2.58.0        BiocGenerics_0.44.0  
[13] dplyr_1.1.2           clusterProfiler_4.6.2 msigdbr_7.5.1         cerebroApp_1.3.1     
[17] presto_1.0.0          data.table_1.14.8     Rcpp_1.0.11           SeuratObject_4.1.3   
[21] Seurat_4.3.0.1       

loaded via a namespace (and not attached):
  [1] rappdirs_0.3.3              scattermore_1.2             tidyr_1.3.0                
  [4] ggplot2_3.4.2               bit64_4.0.5                 irlba_2.3.5.1              
  [7] DelayedArray_0.24.0         KEGGREST_1.38.0             RCurl_1.98-1.12            
 [10] generics_0.1.3              ScaledMatrix_1.6.0          cowplot_1.1.1              
 [13] RSQLite_2.3.1               shadowtext_0.1.2            RANN_2.6.1                 
 [16] future_1.33.0               bit_4.0.5                   tzdb_0.4.0                 
 [19] enrichplot_1.18.4           spatstat.data_3.0-1         xml2_1.3.5                 
 [22] httpuv_1.6.11               SummarizedExperiment_1.28.0 fontawesome_0.5.1          
 [25] viridis_0.6.3               hms_1.1.3                   jquerylib_0.1.4            
 [28] babelgene_22.9              promises_1.2.0.1            fansi_1.0.4                
 [31] progress_1.2.2              dbplyr_2.3.3                igraph_1.5.0               
 [34] DBI_1.1.3                   htmlwidgets_1.6.2           spatstat.geom_3.2-2        
 [37] purrr_1.0.1                 ellipsis_0.3.2              crosstalk_1.2.0            
 [40] biomaRt_2.54.1              deldir_1.0-9                sparseMatrixStats_1.10.0   
 [43] MatrixGenerics_1.10.0       vctrs_0.6.3                 SingleCellExperiment_1.20.1
 [46] ROCR_1.0-11                 abind_1.4-5                 cachem_1.0.8               
 [49] withr_2.5.0                 ggforce_0.4.1               HDO.db_0.99.1              
 [52] progressr_0.13.0            vroom_1.6.3                 sctransform_0.3.5          
 [55] treeio_1.22.0               prettyunits_1.1.1           goftest_1.2-3              
 [58] cluster_2.1.4               DOSE_3.24.2                 ape_5.7-1                  
 [61] lazyeval_0.2.2              crayon_1.5.2                spatstat.explore_3.2-1     
 [64] edgeR_3.40.2                pkgconfig_2.0.3             tweenr_2.0.2               
 [67] GenomeInfoDb_1.34.9         nlme_3.1-162                rlang_1.1.1                
 [70] globals_0.16.2              lifecycle_1.0.3             miniUI_0.1.1.1             
 [73] colourpicker_1.2.0          downloader_0.4              filelock_1.0.2             
 [76] BiocFileCache_2.6.1         rsvd_1.0.5                  polyclip_1.10-4            
 [79] GSVA_1.46.0                 matrixStats_1.0.0           lmtest_0.9-40              
 [82] shinyFiles_0.9.3            Matrix_1.6-0                aplot_0.1.10               
 [85] singscore_1.18.0            Rhdf5lib_1.20.0             zoo_1.8-12                 
 [88] ggridges_0.5.4              png_0.1-8                   viridisLite_0.4.2          
 [91] bitops_1.0-7                shinydashboard_0.7.2        gson_0.1.0                 
 [94] KernSmooth_2.23-22          rhdf5filters_1.10.1         Biostrings_2.66.0          
 [97] blob_1.2.4                  DelayedMatrixStats_1.20.0   stringr_1.5.0              
[100] qvalue_2.30.0               parallelly_1.36.0           spatstat.random_3.1-5      
[103] readr_2.1.4                 gridGraphics_0.5-1          beachmat_2.14.2            
[106] scales_1.2.1                memoise_2.0.1               magrittr_2.0.3             
[109] plyr_1.8.8                  ica_1.0-3                   zlibbioc_1.44.0            
[112] compiler_4.2.2              scatterpie_0.2.1            RColorBrewer_1.1-3         
[115] fitdistrplus_1.1-11         cli_3.6.1                   XVector_0.38.0             
[118] listenv_0.9.0               patchwork_1.1.2             pbapply_1.7-2              
[121] MASS_7.3-60                 tidyselect_1.2.0            stringi_1.7.12             
[124] yaml_2.3.7                  GOSemSim_2.24.0             locfit_1.5-9.8             
[127] BiocSingular_1.14.0         ggrepel_0.9.3               grid_4.2.2                 
[130] sass_0.4.7                  fastmatch_1.1-3             tools_4.2.2                
[133] future.apply_1.11.0         parallel_4.2.2              rstudioapi_0.15.0          
[136] gridExtra_2.3               farver_2.1.1                Rtsne_0.16                 
[139] ggraph_2.1.0                BiocManager_1.30.21.1       digest_0.6.33              
[142] GenomicRanges_1.50.2        later_1.3.1                 RcppAnnoy_0.0.21           
[145] shinyWidgets_0.7.6          httr_1.4.6                  colorspace_2.1-0           
[148] fs_1.6.2                    tensor_1.5                  reticulate_1.30            
[151] splines_4.2.2               uwot_0.1.16                 yulab.utils_0.0.6          
[154] tidytree_0.4.4              spatstat.utils_3.0-3        graphlayouts_1.0.0         
[157] sp_2.0-0                    ggplotify_0.1.1             plotly_4.10.2              
[160] xtable_1.8-4                jsonlite_1.8.7              ggtree_3.6.2               
[163] tidygraph_1.2.3             ggfun_0.1.1                 R6_2.5.1                   
[166] pillar_1.9.0                htmltools_0.5.5             mime_0.12                  
[169] glue_1.6.2                  fastmap_1.1.1               DT_0.28                    
[172] BiocParallel_1.32.6         codetools_0.2-19            fgsea_1.24.0               
[175] utf8_1.2.3                  lattice_0.21-8              bslib_0.5.0                
[178] spatstat.sparse_3.0-2       tibble_3.2.1                curl_5.0.1                 
[181] leiden_0.4.3                GO.db_3.16.0                shinyjs_2.1.0              
[184] limma_3.54.2                survival_3.5-5              munsell_0.5.0              
[187] rhdf5_2.42.1                GenomeInfoDbData_1.2.9      HDF5Array_1.26.0           
[190] reshape2_1.4.4              gtable_0.3.3                shinycssloaders_1.0.0 

The server returned HTTP Status '405'

Hi,

Thanks for the great API, it is extremely useful for my research.

I am trying to run some miRNA enrichment with the following code:

rba_mieaa_enrich(test_set =deg_up,
                             mirna_type = "mature",
                             test_type = "ORA",
                             species = "hsa")

But for the past few days it just gives back an error:

 -- Step 1/3: Submitting Enrichment analysis request:
Submitting ORA enrichment request for 1 miRNA IDs of species Homo sapiens to miEAA servers.
Error: The server returned HTTP Status '405' (Redirection: Method Not Allowed).

I tried to update rbioapi and also restrict the enrichment to certain categories, but all the same.
I would greatly appreciate some help to make it work again.

Best regards,
Mariko

Problem with the Panther serve

Dear Moosa,

I was using the rbioapi packages to access the Panther server, and until today it was fine. However I got this error today, even with the example provided by the rbioapi website:

rba_panther_enrich(genes = c("p53", "BRCA1", "cdk2", "Q99835", "CDC42",

  •                          "CDK1", "KIF23", "PLK1", "RAC2", "RACGAP1"),
    
  •                organism = 9606, annot_dataset = "GO:0008150",
    
  •                cutoff = 0.01)
    

Performing over-representation enrichment analysis of 10 input genes of organism 9606 against GO:0008150 datasets.
Error in .rba_skeleton(input_call) :
Internal Error: Failed to parse the server's response. This is probably because the server has changed the response format. Please report this bug to us:
Error in jsonlite::flatten(x$result) : is.data.frame(x) is not TRUE

Do you know if it will be corrected soon?

Best,
Elsa

P-values and FDRs inconsistent

Thanks for this beneficial tool. However, when I use the rba_reactome_analysis(input = genes_list, species = "Homo sapiens") function, I consistently obtain p-values and FDRs that are different from the results I obtain when I run the analysis directly on the site (https://reactome.org/PathwayBrowser/#/DTAB=AN). This also affects the most significant pathways as they are sorted by p-value.

Database Connection

Hello,

I am trying to access PANTHER but the database is not responding, I restarted the R session but still having trouble accessing it. Is there some way to fix this?

Thank you!

rba_connection_test(print_output=TRUE)
Checking Your connection to the Databases currently supported by rbioapi:
--->>> Internet :
+++ Connected to the Internet.
--->>> Enrichr :
+++ The server is responding.
--->>> Ensembl :
+++ The server is responding.
--->>> JASPAR :
+++ The server is responding.
--->>> miEAA :
+++ The server is responding.
--->>> PANTHER :
!!! failed with error:
Error in curl::curl_fetch_memory(url, handle = handle) :
Recv failure: Connection was reset
--->>> Reactome Content Service :
+++ The server is responding.
--->>> Reactome Analysis Service :
+++ The server is responding.
--->>> STRING :
+++ The server is responding.
--->>> UniProt :
+++ The server is responding.

rba_options()
rbioapi_option current_value allowed_value
1 diagnostics FALSE Logical (TRUE/FALSE)
2 dir_name rbioapi Character
3 progress FALSE Logical (TRUE/FALSE)
4 retry_max 1 Numeric (0 or greater)
5 retry_wait 10 Numeric (0 or greater)
6 save_file FALSE Logical (TRUE/FALSE)
7 skip_error FALSE Logical (TRUE/FALSE)
8 timeout 90 Numeric (0.1 or greater)
9 verbose TRUE Logical (TRUE/FALSE

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.