Heatmap2: which transformations does the tool apply before plotting my data?

I ran the heatmap2 tool on galaxy with the following settings:

Tool Parameters Input Parameter Value

Data transformation > Plot the data as it is
Compute z-scores prior to clustering > none
Scale data on the plot (after clustering) > Scale my data by row
Enable data clustering > no
Labeling columns and rows > Label my columns and rows
Type of colormap to use > three
Output format > PDF

As input file I used a simple gene expression matrix (each gene on a row, each column is a sample, 3 sample per condition, 2 conditions).

Can anyone tell me what the tool plots as output values to build the colors? Is it z-scores, LogFC or else? The color key indicates -1.5 to 1.5 as range. Thanks, appreciate any help!

As input file I used a simple gene expression matrix (each gene on a row, each column is a sample, 3 sample per condition, 2 conditions).

Hi @Stefano,

in its default mode, this tool simply plots the data you give to it.

There are three ways to have it manipulate the input data before plotting. These are the “Data transformation”, “Compute z-scores prior to clustering” and “Scale data on the plot (after clustering)” options. Of these, the last two are performing the same data transformation, i.e. they both compute z-scores, but as it says in the parameter labels, one of them does the transformation before the clustering step, the other one only afterwards. In any case, a selection under “Data transformation” will be done first.

Since you have selected:

Data transformation > Plot the data as it is
Compute z-scores prior to clustering > none
Scale data on the plot (after clustering) > Scale my data by row

for the three parameters in question, you will get z-scores plotted. Since you haven’t selected clustering, you should get identical results if you select Compute z-scores prior to clustering > Compute on rows.

Hope this helps,
Wolfgang

1 Like

Hi @wm75,
that helps a lot! Thanks for your kind clarification,

Stefano