I have the following code to plot the scattering plot by sns.jointplot. I need to set logarithmic binning and logarithmic scale for the x axis and linear one for the y axis. (x and y are 1D arrays)
bins_x =np.logspace(np.log10(min(x)) , np.log10(max(x)) , num=15)
bins_y = np.linspace (min(y), max(y), num=15)
g=sns.jointplot(x=x, y=y, kind='hist', cbar=True, height=6, ratio=3, space=0.2, bins=[bins_x, bins_y])
g.ax_joint.set_xscale('log')
The result of the code is this plot:
The scatter plot looks ok. But the 1D histogram on top of the plot (corresponding to the x axis is not logarithmically binned). Do you know how can I solve it? Or do you know other way to plot this graph?