| Contents | Index |
A clustergram object contains hierarchical clustering analysis data that you can view in a heat map and dendrograms.
Create a clustergram object using the object constructor function clustergram. View a graphical representation of the clustergram object in a heat map and dendrograms using the view method.
The clustergram class is a subclass of the HeatMap class.
Following are methods of a clustergram object:
| addTitle (clustergram) | Add title to clustergram |
| addXLabel (clustergram) | Label x-axis of clustergram |
| addYLabel (clustergram) | Label y-axis of clustergram |
| clusterGroup (clustergram) | Select cluster group |
| get (clustergram) | Retrieve information about clustergram object |
| plot (clustergram) | Render clustergram and dendrograms for clustergram object |
| set (clustergram) | Set property of clustergram object |
| view (clustergram) | View clustergram and dendrograms of clustergram object |
Properties for Clustering Analysis and Clustergram Creation
| Property Name | Description |
|---|---|
| Standardize | String or number specifying the dimension for standardizing the data values. This property transforms the standardized values so that the mean is 0 and the standard deviation is 1 in the specified dimension. Choices are:
|
| Cluster | String or number specifying the dimension for clustering the values in the data. Choices are:
|
| RowPDist | String specifying the distance metric to pass to the pdist function (Statistics Toolbox™ software) to calculate the pairwise distances between rows. For information on choices, see the pdist function. Default is 'euclidean'. |
| ColumnPDist | String specifying the distance metric to pass to the pdist function (Statistics Toolbox software) to calculate the pairwise distances between columns. For information on choices, see the pdist function. Default is 'euclidean'. |
| Linkage | String or two-element cell array of strings specifying the linkage method to pass to the linkage function (Statistics Toolbox software) to create the hierarchical cluster tree for rows and columns. If a two-element cell array of strings, this property uses the first element for linkage between rows, and the second element for linkage between columns. For information on choices, see the linkage function. Default is 'average'. |
| Dendrogram | Scalar or two-element numeric vector or cell array of strings specifying the 'colorthreshold' property to pass to the dendrogram function (Statistics Toolbox software) to create the dendrogram plot. If a two-element numeric vector or cell array, the first element is for the rows, and the second element is for the columns. For more information, see the dendrogram function. |
| OptimalLeafOrder | Enables or disables the optimal leaf ordering calculation, which determines the leaf order that maximizes the similarity between neighboring leaves. Choices are true (enable) or false (disable). Default depends on the size of Data, the matrix of data used to create the clustergram object. If the number of rows or columns in Data exceeds 1000, default is false; otherwise, default is true. |
| Colormap | Either of the following:
Default is redgreencmap. |
| DisplayRange | Positive scalar specifying the display range of standardized values. Default is 3, which means there is a color variation for values between –3 and 3, but values >3 are the same color as 3, and values < –3 are the same color as –3. For example, if you specify redgreencmap for the 'Colormap' property, pure red represents values ≥ DisplayRangeValue, and pure green represents values ≤ –DisplayRangeValue. |
| Symmetric | Forces the color scale of the heat map to be symmetric around zero. Choices are true (default) or false. |
| LogTrans | Controls the log2 transform of the data from natural scale. Choices are true or false (default). |
| DisplayRatio | Either of the following:
This property specifies the ratio of space that the row and column dendrograms occupy relative to the heat map. If DisplayRatio is a scalar, it is used as the ratio for both dendrograms. If DisplayRatio is a two-element vector, the first element is used for the ratio of the row dendrogram width to the heat map width, and the second element is used for the ratio of the column dendrogram height to the heat map height. The second element is ignored for one-dimensional clustergrams. Default is 1/5. |
| ImputeFun | One of the following:
|
| ShowDendrogram | Shows and hides the dendrogram tree diagrams with the clustergram. Choices are 'on' (default) or 'off'. |
Properties for Group Labels
| Property Name | Description |
|---|---|
| RowGroupMarker | Structure or structure array containing information for annotating the groups (clusters) of rows determined by the clustergram function. The structure or structures contain the following fields. If a single structure, then the fields contain a cell array of elements. If a structure array, then the fields contain one element:
|
| ColumnGroupMarker | Structure or structure array containing information for annotating the groups (clusters) of columns determined by the clustergram function. The structure or structures contain the following fields. If a single structure, then the fields contain a cell array of elements. If a structure array, then the fields contain one element:
|
Properties for Row and Column Labels
| Property Name | Description |
|---|---|
| RowLabels | Vector of numbers or cell array of text strings to label the rows in the dendrogram and heat map. Default is a vector of values 1 through M, where M is the number of rows in Data, the matrix of data used by the clustergram function to create the clustergram object. |
| ColumnLabels | Vector of numbers or cell array of text strings to label the columns in the dendrogram and heat map. Default is a vector of values 1 through M, where M is the number of columns in Data, the matrix of data used by the clustergram function to create the clustergram object. |
| ColumnLabelsLocation | Read-only string specifying the location of the column labels. For clustergram objects, it is always 'bottom' (default). |
| RowLabelsLocation | Read-only string specifying the location of the row labels. For clustergram objects, it is always 'right' (default). |
| RowLabelsColor | Structure or structure array containing color information for labeling the rows (y-axis) of the clustergram. The structure or structures contain the following fields. If a single structure, then the fields contain a cell array of elements. If a structure array, then the fields contain one element:
|
| ColumnLabelsColor | Structure or structure array containing color information for labeling the columns (x-axis) of the clustergram. The structure or structures contain the following fields. If a single structure, then the fields contain a cell array of elements. If a structure array, then the fields contain one element:
|
| LabelsWithMarkers | Controls the display of colored markers instead of colored text for the row labels and column labels. Choices are true or false (default). |
| RowLabelsRotate | Numeric value in degrees rotation specifying the orientation of row (y-axis) labels. Default is 0 degrees, which is horizontal. Positive values cause counterclockwise rotation. |
| ColumnLabelsRotate | Numeric value in degrees rotation specifying the orientation of column (x-axis) labels. Default is 90 degrees, which is vertical. Values greater than 90 degrees cause counterclockwise rotation. |
Properties for Annotating Data
| Property Name | Description |
|---|---|
| Annotate | Controls the display of intensity values on each area of the heat map. Choices are true or false (default). |
| AnnotPrecision | Positive integer specifying the precision of the intensity values when displayed on the heat map. Default is 2. |
| AnnotColor | String or three-element vector of RGB values specifying a color, which is used for the text of the intensity values when displayed on the heat map. Default is 'white'. For more information on specifying colors, see ColorSpec. |
Note The following examples use the get and set methods with property names and values of a clustergram object. When supplying a PropertyName, be aware that it is case sensitive. |
Determining Properties and Property Values of a Clustergram Object
Display all properties and their current values of a clustergram object, CGobj:
get(CGobj)
Return all properties and their current values of CGobj, a clustergram object, to CGstruct, a scalar structure, in which each field name is a property of a clustergram object, and each field contains the value of that property:
CGstruct = get(CGobj)
Return the value of a specific property of a clustergram object, CGobj, using either:
PropertyValue = get(CGobj, 'PropertyName')
PropertyValue = CGobj.PropertyName
Return the value of specific properties of a clustergram object, CGobj:
[Property1Value, Property2Value, ...] = get(CGobj, ... 'Property1Name', 'Property2Name', ...)
Determining Possible Values of Clustergram Object Properties
Display possible values for all properties that have a fixed set of property values in a clustergram object, CGobj:
set(CGobj)
Display possible values for a specific property that has a fixed set of property values in a clustergram object, CGobj:
set(CGobj, 'PropertyName')
Specifying Properties of a Clustergram Object
Set a specific property of a clustergram object, CGobj, using either:
set(CGobj, 'PropertyName', PropertyValue)
CGobj.PropertyName = PropertyValue
Set multiple properties of a clustergram object, CGobj:
set(CGobj, 'Property1Name', Property1Value, ...
'Property2Name', Property2Value, ...)addTitle | addXLabel | addYLabel | clustergram | clusterGroup | display | get | plot | set | view

See how to analyze, visualize, and model biological data and systems using MathWorks products.
Get free kit| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |