Re: matrix difference

From: Alexander Bürger <buerger_at_iskp.uni-bonn.de>
Date: Sun, 12 Nov 2006 22:15:57 +0100


Hi Olivier,

>> I woulk like to visualize the difference of two matrices in log scale.
>> ... problem ... negative entries, ...

> You can shift your data to make them > 0 and plot two histo with different colors.

This seemed more complicated to me than patching the code of THistPainter. So I made a crude hack to get more or less what I want. The patch is in the attachment. It adds a new "suboption" nphh (negative-positive-half-half) to col(z) which maps, also in logscale where z'=sign(z)*log(abs(z)) for |z|>1 and z'=0 otherwise, all negative z(') to the first half of the palette, and all positive z(') to the second half, each half with its own scale. Also a little macro setting a color palette for red=negative and blue=positive is attached. The TPaletteAxis class is not adapted, so colz shows a completely wrong color scale.

A+

Alexander

Received on Sun Nov 12 2006 - 22:16:35 MET

This archive was generated by hypermail 2.2.0 : Mon Jan 01 2007 - 16:32:01 MET