Set y axis limit in Pandas histogram

前端 未结 2 1874
夕颜
夕颜 2021-02-20 05:48

I am using Pandas histogram.

I would like to set the y-axis range of the plot.

Here is the context:

import matplotlib.pyplot as plt
%matplotlib          


        
2条回答
  •  温柔的废话
    2021-02-20 06:35

    You can simply add option sharey=True to make all subplots share the same yaxis limit, similiary using sharex=True for xaxis

    data['ranking'].hist(by=data[column], sharey=True)

提交回复
热议问题