Code Monkey home page Code Monkey logo

metaboseek's Introduction

Windows Build Status

Metaboseek

Metaboseek is here to help you analyze your mass spectrometry data!

Visit our website at https://metaboseek.com to test Metaboseek online

Installation and data analysis documentation

Metaboseek is an interactive tool to analyze and browse your mass spectrometry data. It is built on functions from the xcms package, and provides a web-based graphical user interface built with shiny.

Metaboseek is currently under development, and new features are constantly added. Visit the download page to see the full change log.

Citation

If you use Metaboseek for your research, please cite our paper!

Some background

In Liquid Chromatography/Mass Spectrometry (LC/MS), so called mass spectra are acquired in rapid succession. Each spectrum can contain the mass-to-charge ratios (m/z) of thousands of charged molecules (ions) and their intensity (=relative abundance) at one time point. The molecules are separated through chromatography before entering the mass spectrometer, so that ions are separated in an additional dimension, the retention time (rt). This is particularly important to get separate signals for molecules with the same or very similar m/z value, but different structures (this happens a lot).

The combination of m/z value and retention time can be defined as a molecular feature. Although these molecular features typically don't allow unambiguous identification of specific compounds, their abundance can be compared between different biological samples. This can be very useful, because a molecular feature might be enriched in one sample group compared to another. For instance, some molecular features might only be found in a mutant strain of bacteria, but not in the wild-type control. In the approach to metabolomics presented here, we can select such molecular features of interest and then try to get more information about the molecular structure by tandem-MS, a method that breaks molecules into pieces and then reports the m/z of the resulting fragments.

Features

So what can you do with this app? I would like to highlight some of the key software features, and invite you to check out the example data that is loaded in the online version (and is also included in the Metaboseek R package). Documentation on how to use the app is available at https://metaboseek.com/doc.

Metaboseek offers a graphical user interface to set up data analysis with the xcms package to detect and align molecular features from LC/MS data across multiple samples. You can then load xcms results into the app as a "Feature Table" (using xcms and MSnbase packages, mzR-based) and run statistical analyses to identify molecular features of interest.

  1. Filter the xcms results, view and export chromatograms and mass spectra for molecular features of interest.

browse_2

  1. Generate and view molecular networks based on tandem-MS spectrum similarity between molecular features (using MassTools and igraph packages). The interactive plot is based on re-rendering plot.igraph() with different parameters depending on selections.

networking

  1. Annotate fragments in tandem-MS spectra with SIRIUS. Metaboseek sends jobs to the SIRIUS command line interface and retrieves them from the SIRIUS output folder.

SIRIUS

Technical Details

Metaboseek is strictly built from shiny modules, allowing for easy reuse and rearrangement of elements such as the spectral plots

  • Metaboseek is an R package that contains the app code along with some data analysis functions

  • For improved code organization, Metaboseek is built from more than 70 different shiny modules, all of which are part of the Metaboseek package and documented. I am considering splitting grouping these modules into sub-packages for easier reuse by others.

Try Metaboseek

Unfortunately, it was not possible to deploy the app on shinyapps.io. There seems to be a problem with installing one of the required packages (mzR). However, there are other options to try the app:

  • Here is the direct link to the app (with example data pre-loaded), hosted on a shiny-server instance at Boyce Thompson Institute/Cornell University (on this server, it takes up to a minute to load; when installed locally, it starts within a few seconds)

  • Take a look at the documentation here to see how to get Metaboseek as installer or .zip file for Windows (built using R-portable), as a Docker image or from GitHub.

metaboseek's People

Contributors

jasonbason avatar mjhelf avatar

Stargazers

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

Watchers

 avatar  avatar

metaboseek's Issues

Reconsider enabling parallel processing for `chromatograms` call

In multiEIC (https://github.com/mjhelf/METABOseek/blob/bb55f521c2d3aa5e804034213253c1466cdbd956/R/Functions_extract_EICs.R#L235) you disable parallel processing for chromatograms. For a single feature/ion this could make sense, but if you extract ion chromatograms for several features/ranges at once I would use parallel processing as it should be faster. One possible reason why it could be slower is if you use SnowParam.

Some tips here:

  1. use if possible MulticoreParam, as this will fork the process instead of starting a new R instance. SnowParam will thus have to start a new R, and load all required libraries before it can run the code in parallel. This takes quite some time and could be a reason that parallel processing might appear slower than serial processing.
  2. Initialize the parallel processing setup at the start and don't manually specify them in individual function calls. I found it usefull to call e.g. register(bpstart(MulticoreParam(2))) or register(bpstart(SnowParam(2))) right at the start of the session. With the bpstart you explicitly initialyze the forks or sockets and every parallel processing call should start faster (could also help with socket-based parallel processing on windows - but did not try that).

In any rate, there is a parallel processing section in the xcms vignette that describes this a little.

Exporting tables during xcms analysis

Describe the bug
Hi Max,
The peak_table export process is somehow not able to go to completion in my recent jobs. I get a peaktable_grouped.csv file and a peaktable_grouped_rtcorr.csv file only as R workspace files - they're not being written to excel files. I do get peaktable_unprocessed files (both rtcorr and not), but I am hesitant to use because they are not zero-filled and not normalized.

To Reproduce
I set up a few jobs in a row with the same issue. Possible that it's a problem with these runs in particular, as I had no issues for a job of similar size (same samples, different LC).

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
image

Console output
Aligning 20190624_05.mzXML against 20190624_04.mzXML ... Error in (function (x) : attempt to apply non-function

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Additional context
Hi Max!

Version 0.9.6 installer issue

I was able to successfully install version 0.9.6 on a new system but the executable consistently crashed prior to the web browser opening. I didn't have this issue on a different computer after updating to 0.9.6 from a previous version.

Installing version 0.9.5 first, then installing version 0.9.6 solved this problem.

Crashes with PRM data

reported offline by @rnb77:

MS data files that don't contain MS1 scans (e.g. PRM runs) cause crashes when switching to the MS2 browser

@rnb77 can you please give me access to the data that caused the issue?

Improved EIC extraction in xcms

Hi @mjhelf , just wanted to highlight that we improved the ion chromatogram extraction for features recently in xcms.

In the current release xcms (for R 3.5.2 and Bioconductor 3.8) we have the featureChromatograms function that extracts ion chromatograms for features in the XCMSnExp object.

In the current devel xcms (i.e. master branch in the xcms github repo) we added some more useful stuff. Chromatogram objects can now also contain the information of identified chromatographic peaks and when you use featureChromatograms you will extract the ion chromatograms for features along with the identified chromatographic peaks. The plot function for these XChromatograms objects will now automatically highlight the identified peak. I've attached the updated vignette in case you want to see how this works.

xcms.html.zip

MF prediction incorrect method.

MF prediction currently yields MFs with integer double-bond equivalents; however, for ESI + and ESI - data the most likely scenario is half-integer DBUs. Best to add this as an option, with half integer set as default.

CV

comments bug

comments from previous table transferred to active table (seen when custom table -> loaded table: first three comments in loaded table missing)

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.