Confusing colours using geneplotter functions and heatmap()
1
0
Entering edit mode
@michael-watson-iah-c-378
Last seen 9.6 years ago
Hi I am using heatmap() to create a heatmap (obviously) and using the function: greenred.colors() To create a list of green/red colors to use. However, the results are very confusing! My spot ME7_823 has a value of -0.4 for a particular column, another spot NB_774D has a value of -0.6 and a third spot ME7_949 a value of -0.7. : ME7_823 -0.4 NB_774D -0.6 ME7_949 -0.7 Now, I would expect all of these values to be green, and for ME7_949 to be brighter than NB_774D which in turn would be brighter than ME7_823, which would be the darkest as it is the lowest value. THIS IS NOT THE CASE! In my heatmap(), NB_774D is clearly the darkest, then ME7_823 and then ME7_949 is the brightest. Clearly this is not how it should be, UNLESS heatmap() only assigns colours relative to each row individually, and does not do any comparison between rows. Is this the case? Won't this lead to misleading results? Surely the colour assigned to a spot in a heatmap should reflect that spot's "position" in the whole dataset, not just the data for that row of the matrix? If the latter is true, then values of 5000 and 0.5 could be assigned the same colour, simply because they are in the same position relative to their respective genes - and that would render making comparisons vertically in a heatmap() useless...? Cheers Mick
• 853 views
ADD COMMENT
0
Entering edit mode
@sean-davis-490
Last seen 3 months ago
United States
Michael, There are times when using row-based scaling makes sense. For example, if one is comparing two samples via a common reference (2-color design), then absolute ratios are not meaningful, only the ratios relative to each other. In this case, and probably others, having row-based scaling (or normalization) makes contrasts easier to see and more intuitive. In your case, it seems you feel that scaling is not appropriate and probably isn't. I believe the default for heatmap is to have row scaling. From heatmap documentation (see ?heatmap): scale: character indicating if the values should be centered and scaled in either the row direction or the column direction, or none. The default is '"row"' if 'symm' false, and '"none"' otherwise. So, you probably want to do heatmap(...,scale="none") Sean > Clearly this is not how it should be, UNLESS heatmap() only assigns > colours relative to each row individually, and does not do any > comparison between rows. Is this the case? Won't this lead to > misleading results? Surely the colour assigned to a spot in a heatmap > should reflect that spot's "position" in the whole dataset, not just > the > data for that row of the matrix? If the latter is true, then values of > 5000 and 0.5 could be assigned the same colour, simply because they are > in the same position relative to their respective genes - and that > would > render making comparisons vertically in a heatmap() useless...?
ADD COMMENT

Login before adding your answer.

Traffic: 863 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6