
Wrong plotting by 2D (Joint) histogram

feifeihanyu
I have been benefited from the code posted here: http://www.igorexchange.com/node/1373 for 2D Joint histogram plot.
Recently I got a wrong graph attached. I have two columns data x and y, and x(i) is smaller than y(i). so the graph should show only in upper triangle area.
But the image shows all. Does anyone know the reason? Thanks
regards
Feifei

March 8, 2016 at 08:50 am - Permalink
Thank you so much for your reply!
x and y have the same size. I didn't find the data point x=1005 and y=630, except in the figure. x(i) always less than y(i).
just plotting y vs x. the bottom triangle is empty!! That is the reason I was surprised.
Below, you can find the data file and the y vs x pltting.
You could try the 2D Joint histogram to plot these data.
Anyone else knows the reason?
March 9, 2016 at 01:27 am - Permalink
If you are using Igor 6.3x you can put at the top of your procedure file
#include <Bivariate Histogram 2>
This will give you the WaveMetrics version - the ability to make a Bivariate Histogram from the Macros menu. I did this on your data and got only density in the correct triangle.
I think in Igor 7 there is a Joint Histogram function built-in.
March 9, 2016 at 02:21 am - Permalink
Hi sjr51,
Thanks a lot! Although I still don't know the reason. It seems that "2D Joint histogram" from http://www.igorexchange.com/node/1373 is not very reliable. However, I learn an another power tool from you! Nice suggestion! Thanks!
with best regards
March 9, 2016 at 09:00 am - Permalink