I have 2 arrays of data x and y both are 22250-by-54, and I'm trying to use hist3 and imagesc to make density plots for each x(:,n) and y(:,n) pair where n = 1:54. 
I'm using imagesc(values2) where:
values2 = hist3([x(:) y(:)],[round(max(x)) round(max(y)) ]);
to use as my argument to plot for each of the 54 x and y values to get a unique axis range and it works fine. However, when I place fixed integer values for values2 such as
values2 = hist3([x(:) y(:)],[50 50 ]);
the actual values for each of the 54 columns of x and y end up getting scaled to the [50 50] parameters or if I use [100 100] and it does not reflect the ACTUAL values for each x and y. How can I fix the axis x,y ranges and keep the actual values in the fixed axis range?
I have tried also using xlim and ylim in a separate call after the call to imagesc(values2) and this does not work either - it plots my data in a very small area and leaves lots of white space around the image area.
Thank you for your help!!
I have tried the "checked" response from the link below to get to where I am now: Scatter plot with density in Matlab
 
     
    
