Skip to Main Content Skip to Search
Product Documentation

msviewer - Explore mass spectrum or set of mass spectra

Syntax

msviewer(MZ , Intensities)
msviewer(..., 'Markers', MarkersValue)
msviewer(..., 'Group', GroupValue)

Arguments

MZ Column vector of common mass/charge (m/z) values for a set of spectra. The number of elements in the vector equals the number of rows in the matrix Intensities.
IntensitiesMatrix of intensity values for a set of mass spectra that share the same m/z range. Each row corresponds to an m/z value, and each column corresponds to a spectrum or retention time. The number of rows equals the number of elements in vector MZ.
GroupValueEither of the following:
  • Vector of values with the same number of elements as rows in the matrix Intensities

  • Cell array of strings with the same number of elements as rows (spectra) in the matrix Intensities

Each value or string specifies a group to which the corresponding spectrum belongs. Spectra from the same group are plotted with the same color. Default is [1:numSpectra].

Description

msviewer(MZ , Intensities) displays the MS Viewer, which lets you view and explore a mass spectrum defined by MZ and Intensities.

msviewer(..., 'Markers', MarkersValue) specifies a list of marker positions from the mass/charge vector, MZ, for exploration and easy navigation. Enter a column vector with MZ values.

msviewer(..., 'Group', GroupValue) specifies a group to which the spectra belong. The groups are specified by GroupValue, a vector of values or cell array of strings. The number of values or strings is the same as the number of rows in the matrix Intensities. Each value or string specifies a group to which the corresponding spectrum belongs. Spectra from the same group are plotted with the same color. Default is [1:numSpectra].

The MS Viewer includes the following features:

MSViewer has five components:

Examples

  1. Load and plot sample data

    load sample_lo_res
    msviewer(MZ_lo_res, Y_lo_res)
  2. Add a marker by pointing to a mass peak, right-clicking, and then clicking Add Marker.

  3. From the File menu, select

    • Import Markers from Workspace — Opens the Import Markers From MATLAB Workspace dialog. The dialog should display a list of double Mx1 or 1xM variables. If the selected variable is out of range, the viewer displays an error message

    • Export Markers to Workspace — Opens the Export Markers to MATLAB Workspace dialog. You can enter a variable name for the markers. All markers are saved. If there is no marker available, this menu item should be disabled.

    • Print to Figure — Prints the spectra plot in the main display to a MATLAB Figure window

  4. From the Tools menu, click

    • Add Marker — Opens the Add Marker dialog. Enter an m/z marker.

    • Delete Marker — Removes the currently selected m/z marker from the Markers (m/z) list.

    • Next Marker or Previous Marker — Moves the selection up and down the Markers (m/z) list.

    • Zoom XY, Zoom X, Zoom Y, or Zoom Out — Changes the cursor from an arrow to crosshairs. Left-click and drag a rectangle box over an area and then release the mouse button. The display zooms the area covered by the box.

  5. Move the cursor to the range window at the bottom. Click and drag the view box to a new location.

See Also

msheatmap

How To

  


Free Computational Biology Interactive Kit

See how to analyze, visualize, and model biological data and systems using MathWorks products.

Get free kit

Trials Available

Try the latest computational biology products.

Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS