Attempting to import SBML file using R
0
1
Entering edit mode
isasg ▴ 10
@3aabd927
Last seen 12 months ago
United States

Hi,

I have a metabolic model I would like to work with currently in an sbml file. I have been trying to figure out a method to extract information from this format to work with the edges and nodes with RGBL or a similar graph library. Unfortunately, I cannot use the rsbml package since it is not supported on Mac. I have been trying out the libSBML and sbmlr packages but have been running into issues there as well.

When using the readSBML function from libSBML, my file is read in as [1] "_p_SBMLDocument" attr(,"package") [1] "libSBML". I'm not sure how to convert this into another class or extract any information about the actual model.

cd630=readSBML(system.file("models", "iCdG709.sbml", package = "SBMLR"))

When using readSBML from SBMLR, I receive this error.

Error: C stack usage 7969552 is too close to the limit

I'm not sure what is causing this issue. When I read in the example models that come with the SBMLR package, like curto, I don't have this issue and that file is read in as class "SBMLR".

If anyone has any insight into any of these issues, any help would be appreciated! I'm really not sure what the best route would be and haven't seen much information online. I really just need to get the model into a format that is easier to work with. The file I am working with can be found here: https://github.com/csbl/Jenior_CdifficileGENRE_2021/blob/master/data/reconstructions/iCdG709.sbml

sessionInfo( )

R version 4.3.2 (2023-10-31)
Platform: x86_64-apple-darwin20 (64-bit)
Running under: macOS Monterey 12.7.1

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib 
LAPACK: /Library/Frameworks/R.framework/Versions/4.3-x86_64/Resources/lib/libRlapack.dylib;  LAPACK version 3.11.0

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

time zone: America/New_York
tzcode source: internal

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

other attached packages:
 [1] genefilter_1.82.1           pheatmap_1.0.12            
 [3] apeglm_1.22.1               MASS_7.3-60                
 [5] pasilla_1.28.0              DEXSeq_1.46.0              
 [7] RColorBrewer_1.1-3          AnnotationDbi_1.62.2       
 [9] BiocParallel_1.34.2         DESeq2_1.40.2              
[11] SummarizedExperiment_1.30.2 Biobase_2.60.0             
[13] MatrixGenerics_1.12.3       matrixStats_1.1.0          
[15] GenomicRanges_1.52.1        GenomeInfoDb_1.36.4        
[17] IRanges_2.34.1              S4Vectors_0.38.2           
[19] htmltools_0.5.7             lubridate_1.9.3            
[21] forcats_1.0.0               stringr_1.5.1              
[23] dplyr_1.1.4                 purrr_1.0.2                
[25] readr_2.1.4                 tidyr_1.3.0                
[27] tibble_3.2.1                ggplot2_3.4.4              
[29] tidyverse_2.0.0             timeDate_4022.108          
[31] KEGGgraph_1.60.0            readxl_1.4.3               
[33] SBMLR_1.96.0                deSolve_1.38               
[35] XML_3.99-0.15               RBGL_1.76.0                
[37] graph_1.78.0                BiocGenerics_0.46.0        
[39] libSBML_5.20.2             

loaded via a namespace (and not attached):
  [1] splines_4.3.2           bitops_1.0-7           
  [3] ggplotify_0.1.2         filelock_1.0.2         
  [5] cellranger_1.1.0        polyclip_1.10-6        
  [7] lifecycle_1.0.4         lattice_0.21-9         
  [9] magrittr_2.0.3          cowplot_1.1.1          
 [11] DBI_1.1.3               abind_1.4-5            
 [13] zlibbioc_1.46.0         ggraph_2.1.0           
 [15] RCurl_1.98-1.13         yulab.utils_0.1.0      
 [17] tweenr_2.0.2            rappdirs_0.3.3         
 [19] GenomeInfoDbData_1.2.10 enrichplot_1.20.3      
 [21] ggrepel_0.9.4           tidytree_0.4.5         
 [23] annotate_1.78.0         codetools_0.2-19       
 [25] DelayedArray_0.26.7     DOSE_3.26.2            
 [27] xml2_1.3.5              ggforce_0.4.1          
 [29] tidyselect_1.2.0        aplot_0.2.2            
 [31] farver_2.1.1            viridis_0.6.4          
 [33] BiocFileCache_2.8.0     jsonlite_1.8.7         
 [35] tidygraph_1.2.3         survival_3.5-7         
 [37] bbmle_1.0.25            tools_4.3.2            
 [39] progress_1.2.2          treeio_1.24.3          
 [41] Rcpp_1.0.11             glue_1.6.2             
 [43] gridExtra_2.3           qvalue_2.32.0          
 [45] numDeriv_2016.8-1.1     withr_2.5.2            
 [47] fastmap_1.1.1           fansi_1.0.5            
 [49] digest_0.6.33           timechange_0.2.0       
 [51] R6_2.5.1                gridGraphics_0.5-1     
 [53] colorspace_2.1-0        GO.db_3.17.0           
 [55] biomaRt_2.56.1          RSQLite_2.3.3          
 [57] utf8_1.2.4              generics_0.1.3         
 [59] data.table_1.14.8       prettyunits_1.2.0      
 [61] graphlayouts_1.0.2      httr_1.4.7             
 [63] S4Arrays_1.0.6          scatterpie_0.2.1       
 [65] pkgconfig_2.0.3         gtable_0.3.4           
 [67] blob_1.2.4              hwriter_1.3.2.1        
 [69] XVector_0.40.0          clusterProfiler_4.8.3  
 [71] shadowtext_0.1.2        fgsea_1.26.0           
 [73] geneplotter_1.78.0      scales_1.2.1           
 [75] png_0.1-8               ggfun_0.1.3            
 [77] rstudioapi_0.15.0       tzdb_0.4.0             
 [79] reshape2_1.4.4          coda_0.19-4            
 [81] nlme_3.1-163            curl_5.1.0             
 [83] bdsmatrix_1.3-6         cachem_1.0.8           
 [85] parallel_4.3.2          HDO.db_0.99.1          
 [87] pillar_1.9.0            grid_4.3.2             
 [89] vctrs_0.6.4             dbplyr_2.4.0           
 [91] xtable_1.8-4            Rgraphviz_2.44.0       
 [93] mvtnorm_1.2-3           cli_3.6.1              
 [95] locfit_1.5-9.8          compiler_4.3.2         
 [97] Rsamtools_2.16.0        rlang_1.1.2            
 [99] crayon_1.5.2            emdbook_1.3.13         
[101] plyr_1.8.9              fs_1.6.3               
[103] stringi_1.8.2           viridisLite_0.4.2      
[105] munsell_0.5.0           Biostrings_2.68.1      
[107] lazyeval_0.2.2          GOSemSim_2.26.1        
[109] Matrix_1.6-1.1          hms_1.1.3              
[111] patchwork_1.1.3         bit64_4.0.5            
[113] KEGGREST_1.40.1         statmod_1.5.0          
[115] igraph_1.5.1            memoise_2.0.1          
[117] ggtree_3.8.2            fastmatch_1.1-4        
[119] bit_4.0.5               downloader_0.4         
[121] ape_5.7-1               gson_0.1.0
SBMLR sbml rsbm rsbml • 456 views
ADD COMMENT

Login before adding your answer.

Traffic: 639 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6