| Bioinformatics Toolbox™ | ![]() |
msheatmap(MZ, Intensities)
msheatmap(MZ, Times, Intensities)
msheatmap(..., 'Midpoint', MidpointValue,
...)
msheatmap(..., 'Range', RangeValue,
...)
msheatmap(..., 'Markers', MarkersValue,
...)
msheatmap(..., 'SpecIdx', SpecIdxValue,
...)
msheatmap(..., 'Group', GroupValue,
...)
msheatmap(..., 'Resolution', ResolutionValue,
...)
| 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.
| |
| Times | Column vector of retention times associated
with a liquid chromatography/mass spectrometry (LC/MS) or gas chromatography/mass
spectrometry (GC/MS) data set. The number of elements in the vector
equals the number of columns in the matrix Intensities.
The retention times are used to label the y-axis
of the heat map.
| |
| Intensities | Matrix 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.
The number of columns equals the number of elements in vector Times.
| |
| MidpointValue | Value specifying a quantile of the ion
intensity values to fall below the midpoint of the colormap, meaning
they do not represent peaks. msheatmap uses a custom
colormap where cool colors represent nonpeak regions, white represents
the midpoint, and warm colors represent peaks. Choices are any value ≥
0 and ≤ 1. Default is:
| |
| RangeValue | 1-by-2 vector specifying the m/z range for the x-axis of the heat map. RangeValue must be within [min(MZ) max(MZ)]. Default is the full range [min(MZ) max(MZ)]. | |
| MarkersValue | Vector of m/z values to mark on the top horizontal axis of the heat map. Default is []. | |
| SpecIdxValue | Either of the following:
Each value or string specifies a label for the corresponding spectrum. These values or strings are used to label the y-axis of the heat map. | |
| GroupValue | Either of the following:
Each value or string specifies a group to which the corresponding spectrum belongs. The spectra are sorted and combined into groups along the y-axis in the heat map. | |
| ResolutionValue | Value specifying the horizontal resolution
of the heat map image. Increase this value to enhance details. Decrease
this value to reduce memory usage. Default is:
|
msheatmap(MZ, Intensities) displays a pseudocolor heat map image of the intensities for the spectra in matrix Intensities.
msheatmap(MZ, Times, Intensities) displays a pseudocolor heat map image of the intensities for the spectra in matrix Intensities, using the retention times in vector Times to label the y-axis.
msheatmap(..., 'PropertyName', PropertyValue, ...) calls msheatmap with optional properties that use property name/property value pairs. You can specify one or more properties in any order. Each PropertyName must be enclosed in single quotation marks and is case insensitive. These property name/property value pairs are as follows:
msheatmap(..., 'Midpoint', MidpointValue,
...) specifies a quantile of the ion intensity values
to fall below the midpoint of the colormap, meaning they do not represent
peaks. msheatmap uses a custom colormap where cool
colors represent nonpeak regions, white represents the midpoint, and
warm colors represent peaks. Choices are any value between 0 and 1.
Default is:
0.99 — For LC/MS or GC/MS data or when input T is provided. This means that 1% of the pixels are warm colors and represent peaks.
0.95 — For non-LC/MS or non-GC/MS data or when input T is not provided. This means that 5% of the pixels are warm colors and represent peaks.
Tip You can also change the midpoint interactively after creating the heat map by right-clicking the color bar, selecting Interactive Colormap Shift, then click-dragging the cursor vertically on the color bar. This technique is useful when comparing multiple heat maps. |
msheatmap(..., 'Range', RangeValue, ...) specifies the m/z range for the x-axis of the heat map. RangeValue is a 1-by-2 vector that must be within [min(MZ) max(MZ)]. Default is the full range [min(MZ) max(MZ)].
msheatmap(..., 'Markers', MarkersValue, ...) places markers along the top horizontal axis of the heat map for the m/z values specified in the vector MarkersValue. Default is [].
msheatmap(..., 'SpecIdx', SpecIdxValue, ...) labels the spectra along the y-axis in the heat map. The labels are specified by SpecIdxValue, a vector of values or cell array of strings. The number of values or strings is the same as the number of columns (spectra) in the matrix Intensities. Each value or string specifies a label for the corresponding spectrum.
msheatmap(..., 'Group', GroupValue, ...) sorts and combines spectra into groups along the y-axis in the heat map. 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.
msheatmap(..., 'Resolution', ResolutionValue, ...) specifies the horizontal resolution of the heat map image. Increase this value to enhance details. Decrease this value to reduce memory usage. Default is:
0.5 — When MZ contains > 2,500 elements.
0.05 — When MZ contains <= 2,500 elements.
SELDI-TOF Data
Load SELDI-TOF sample data.
load sample_lo_res
Create a vector of four m/z values to mark along the top horizontal axis of the heat map.
M = [3991.4 4598 7964 9160];
Display the heat map with m/z markers and a limited m/z range.
msheatmap(MZ_lo_res,Y_lo_res,'markers',M,'range',[3000 10000])

Display the heat map again grouping each spectrum into one of two groups.
TwoGroups = [1 1 2 2 1 1 2 2]; msheatmap(MZ_lo_res,Y_lo_res,'markers',M,'group',TwoGroups)

Liquid Chromatography/Mass Spectrometry (LC/MS) Data
Load LC/MS sample data.
load lcmsdata
Resample the peak lists to create a vector of m/z values and a matrix of intensity values.
[MZ, Intensities] = msppresample(peaks, 5000);
Display the heat map showing mass spectra at different retention times.
msheatmap(MZ, ret_time, log(Intensities))

Bioinformatics Toolbox functions: msalign, msbackadj, msdotplot, mslowess, msnorm, mspalign, msresample, mssgolay, msviewer
![]() | msdotplot | mslowess | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |