www.gusucode.com > bioinfo 案例源码程序 matlab代码 > bioinfo/PlotASetOfMassSpectraDataExample.m
%% Plot Mass Spectra Data % This example shows how to plot mass spectra data. % Copyright 2015 The MathWorks, Inc. %% % Load and plot a sample mass spectra data. load sample_lo_res msviewer(MZ_lo_res, Y_lo_res) %% % Add a marker by pointing to a mass peak, right-clicking, and % then clicking *Add Marker*. %% % The *File* menu has the following options. % % * *Import Markers from Workspace* - Opens the Import Markers From MATLAB(R) % Workspace dialog. The dialog displays 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(R) % Workspace dialog. Enter a variable name for the markers. All markers are % saved. If thre is no marker available, this menu item is disabled. % * *Print to Figure* - Prints the spectra plot in the main display to a % MATLAB(R) figure window. %% % The *Tools* menu has the following options. % % * *Add Marker* - Opens the Add Marker dialog where you can 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* list. % * *Zoom XY*, *Zoom X*, *Zoom Y*, or *Zoom Out* - Changes the cursor from % an arror to a crosshair. Left-click and drag a rectangle box over an area % and then release it. The display zooms the area covered by the box. %% % From the range window at the bottom, move the view box to a new % location.