Thanks for your help Mathieu! I managed to solve this problem using imshow by looking at previous Matlab answers by Image Analyst:
x = D(:,1);
Unrecognized function or variable 'D'.
y = D(:,2);
z = D(:,3);
xgrid = reshape(x,[100,100]);
ygrid = reshape(y,[100,100]);
zgrid = reshape(z,[100,100]);
C= [xgrid ygrid zgrid];
C2 = imresize(zgrid, 100); % Blow up by a factor of 100;
figure;
imshow(C2,'XData', x./1e3, 'YData', y./1e3);
axis on;
clim([0e14 0.16e14])
cmap = jet(256);
colormap(cmap);
h = colorbar;
h.Label.String = 'Number Density';
h.Location = 'northoutside';
xlabel('Km'); ylabel('Km');
set(gca,'Fontsize',16);
ax = gca; % get the current axis
ax.Clipping = 'off'; % turn clipping off


