This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.


Create Principal Component Analysis (PCA) plot of microarray data


mapcaplot(Data, Label)


DataDataMatrix object or numeric array containing microarray expression profile data. If a DataMatrix object, the row names are used as labels in the plot, unless you provide labels with the second input Label.
LabelCell array of character vectors representing labels for the data points in the plot.


mapcaplot(Data) creates 2-D scatter plots of principal components of Data, a DataMatrix object or numeric array containing microarray expression profile data.

mapcaplot(Data, Label) uses the elements of the cell array of character vectors Label, instead of the row numbers, to label the data points in the PCA plots.

Once you plot the principal components, you can:

  • Select principal components for the x and y axes from the drop-down list boxes below each scatter plot.

  • Click a data point to display its label.

  • Select a subset of data points by click-dragging a box around them. This will highlight the points in the selected region and the corresponding points in the other axes. The labels of the selected data points appear in the list box.

  • Select a label in the list box to highlight the corresponding data point in the plot. Press and hold Ctrl or Shift to select multiple data points.

  • Export the gene labels and indices to a structure in the MATLAB® workspace by clicking Export.


collapse all

This example shows how to create a PCA plot of yeast microarray data.

This example uses data from an experiment (DeRisi et al., 1997) that used DNA microarrays to study temporal gene expression of almost all genes in Saccharomyces cerevisiae (yeast) during the metabolic shift from fermentation to respiration. Expression levels were measured at seven time points during the diauxic shift.

Load the MAT-file, provided with Bioinformatics Toolbox™, that contains filtered yeast microarray data.

load filteredyeastdata

This MAT-file includes three variables:

  • yeastvalues - A matrix of gene expression data from Saccharomyces cerevisiae (yeast) during the metabolic shift from fermentation to respiration

  • genes - A cell array of GenBank® accession numbers for labeling the rows in yeastvalues

  • times - A vector of time values for labeling the columns in yeastvalues

Perform PCA on the expression data and plot the result.

mapcaplot(yeastvalues, genes)


[1] DeRisi, J.L., Iyer, V.R., and Brown, P.O. (1997). Exploring the metabolic and genetic control of gene expression on a genomic scale. Science 278, 680–686s.

Introduced before R2006a

Was this topic helpful?