I want to combine a time series and a histogram to appear together like the example below:

I just want one to be scaled without distortion and placed freely within the second but I haven't found yet a code snipped for this.
The graph was taken from here, but it involves merging 2 svg graphs. Can this be done directly in matplotlib?