Apologies for being relatively new to Python and especially new to using it for statistical purposes. I have two columns of data which I've read in from excel. I've created the 1D histograms for each column and proven the area under them to be equal to 1 like so:
n, bins, _=plt.hist(thickness, 15, range=[0,8], density=True)
Area_T= sum(numpy.diff(bins)*n)
Now I wish to prove that area of a 2D histogram is equal to 1. I have the 2D histogram made, just not sure how to integrate it since it returns a 2D array.
h, xedges, yedges, _=plt.hist2d(thickness_data, height_data, bins=(20,20), density=True)